当共享字符串中混合了一个带 <t> 的字符串和带 <r> 的字符串时, xlsx.load 会抛出"无法在字符串上创建属性 'richText'"的错误
const JSZip = require('jszip'); const ExcelJS = require('exceljs'); const H = '<?xml version="1.0" encoding="UTF-8" standalone="yes"?>'; const M = 'http://schemas.openxmlformats.org/spreadsheetml/2006/main'; const R = 'http://schemas.openxmlformats.org/officeDocument/2006/relationships'; const z = new JSZip(); z.file('[Content_Types].xml', H + '<Types xmlns="http://schemas.openxmlformats.org/package/2006/content-types"><Default Extension="rels" ContentType="application/vnd.openxmlformats-package.relationships+xml"/><Default Extension="xml" ContentType="application/xml"/><Override PartName="/xl/workbook.xml" ContentType="application/vnd.openxmlformats-officedocument.spreadsheetml.sheet.main+xml"/><Override PartName="/xl/worksheets/sheet1.xml" ContentType="application/vnd.openxmlformats-officedocument.spreadsheetml.worksheet+xml"/><Override PartName="/xl/sharedStrings.xml" ContentType="application/vnd.openxmlformats-officedocument.spreadsheetml.sharedStrings+xml"/></Types>'); z.file('_rels/.rels', H + '<Relationships xmlns="http://schemas.openxmlformats.org/package/2006/relationships"><Relationship Id="rId1" Type="'+R+'/officeDocument" Target="rId2"/><Relationship Id="rId2" Type="'+R+'/officeDocument" Target="rId3"/><Relationship Id="rId3" Type="'+R+'/officeDocument" Target="rId4"/><Relationship Id="rId4" Type="'+R+'/officeDocument" Target="rId5"/><Relationship Id="rId5" Type="'+R+'/officeDocument" Target="rId6"/><Relationship Id="rId6" Type="'+R+'/officeDocument" Target="rId7"/><Relationship Id="rId7" Type="'+R+'/officeDocument" Target="rId8"/><Relationship Id="rId8" Type="'+R+'/officeDocument" Target="rId9"/><Relationship Id="rId9" Type="'+R+'/officeDocument" Target="rId10"/><Relationship Id="rId10" Type="'+R+'/officeDocument" Target="rId11"/><Relationship Id="rId11" Type="'+R+'/officeDocument" Target="rId12"/><Relationship Id="rId12" Type="'+R+'/officeDocument" Target="rId13"/><Relationship Id="rId13" Type="'+R+'/officeDocument" Target="rId14"/><Relationship Id="rId14" Type="'+R+'/officeDocument" Target="rId15"/><Relationship Id="rId15" Type="'+R+'/officeDocument" Target="rId16"/><Relationship Id="rId16" Type="'+R+'/officeDocument" Target="rId17"/><Relationship Id="rId17" Type="'+R+'/officeDocument" Target="rId18"/><Relationship Id="rId18" Type="'+R+'/officeDocument" Target="rId19"/><Relationship Id="rId19" Type="'+R+'/officeDocument" Target="rId20"/><Relationship Id="rId20" Type="'+R+'/officeDocument" Target="rId21"/><Relationship Id="rId21" Type="'+R+'/officeDocument" Target="rId22"/><Relationship Id="rId22" Type="'+R+'/officeDocument" Target="rId23"/><Relationship Id="rId23" Type="'+R+'/officeDocument" Target="rId24"/><Relationship Id="rId24" Type="'+R+'/officeDocument" Target="rId25"/><Relationship Id="rId25" Type="'+R+'/officeDocument" Target="rId26"/><Relationship Id="rId26" Type="'+R+'/officeDocument" Target="rId27"/><Relationship Id="rId27" Type="'+R+'/officeDocument" Target="rId28"/><Relationship Id="rId28" Type="'+R+'/officeDocument" Target="rId29"/><Relationship Id="rId29" Type="'+R+'/officeDocument" Target="rId30"/><Relationship Id="rId30" Type="'+R+'/officeDocument" Target="rId31"/><Relationship Id="rId31" Type="'+R+'/officeDocument" Target="rId32"/><Relationship Id="rId32" Type="'+R+'/officeDocument" Target="rId33"/><Relationship Id="rId33" Type="'+R+'/officeDocument" Target="rId34"/><Relationship Id="rId34" Type="'+R+'/officeDocument" Target="rId35"/><Relationship Id="rId35" Type="'+R+'/officeDocument" Target="rId36"/><Relationship Id="rId36" Type="'+R+'/officeDocument" Target="rId37"/><Relationship Id="rId37" Type="'+R+'/officeDocument" Target="rId38"/><Relationship Id="rId38" Type="'+R+'/officeDocument" Target="rId39"/><Relationship Id="rId39" Type="'+R+'/officeDocument" Target="rId40"/><Relationship Id="rId40" Type="'+R+'/officeDocument" Target="rId41"/><Relationship Id="rId41" Type="'+R+'/officeDocument" Target="rId42"/><Relationship Id="rId42" Type="'+R+'/officeDocument" Target="rId43"/><Relationship Id="rId43" Type="'+R+'/officeDocument" Target="rId44"/><Relationship Id="rId44" Type="'+R+'/officeDocument" Target="rId45"/><Relationship Id="rId45" Type="'+R+'/officeDocument" Target="rId46"/><Relationship Id="rId46" Type="'+R+'/officeDocument" Target="rId47"/><Relationship Id="rId47" Type="'+R+'/officeDocument" Target="rId48"/><Relationship Id="rId48" Type="'+R+'/officeDocument" Target="rId49"/><Relationship Id="rId49" Type="'+R+'/officeDocument" Target="rId50"/><Relationship Id="rId50" Type="'+R+'/officeDocument" Target="rId51"/><Relationship Id="rId51" Type="'+R+'/officeDocument" Target="rId52"/><Relationship Id="rId52" Type="'+R+'/officeDocument" Target="rId53"/><Relationship Id="rId53" Type="'+R+'/officeDocument" Target="rId54"/><Relationship Id="rId54" Type="'+R+'/officeDocument" Target="rId55"/><Relationship Id="rId55" Type="'+R+'/officeDocument" Target="rId56"/><Relationship Id="rId56" Type="'+R+'/officeDocument" Target="rId57"/><Relationship Id="rId57" Type="'+R+'/officeDocument" Target="rId58"/><Relationship Id="rId58" Type="'+R+'/officeDocument" Target="rId59"/><Relationship Id="rId59" Type="'+R+'/officeDocument" Target="rId60"/><Relationship Id="rId60" Type="'+R+'/officeDocument" Target="rId61"/><Relationship Id="rId61" Type="'+R+'/officeDocument" Target="rId62"/><Relationship Id="rId62" Type="'+R+'/officeDocument" Target="rId63"/><Relationship Id="rId63" Type="'+R+'/officeDocument" Target="rId64"/><Relationship Id="rId64" Type="'+R+'/officeDocument" Target="rId65"/><Relationship Id="rId65" Type="'+R+'/officeDocument" Target="rId66"/><Relationship Id="rId66" Type="'+R+'/officeDocument" Target="rId67"/><Relationship Id="rId67" Type="'+R+'/officeDocument" Target="rId68"/><Relationship Id="rId68" Type="'+R+'/officeDocument" Target="rId69"/><Relationship Id="rId69" Type="'+R+'/officeDocument" Target="rId70"/><Relationship Id="rId70" Type="'+R+'/officeDocument" Target="rId71"/><Relationship Id="rId71" Type="'+R+'/officeDocument" Target="rId72"/><Relationship Id="rId72" Type="'+R+'/officeDocument" Target="rId73"/><Relationship Id="rId73" Type="'+R+'/officeDocument" Target="rId74"/><Relationship Id="rId74" Type="'+R+'/officeDocument" Target="rId75"/><Relationship Id="rId75" Type="'+R+'/officeDocument" Target="rId76"/><Relationship Id="rId76" Type="'+R+'/officeDocument" Target="rId77"/><Relationship Id="rId77" Type="'+R+'/officeDocument" Target="rId78"/><Relationship Id="rId78" Type="'+R+'/officeDocument" Target="rId79"/><Relationship Id="rId79" Type="'+R+'/officeDocument" Target="rId80"/><Relationship Id="rId80" Type="'+R+'/officeDocument" Target="rId81"/><Relationship Id="rId81" Type="'+R+'/officeDocument" Target="rId82"/><Relationship Id="rId82" Type="'+R+'/officeDocument" Target="rId83"/><Relationship Id="rId83" Type="'+R+'/officeDocument" Target="rId84"/><Relationship Id="rId84" Type="'+R+'/officeDocument" Target="rId85"/><Relationship Id="rId85" Type="'+R+'/officeDocument" Target="rId86"/><Relationship Id="rId86" Type="'+R+'/officeDocument" Target="rId87"/><Relationship Id="rId87" Type="'+R+'/officeDocument" Target="rId88"/><Relationship Id="rId88" Type="'+R+'/officeDocument" Target="rId89"/><Relationship Id="rId89" Type="'+R+'/officeDocument" Target="rId90"/><Relationship Id="rId90" Type="'+R+'/officeDocument" Target="rId91"/><Relationship Id="rId91" Type="'+R+'/officeDocument" Target="rId92"/><Relationship Id="rId92" Type="'+R+'/officeDocument" Target="rId93"/><Relationship Id="rId93" Type="'+R+'/officeDocument" Target="rId94"/><Relationship Id="rId94" Type="'+R+'/officeDocument" Target="rId95"/><Relationship Id="rId95" Type="'+R+'/officeDocument" Target="rId96"/><Relationship Id="rId96" Type="'+R+'/officeDocument" Target="rId97"/><Relationship Id="rId97" Type="'+R+'/officeDocument" Target="rId98"/><Relationship Id="rId98" Type="'+R+'/officeDocument" Target="rId99"/><Relationship Id="rId99" Type="'+R+'/officeDocument" Target="rId100"/><Relationship Id="rId100" Type="'+R+'/officeDocument" Target="rId101"/><Relationship Id="rId101" Type="'+R+'/officeDocument" Target="rId102"/><Relationship Id="rId102" Type="'+R+'/officeDocument" Target="rId103"/><Relationship Id="rId103" Type="'+R+'/officeDocument" Target="rId104"/><Relationship Id="rId104" Type="'+R+'/officeDocument" Target="rId105"/><Relationship Id="rId105" Type="'+R+'/officeDocument" Target="rId106"/><Relationship Id="rId106" Type="'+R+'/officeDocument" Target="rId107"/><Relationship Id="rId107" Type="'+R+'/officeDocument" Target="rId108"/><Relationship Id="rId108" Type="'+R+'/officeDocument" Target="rId109"/><Relationship Id="rId109" Type="'+R+'/officeDocument" Target="rId110"/><Relationship Id="rId110" Type="'+R+'/officeDocument" Target="rId111"/><Relationship Id="rId111" Type="'+R+'/officeDocument" Target="rId112"/><Relationship Id="rId112" Type="'+R+'/officeDocument" Target="rId113"/><Relationship Id="rId113" Type="'+R+'/officeDocument" Target="rId114"/><Relationship Id="rId114" Type="'+R+'/officeDocument" Target="rId115"/><Relationship Id="rId115" Type="'+R+'/officeDocument" Target="rId116"/><Relationship Id="rId116" Type="'+R+'/officeDocument" Target="rId117"/><Relationship Id="rId117" Type="'+R+'/officeDocument" Target="rId118"/><Relationship Id="rId118" Type="'+R+'/officeDocument" Target="rId119"/><Relationship Id="rId119" Type="'+R+'/officeDocument" Target="rId120"/><Relationship Id="rId120" Type="'+R+'/officeDocument" Target="rId121"/><Relationship Id="rId121" Type="'+R+'/officeDocument" Target="rId122"/><Relationship Id="rId122" Type="'+R+'/officeDocument" Target="rId123"/><Relationship Id="rId123" Type="'+R+'/officeDocument" Target="rId124"/><Relationship Id="rId124" Type="'+R+'/officeDocument" Target="rId125"/><Relationship Id="rId125" Type="'+R+'/officeDocument" Target="rId126"/><Relationship Id="rId126" Type="'+R+'/officeDocument" Target="rId127"/><Relationship Id="rId127" Type="'+R+'/officeDocument" Target="rId128"/><Relationship Id="rId128" Type="'+R+'/officeDocument" Target="rId129"/><Relationship Id="rId129" Type="'+R+'/officeDocument" Target="rId130"/><Relationship Id="rId130" Type="'+R+'/officeDocument" Target="rId131"/><Relationship Id="rId131" Type="'+R+'/officeDocument" Target="rId132"/><Relationship Id="rId132" Type="'+R+'/officeDocument" Target="rId133"/><Relationship Id="rId133" Type="'+R+'/officeDocument" Target="rId134"/><Relationship Id="rId134" Type="'+R+'/officeDocument" Target="rId135"/><Relationship Id="rId135" Type="'+R+'/officeDocument" Target="rId136"/><Relationship Id="rId136" Type="'+R+'/officeDocument" Target="rId137"/><Relationship Id="rId137" Type="'+R+'/officeDocument" Target="rId138"/><Relationship Id="rId138" Type="'+R+'/officeDocument" Target="rId139"/><Relationship Id="rId139" Type="'+R+'/officeDocument" Target="rId140"/><Relationship Id="rId140" Type="'+R+'/officeDocument" Target="rId141"/><Relationship Id="rId141" Type="'+R+'/officeDocument" Target="rId142"/><Relationship Id="rId142" Type="'+R+'/officeDocument" Target="rId143"/><Relationship Id="rId143" Type="'+R+'/officeDocument" Target="rId144"/><Relationship Id="rId144" Type="'+R+'/officeDocument" Target="rId145"/><Relationship Id="rId145" Type="'+R+'/officeDocument" Target="rId146"/><Relationship Id="rId146" Type="'+R+'/officeDocument" Target="rId147"/><Relationship Id="rId147" Type="'+R+'/officeDocument" Target="rId148"/><Relationship Id="rId148" Type="'+R+'/officeDocument" Target="rId149"/><Relationship Id="rId149" Type="'+R+'
内容来源: exceljs/exceljs