diff --git a/CHANGELOG.md b/CHANGELOG.md index 8ab28578..63c2851b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -8,7 +8,7 @@ and this project adheres to ### Added -- ✨(frontend) enable ODT export for documents #1524 +- ✨(export) enable ODT export for documents #1524 - ✨(frontend) improve mobile UX by showing subdocs count #1540 ### Fixed @@ -17,13 +17,14 @@ and this project adheres to - ♿(frontend) improve ARIA in doc grid and editor for a11y #1519 - ♿(frontend) improve accessibility and styling of summary table #1528 - ♿(frontend) add focus trap and enter key support to remove doc modal #1531 -- 🐛(docx) fix image overflow by limiting width to 600px during export #1525 - 🐛(frontend) preserve @ character when esc is pressed after typing it #1512 - 🐛(frontend) make summary button fixed to remain visible during scroll #1581 - 🐛(frontend) fix pdf embed to use full width #1526 - 🐛(frontend) fix fallback translations with Trans #1620 -- 🐛(pdf) fix table cell alignment issue in exported documents #1582 -- 🐛(pdf) preserve image aspect ratio in PDF export #1622 +- 🐛(export) fix image overflow by limiting width to 600px during export #1525 +- 🐛(export) fix table cell alignment issue in exported documents #1582 +- 🐛(export) preserve image aspect ratio in PDF export #1622 +- 🐛(export) Export fails when paste with style #1552 ### Security diff --git a/src/frontend/apps/impress/src/features/docs/doc-export/mappingDocx.tsx b/src/frontend/apps/impress/src/features/docs/doc-export/mappingDocx.tsx index 054a8e30..1d1f607c 100644 --- a/src/frontend/apps/impress/src/features/docs/doc-export/mappingDocx.tsx +++ b/src/frontend/apps/impress/src/features/docs/doc-export/mappingDocx.tsx @@ -39,39 +39,5 @@ export const docxDocsSchemaMappings: DocsExporterDocx['mappings'] = { shading: { fill: 'DCDCDC' }, } : {}, - // If the color is not defined, we fall back to default colors - backgroundColor: (val, exporter) => { - if (!val) { - return {}; - } - - const backgroundColor = exporter.options.colors?.[val]?.background; - - if (!backgroundColor) { - return {}; - } - - return { - shading: { - fill: backgroundColor.slice(1), - }, - }; - }, - // If the color is not defined, we fall back to default colors - textColor: (val, exporter) => { - if (!val) { - return {}; - } - - const color = exporter.options.colors?.[val]?.text; - - if (!color) { - return {}; - } - - return { - color: color.slice(1), - }; - }, }, }; diff --git a/src/frontend/apps/impress/src/features/docs/doc-export/mappingODT.ts b/src/frontend/apps/impress/src/features/docs/doc-export/mappingODT.ts index 88fd77c1..224190f1 100644 --- a/src/frontend/apps/impress/src/features/docs/doc-export/mappingODT.ts +++ b/src/frontend/apps/impress/src/features/docs/doc-export/mappingODT.ts @@ -30,32 +30,4 @@ export const odtDocsSchemaMappings: DocsExporterODT['mappings'] = { interlinkingSearchInline: () => null, interlinkingLinkInline: inlineContentMappingInterlinkingLinkODT, }, - styleMapping: { - ...odtDefaultSchemaMappings.styleMapping, - textColor: (val, exporter): Record => { - if (!val) { - return {}; - } - const color = exporter.options.colors?.[val]?.text; - - if (!color) { - return {}; - } - - return { 'fo:color': color }; - }, - - backgroundColor: (val, exporter): Record => { - if (!val) { - return {}; - } - const color = exporter.options.colors?.[val]?.background; - - if (!color) { - return {}; - } - - return { 'fo:background-color': color }; - }, - }, }; diff --git a/src/frontend/apps/impress/src/features/docs/doc-export/mappingPDF.tsx b/src/frontend/apps/impress/src/features/docs/doc-export/mappingPDF.tsx index ae34f646..0d0c7cbd 100644 --- a/src/frontend/apps/impress/src/features/docs/doc-export/mappingPDF.tsx +++ b/src/frontend/apps/impress/src/features/docs/doc-export/mappingPDF.tsx @@ -39,37 +39,5 @@ export const pdfDocsSchemaMappings: DocsExporterPDF['mappings'] = { // that is not available in italics code: (enabled?: boolean) => enabled ? { fontFamily: 'Courier', backgroundColor: '#dcdcdc' } : {}, - // If the color is not defined, we fall back to default colors - textColor: (val, exporter) => { - if (!val) { - return {}; - } - - const color = exporter.options.colors?.[val]?.text; - - if (!color) { - return {}; - } - - return { - color, - }; - }, - // If the color is not defined, we fall back to default colors - backgroundColor: (val, exporter) => { - if (!val) { - return {}; - } - - const backgroundColor = exporter.options.colors?.[val]?.background; - - if (!backgroundColor) { - return {}; - } - - return { - backgroundColor, - }; - }, }, };