@microsoft/connected-workbooks
Version:
Microsoft backed, Excel advanced xlsx workbook generation JavaScript library
13 lines (12 loc) • 4.09 kB
JavaScript
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.pqMetadataXmlMockPart2 = exports.pqMetadataXmlMockPart1 = exports.existingSharedStringsXmlMock = exports.sharedStringsXmlMock = exports.queryTableMock = exports.workbookXmlMock = exports.addZeroSheetsXmlMock = exports.sheetsXmlMock = exports.connectedWorkbookXmlMock = void 0;
exports.connectedWorkbookXmlMock = '<ConnectedWorkbook xmlns="http://schemas.microsoft.com/ConnectedWorkbook" version="1.0.0"></ConnectedWorkbook>';
exports.sheetsXmlMock = '<sheetData><row r="1" spans="1:2" x14ac:dyDescent="0.3"><c r="A1" t="str"><v>Column1</v></c><c r="B1" t="str"><v>Column2</v></c></row><row r="2" spans="1:2" x14ac:dyDescent="0.3"><c r="A2" t="1"><v>1</v></c><c r="B2" t="1"><v>2</v></c></row></sheetData>';
exports.addZeroSheetsXmlMock = '<sheetData><row r="1" spans="1:2" x14ac:dyDescent="0.3"><c r="A1" t="str"><v>Column1</v></c><c r="B1" t="str"><v>Column2</v></c></row><row r="2" spans="1:2" x14ac:dyDescent="0.3"><c r="A2" t="str"><v>one</v></c><c r="B2" t="1"><v>0</v></c></row><row r="3" spans="1:2" x14ac:dyDescent="0.3"><c r="A3" t="str"><v>two</v></c><c r="B3" t="1"><v>2</v></c></row></sheetData>';
exports.workbookXmlMock = '<definedName name="ExternalData_1" localSheetId="0" hidden="1">Sheet1!$A$1:$B$2</definedName>';
exports.queryTableMock = '<queryTableRefresh nextId="3"><queryTableFields count="2"><queryTableField id="1" name="Column1" tableColumnId="1"/><queryTableField id="2" name="Column2" tableColumnId="2"/></queryTableFields></queryTableRefresh></queryTable>';
exports.sharedStringsXmlMock = "<sst xmlns=\"http://schemas.openxmlformats.org/spreadsheetml/2006/main\" count=\"2\" uniqueCount=\"2\"><si><t>Query1</t></si><si><t/></si><si><t>newQueryName</t></si></sst>";
exports.existingSharedStringsXmlMock = "<sst xmlns=\"http://schemas.openxmlformats.org/spreadsheetml/2006/main\" count=\"1\" uniqueCount=\"1\"><si><t>newQueryName</t></si><si><t/></si></sst>";
exports.pqMetadataXmlMockPart1 = '<LocalPackageMetadataFile xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><Items> <Item> <ItemLocation> <ItemType>AllFormulas</ItemType> <ItemPath/> </ItemLocation> <StableEntries/> </Item> <Item> <ItemLocation> <ItemType>Formula</ItemType> <ItemPath>Section1/newQueryName</ItemPath> </ItemLocation> <StableEntries> <Entry Type="IsPrivate" Value="l0"/> <Entry Type="FillEnabled" Value="l1"/> <Entry Type="FillObjectType" Value="sTable"/> <Entry Type="FillToDataModelEnabled" Value="l0"/> <Entry Type="BufferNextRefresh" Value="l1"/> <Entry Type="ResultType" Value="sTable"/> <Entry Type="NameUpdatedAfterFill" Value="l0"/> <Entry Type="NavigationStepName" Value="sNavigation"/> <Entry Type="FillTarget" Value="sQuery1"/> <Entry Type="FilledCompleteResultToWorksheet" Value="l1"/> <Entry Type="AddedToDataModel" Value="l0"/> <Entry Type="FillCount" Value="l1"/> <Entry Type="FillErrorCode" Value="sUnknown"/> <Entry Type="FillErrorCount" Value="l0"/>';
exports.pqMetadataXmlMockPart2 = '<Entry Type="FillColumnTypes" Value="sBg=="/> <Entry Type="FillColumnNames" Value="s["Query1"]"/> <Entry Type="FillStatus" Value="sComplete"/> <Entry Type="RelationshipInfoContainer" Value="s{"columnCount":1,"keyColumnNames":[],"queryRelationships":[],"columnIdentities":["Section1/Query1/AutoRemovedColumns1.{Query1,0}"],"ColumnCount":1,"KeyColumnNames":[],"ColumnIdentities":["Section1/Query1/AutoRemovedColumns1.{Query1,0}"],"RelationshipInfo":[]}"/> </StableEntries> </Item> <Item> <ItemLocation> <ItemType>Formula</ItemType> <ItemPath>Section1/newQueryName/Source</ItemPath> </ItemLocation> <StableEntries/> </Item> </Items> </LocalPackageMetadataFile>';