Merge pull request #841 from dolanmiu/feat/workflow-updates

Add workflow and issue template
This commit is contained in:
Dolan
2021-03-20 01:57:55 +00:00
committed by GitHub
4 changed files with 46 additions and 6 deletions

9
.github/ISSUE_TEMPLATE.md vendored Normal file
View File

@ -0,0 +1,9 @@
# Thank you for raising an issue to `docx`
Please do not raise an issue unless it is an **issue**.
- Is your issue a feature request? Are you giving ideas to the community? Are you asking for help? Please raise a ticket in the `Discussions` section:
https://github.com/dolanmiu/docx/discussions
- Is your issue a previously asked? Please respond to that thread instead

View File

@ -93,6 +93,7 @@ jobs:
npm run ts-node -- ./demo/22-right-to-left-text.ts npm run ts-node -- ./demo/22-right-to-left-text.ts
npm run ts-node -- ./demo/23-base64-images.ts npm run ts-node -- ./demo/23-base64-images.ts
npm run ts-node -- ./demo/24-images-to-table-cell.ts npm run ts-node -- ./demo/24-images-to-table-cell.ts
npm run ts-node -- ./demo/25-table-xml-styles.ts
npm run ts-node -- ./demo/26-paragraph-borders.ts npm run ts-node -- ./demo/26-paragraph-borders.ts
npm run ts-node -- ./demo/27-declaritive-styles-3.ts npm run ts-node -- ./demo/27-declaritive-styles-3.ts
npm run ts-node -- ./demo/28-table-of-contents.ts npm run ts-node -- ./demo/28-table-of-contents.ts
@ -102,3 +103,32 @@ jobs:
npm run ts-node -- ./demo/32-merge-and-shade-table-cells.ts npm run ts-node -- ./demo/32-merge-and-shade-table-cells.ts
npm run ts-node -- ./demo/33-sequential-captions.ts npm run ts-node -- ./demo/33-sequential-captions.ts
npm run ts-node -- ./demo/34-floating-tables.ts npm run ts-node -- ./demo/34-floating-tables.ts
npm run ts-node -- ./demo/35-hyperlinks.ts
npm run ts-node -- ./demo/36-image-to-table-cell.ts
npm run ts-node -- ./demo/37-images-to-header-and-footer.ts
npm run ts-node -- ./demo/38-text-wrapping.ts
npm run ts-node -- ./demo/39-page-numbers.ts
npm run ts-node -- ./demo/40-line-numbers.ts
npm run ts-node -- ./demo/41-merge-table-cells-2.ts
npm run ts-node -- ./demo/42-restart-page-numbers.ts
npm run ts-node -- ./demo/43-images-to-table-cell-2.ts
npm run ts-node -- ./demo/44-multiple-columns.ts
npm run ts-node -- ./demo/45-highlighting-text.ts
npm run ts-node -- ./demo/46-shading-text.ts
npm run ts-node -- ./demo/47-number-of-total-pages-section.ts
npm run ts-node -- ./demo/48-vertical-align.ts
npm run ts-node -- ./demo/49-table-borders.ts
npm run ts-node -- ./demo/50-readme-demo.ts
npm run ts-node -- ./demo/51-character-styles.ts
npm run ts-node -- ./demo/52-japanese.ts
npm run ts-node -- ./demo/53-chinese.ts
npm run ts-node -- ./demo/54-custom-properties.ts
npm run ts-node -- ./demo/55-math.ts
npm run ts-node -- ./demo/56-background-color.ts
npm run ts-node -- ./demo/57-add-parent-numbered-lists.ts
npm run ts-node -- ./demo/58-section-types.ts
npm run ts-node -- ./demo/59-header-footer-margins.ts
npm run ts-node -- ./demo/60-track-revisions.ts
npm run ts-node -- ./demo/61-text-frame.ts
npm run ts-node -- ./demo/62-paragraph-spacing.ts
npm run ts-node -- ./demo/63-odd-even-header-footer.ts

View File

@ -18,11 +18,8 @@ const doc = new Document(
{ name: "Subtitle", value: "Subtitle" }, { name: "Subtitle", value: "Subtitle" },
{ name: "Address", value: "Address" }, { name: "Address", value: "Address" },
], ],
sections: [],
}, },
// No file properties
{},
// No sections
[],
); );
Packer.toBuffer(doc).then((buffer) => { Packer.toBuffer(doc).then((buffer) => {

View File

@ -7,8 +7,12 @@ const doc = new Document({
sections: [ sections: [
{ {
properties: { properties: {
header: 100, page: {
footer: 50, margin: {
header: 100,
footer: 50,
},
},
}, },
headers: { headers: {
default: new Header({ default: new Header({