Commit Graph

26 Commits

Author SHA1 Message Date
704c678333 fix: unit tests fix 2023-04-19 16:51:03 +03:00
5950055cca Fix linting and add new lint rules 2022-09-19 20:48:50 +01:00
982d923553 Improve import alias
@file/ and @export/ instead of file/ and export/ etc
2022-06-26 23:26:42 +01:00
f378c37b62 Test at spec.ts for referenceConfigMap 2021-07-30 11:59:49 +03:00
0b88cb0ca5 #548 #508 Restart numbered lists 2021-03-12 03:58:05 +00:00
643e3c2f84 Finish making numbering declarative 2019-11-08 03:11:19 +00:00
8eff6bd0cf Declarative numbering work 2019-11-01 01:57:01 +00:00
591b2f4e04 Declarative styles 2019-10-04 01:20:41 +01:00
04b6d8e54a Declarative hyperlinks, bookmarks, tab stops and page breaks 2019-09-30 22:56:21 +01:00
099eb1d202 Merge branch 'master' of github.com:dolanmiu/docx into feat/declaritive
# Conflicts:
#	src/file/paragraph/run/run.ts
2019-08-06 21:06:06 +01:00
ebc7dca949 Fix tests 2019-08-06 13:39:05 +03:00
fa710d1ba6 Highlighting 2019-08-06 11:13:43 +03:00
cb42c74a8d Make Paragraph declaritive 2019-06-12 01:03:36 +01:00
77edf8862b Added constant EMPTY_OBJECT (an empty sealed object) that is used to indicate to the xml library that an empty XML element should be generated, and use it in the JSON hardcoded into the tests. 2019-04-10 13:47:38 -04:00
bb1604cd8f Turn back on no-null-keyword. Use empty object instead of null to signal to the xml library that an empty element should be produced. Update the related tests.
Related to #306
2019-04-10 01:28:37 -04:00
816cb54b14 Optimize XML output by properly constructing objects to send to the xml library so that it can produce proper empty elements.
Rework the way attributes are stored in ImportedXmlComponent to match elsewhere (required allowing for a null xmlKeys in the XmlAttributeComponent interface).
Rework the way paragraphs get added to the end of table cells if needed.
The goal in both reworks is to not mess around with the objects output from `prepForXml` if we can avoid it.
Made the output of RunProperties, ParagraphProperties, TableCellProperties, TableRowProperties, and TableProperties all optional based on whether they contain any attributes or children.  Changed code in PageBorders, TableCellMargin, and TableCellBorders that implemented this same thing by overriding `prepForXml` so that it uses the new XmlComponent subclass instead.
Removed commented out code that attempted to fix-up XML output and make proper empty elements.
Fixed all affected tests.
Turn off `no-null-keyword` in the linter as we need to use null to signal to the `xml` library to create an empty element with no attributes (`undefined` will not work in its place).

Fixes #306
2019-04-09 05:27:18 -04:00
bf18154fcf Fix style 2018-12-07 15:34:27 +00:00
7639b60b15 Refactor to separate classes in their specific files an tests improuvements for styles 2018-11-13 11:04:03 -02:00
7b47dadede Fix Prettier styling 2018-11-11 22:54:35 +00:00
7980f14efb Introduce some functional programming techniques 2018-11-02 02:51:57 +00:00
4742cf0f3f Clean imports 2018-10-26 01:04:07 +01:00
12c8cb93f6 Clean up API 2018-08-07 01:25:28 +01:00
974eb510ef Fix style 2018-07-24 12:37:15 +08:00
1fad9a666e Let fonts suit for more characters 2018-07-24 12:24:26 +08:00
e93d6799fd Made project Prettier compliant 2018-01-23 01:33:12 +00:00
2358139a6b Change docx folder to more appropriate "file" folder 2017-12-20 01:03:20 +00:00