diff --git a/tools/admin/operations/library.js b/tools/admin/operations/library.js index 8d77c9b..e2a9e10 100644 --- a/tools/admin/operations/library.js +++ b/tools/admin/operations/library.js @@ -105,14 +105,10 @@ export async function uploadBlockDocs(org, site, blocksToUpload, onProgress) { export async function updateLibraryBlocksJSON(org, site, blockNames) { let existingBlocks = []; - let existingOptions = null; try { const existingBlocksJSON = await fetchBlocksJSON(org, site); existingBlocks = getBlocksArray(existingBlocksJSON); - if (existingBlocksJSON?.options) { - existingOptions = existingBlocksJSON.options; - } } catch (error) { // ignore } @@ -149,10 +145,6 @@ export async function updateLibraryBlocksJSON(org, site, blockNames) { site, ); - if (existingOptions) { - blocksJSON.options = existingOptions; - } - return updateBlocksJSON(org, site, blocksJSON); } diff --git a/tools/admin/utils/doc-generator.js b/tools/admin/utils/doc-generator.js index 0efd0e7..a9053fc 100644 --- a/tools/admin/utils/doc-generator.js +++ b/tools/admin/utils/doc-generator.js @@ -73,49 +73,12 @@ export function generateBlocksJSON(blocks, org, site) { path: block.path || getContentBlockPath(org, site, block.name), })); - const optionsSheet = [ - { - key: 'style', - blocks: 'section-metadata', - values: 'xxs-spacing | xs-spacing | s-spacing | m-spacing | l-spacing | xl-spacing | xxl-spacing | dark | light | quiet', - }, - { - key: 'gap', - blocks: 'ALL', - values: '100 | 200 | 300 | 400 | 500 | 600 | 700 | 800', - }, - { - key: 'background', - blocks: 'section-metadata', - values: 'dark-grey=#676767 | light-grey=#EFEFEF | adobe-red=#FF0000 | blue=#0077B6 | green=#00A36C', - }, - { - key: 'spacing', - blocks: 'section-metadata', - values: '400 | 500 | 600 | 700 | 800', - }, - { - key: 'template', - blocks: 'metadata', - values: 'blog-post | product-page | feature-page', - }, - ]; - return { ':version': 3, - ':names': ['data', 'options'], - ':type': 'multi-sheet', - data: { - total: dataSheet.length, - limit: dataSheet.length, - offset: 0, - data: dataSheet, - }, - options: { - total: optionsSheet.length, - limit: optionsSheet.length, - offset: 0, - data: optionsSheet, - }, + ':type': 'sheet', + total: dataSheet.length, + limit: dataSheet.length, + offset: 0, + data: dataSheet, }; }