Skip to content

Commit f85d159

Browse files
authored
[Word] (tools) Filter ImportedStylesConflictBehavior parameters when WordApiDesktop is removed (#2179)
* Filter ImportedStylesConflictBehavior parameters when WordApiDesktop is removed * Removing parameter note when parameter removed * Fix duplicate methods * Verify clean run
1 parent 711350e commit f85d159

File tree

32 files changed

+56
-380
lines changed

32 files changed

+56
-380
lines changed

docs/docs-ref-autogen/office/office/office.documentselectionchangedeventargs.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ remarks: |-
1010
#### Examples
1111
1212
```TypeScript
13-
// The following example adds an event handler for the SelectionChanged event of a document
13+
// The following example adds an event handler for the SelectionChanged event of a document.
1414
function addSelectionChangedEventHandler() {
1515
Office.context.document.addHandlerAsync(Office.EventType.DocumentSelectionChanged, MyHandler);
1616
}

docs/docs-ref-autogen/office_release/office/office.documentselectionchangedeventargs.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ remarks: |-
1010
#### Examples
1111
1212
```TypeScript
13-
// The following example adds an event handler for the SelectionChanged event of a document
13+
// The following example adds an event handler for the SelectionChanged event of a document.
1414
function addSelectionChangedEventHandler() {
1515
Office.context.document.addHandlerAsync(Office.EventType.DocumentSelectionChanged, MyHandler);
1616
}

docs/docs-ref-autogen/word_1_6/word/word.document.yml

Lines changed: 3 additions & 40 deletions
Original file line numberDiff line numberDiff line change
@@ -661,18 +661,15 @@ methods:
661661
return:
662662
type: '<xref uid="word!Word.StyleCollection:class" />'
663663
description: ''
664-
- name: 'importStylesFromJson(stylesJson, importedStylesConflictBehavior)'
664+
- name: importStylesFromJson(stylesJson)
665665
uid: 'word!Word.Document#importStylesFromJson:member(1)'
666666
package: word!
667-
fullName: 'importStylesFromJson(stylesJson, importedStylesConflictBehavior)'
667+
fullName: importStylesFromJson(stylesJson)
668668
summary: Import styles from a JSON-formatted string.
669669
remarks: >-
670670
\[ [API set: WordApi 1.6](/javascript/api/requirement-sets/word/word-api-requirement-sets) \]
671671
672672
673-
Note: The `importedStylesConflictBehavior` parameter was introduced in WordApiDesktop 1.1.
674-
675-
676673
#### Examples
677674
678675
@@ -696,45 +693,11 @@ methods:
696693
isPreview: false
697694
isDeprecated: false
698695
syntax:
699-
content: >-
700-
importStylesFromJson(stylesJson: string, importedStylesConflictBehavior?: Word.ImportedStylesConflictBehavior):
701-
OfficeExtension.ClientResult<string[]>;
696+
content: 'importStylesFromJson(stylesJson: string): OfficeExtension.ClientResult<string[]>;'
702697
parameters:
703698
- id: stylesJson
704699
description: Required. A JSON-formatted string representing the styles.
705700
type: string
706-
- id: importedStylesConflictBehavior
707-
description: >-
708-
Optional. Specifies how to handle any imported styles with the same name as existing styles in the current
709-
document.
710-
type: Word.ImportedStylesConflictBehavior
711-
return:
712-
type: '<xref uid="office!OfficeExtension.ClientResult:class" />&lt;string[]&gt;'
713-
description: ''
714-
- name: 'importStylesFromJson(stylesJson, importedStylesConflictBehaviorString)'
715-
uid: 'word!Word.Document#importStylesFromJson:member(2)'
716-
package: word!
717-
fullName: 'importStylesFromJson(stylesJson, importedStylesConflictBehaviorString)'
718-
summary: Import styles from a JSON-formatted string.
719-
remarks: |-
720-
\[ [API set: WordApi 1.6](/javascript/api/requirement-sets/word/word-api-requirement-sets) \]
721-
722-
Note: The `importedStylesConflictBehavior` parameter was introduced in WordApiDesktop 1.1.
723-
isPreview: false
724-
isDeprecated: false
725-
syntax:
726-
content: >-
727-
importStylesFromJson(stylesJson: string, importedStylesConflictBehaviorString?: "Ignore" | "Overwrite" |
728-
"CreateNew"): OfficeExtension.ClientResult<string[]>;
729-
parameters:
730-
- id: stylesJson
731-
description: Required. A JSON-formatted string representing the styles.
732-
type: string
733-
- id: importedStylesConflictBehaviorString
734-
description: >-
735-
Optional. Specifies how to handle any imported styles with the same name as existing styles in the current
736-
document.
737-
type: '"Ignore" | "Overwrite" | "CreateNew"'
738701
return:
739702
type: '<xref uid="office!OfficeExtension.ClientResult:class" />&lt;string[]&gt;'
740703
description: ''

docs/docs-ref-autogen/word_1_7/word/word.document.yml

Lines changed: 3 additions & 40 deletions
Original file line numberDiff line numberDiff line change
@@ -678,18 +678,15 @@ methods:
678678
return:
679679
type: '<xref uid="word!Word.StyleCollection:class" />'
680680
description: ''
681-
- name: 'importStylesFromJson(stylesJson, importedStylesConflictBehavior)'
681+
- name: importStylesFromJson(stylesJson)
682682
uid: 'word!Word.Document#importStylesFromJson:member(1)'
683683
package: word!
684-
fullName: 'importStylesFromJson(stylesJson, importedStylesConflictBehavior)'
684+
fullName: importStylesFromJson(stylesJson)
685685
summary: Import styles from a JSON-formatted string.
686686
remarks: >-
687687
\[ [API set: WordApi 1.6](/javascript/api/requirement-sets/word/word-api-requirement-sets) \]
688688
689689
690-
Note: The `importedStylesConflictBehavior` parameter was introduced in WordApiDesktop 1.1.
691-
692-
693690
#### Examples
694691
695692
@@ -713,45 +710,11 @@ methods:
713710
isPreview: false
714711
isDeprecated: false
715712
syntax:
716-
content: >-
717-
importStylesFromJson(stylesJson: string, importedStylesConflictBehavior?: Word.ImportedStylesConflictBehavior):
718-
OfficeExtension.ClientResult<string[]>;
713+
content: 'importStylesFromJson(stylesJson: string): OfficeExtension.ClientResult<string[]>;'
719714
parameters:
720715
- id: stylesJson
721716
description: Required. A JSON-formatted string representing the styles.
722717
type: string
723-
- id: importedStylesConflictBehavior
724-
description: >-
725-
Optional. Specifies how to handle any imported styles with the same name as existing styles in the current
726-
document.
727-
type: Word.ImportedStylesConflictBehavior
728-
return:
729-
type: '<xref uid="office!OfficeExtension.ClientResult:class" />&lt;string[]&gt;'
730-
description: ''
731-
- name: 'importStylesFromJson(stylesJson, importedStylesConflictBehaviorString)'
732-
uid: 'word!Word.Document#importStylesFromJson:member(2)'
733-
package: word!
734-
fullName: 'importStylesFromJson(stylesJson, importedStylesConflictBehaviorString)'
735-
summary: Import styles from a JSON-formatted string.
736-
remarks: |-
737-
\[ [API set: WordApi 1.6](/javascript/api/requirement-sets/word/word-api-requirement-sets) \]
738-
739-
Note: The `importedStylesConflictBehavior` parameter was introduced in WordApiDesktop 1.1.
740-
isPreview: false
741-
isDeprecated: false
742-
syntax:
743-
content: >-
744-
importStylesFromJson(stylesJson: string, importedStylesConflictBehaviorString?: "Ignore" | "Overwrite" |
745-
"CreateNew"): OfficeExtension.ClientResult<string[]>;
746-
parameters:
747-
- id: stylesJson
748-
description: Required. A JSON-formatted string representing the styles.
749-
type: string
750-
- id: importedStylesConflictBehaviorString
751-
description: >-
752-
Optional. Specifies how to handle any imported styles with the same name as existing styles in the current
753-
document.
754-
type: '"Ignore" | "Overwrite" | "CreateNew"'
755718
return:
756719
type: '<xref uid="office!OfficeExtension.ClientResult:class" />&lt;string[]&gt;'
757720
description: ''

docs/docs-ref-autogen/word_1_8/word/word.document.yml

Lines changed: 3 additions & 40 deletions
Original file line numberDiff line numberDiff line change
@@ -678,18 +678,15 @@ methods:
678678
return:
679679
type: '<xref uid="word!Word.StyleCollection:class" />'
680680
description: ''
681-
- name: 'importStylesFromJson(stylesJson, importedStylesConflictBehavior)'
681+
- name: importStylesFromJson(stylesJson)
682682
uid: 'word!Word.Document#importStylesFromJson:member(1)'
683683
package: word!
684-
fullName: 'importStylesFromJson(stylesJson, importedStylesConflictBehavior)'
684+
fullName: importStylesFromJson(stylesJson)
685685
summary: Import styles from a JSON-formatted string.
686686
remarks: >-
687687
\[ [API set: WordApi 1.6](/javascript/api/requirement-sets/word/word-api-requirement-sets) \]
688688
689689
690-
Note: The `importedStylesConflictBehavior` parameter was introduced in WordApiDesktop 1.1.
691-
692-
693690
#### Examples
694691
695692
@@ -713,45 +710,11 @@ methods:
713710
isPreview: false
714711
isDeprecated: false
715712
syntax:
716-
content: >-
717-
importStylesFromJson(stylesJson: string, importedStylesConflictBehavior?: Word.ImportedStylesConflictBehavior):
718-
OfficeExtension.ClientResult<string[]>;
713+
content: 'importStylesFromJson(stylesJson: string): OfficeExtension.ClientResult<string[]>;'
719714
parameters:
720715
- id: stylesJson
721716
description: Required. A JSON-formatted string representing the styles.
722717
type: string
723-
- id: importedStylesConflictBehavior
724-
description: >-
725-
Optional. Specifies how to handle any imported styles with the same name as existing styles in the current
726-
document.
727-
type: Word.ImportedStylesConflictBehavior
728-
return:
729-
type: '<xref uid="office!OfficeExtension.ClientResult:class" />&lt;string[]&gt;'
730-
description: ''
731-
- name: 'importStylesFromJson(stylesJson, importedStylesConflictBehaviorString)'
732-
uid: 'word!Word.Document#importStylesFromJson:member(2)'
733-
package: word!
734-
fullName: 'importStylesFromJson(stylesJson, importedStylesConflictBehaviorString)'
735-
summary: Import styles from a JSON-formatted string.
736-
remarks: |-
737-
\[ [API set: WordApi 1.6](/javascript/api/requirement-sets/word/word-api-requirement-sets) \]
738-
739-
Note: The `importedStylesConflictBehavior` parameter was introduced in WordApiDesktop 1.1.
740-
isPreview: false
741-
isDeprecated: false
742-
syntax:
743-
content: >-
744-
importStylesFromJson(stylesJson: string, importedStylesConflictBehaviorString?: "Ignore" | "Overwrite" |
745-
"CreateNew"): OfficeExtension.ClientResult<string[]>;
746-
parameters:
747-
- id: stylesJson
748-
description: Required. A JSON-formatted string representing the styles.
749-
type: string
750-
- id: importedStylesConflictBehaviorString
751-
description: >-
752-
Optional. Specifies how to handle any imported styles with the same name as existing styles in the current
753-
document.
754-
type: '"Ignore" | "Overwrite" | "CreateNew"'
755718
return:
756719
type: '<xref uid="office!OfficeExtension.ClientResult:class" />&lt;string[]&gt;'
757720
description: ''

docs/docs-ref-autogen/word_1_9/word/word.document.yml

Lines changed: 3 additions & 40 deletions
Original file line numberDiff line numberDiff line change
@@ -678,18 +678,15 @@ methods:
678678
return:
679679
type: '<xref uid="word!Word.StyleCollection:class" />'
680680
description: ''
681-
- name: 'importStylesFromJson(stylesJson, importedStylesConflictBehavior)'
681+
- name: importStylesFromJson(stylesJson)
682682
uid: 'word!Word.Document#importStylesFromJson:member(1)'
683683
package: word!
684-
fullName: 'importStylesFromJson(stylesJson, importedStylesConflictBehavior)'
684+
fullName: importStylesFromJson(stylesJson)
685685
summary: Import styles from a JSON-formatted string.
686686
remarks: >-
687687
\[ [API set: WordApi 1.6](/javascript/api/requirement-sets/word/word-api-requirement-sets) \]
688688
689689
690-
Note: The `importedStylesConflictBehavior` parameter was introduced in WordApiDesktop 1.1.
691-
692-
693690
#### Examples
694691
695692
@@ -713,45 +710,11 @@ methods:
713710
isPreview: false
714711
isDeprecated: false
715712
syntax:
716-
content: >-
717-
importStylesFromJson(stylesJson: string, importedStylesConflictBehavior?: Word.ImportedStylesConflictBehavior):
718-
OfficeExtension.ClientResult<string[]>;
713+
content: 'importStylesFromJson(stylesJson: string): OfficeExtension.ClientResult<string[]>;'
719714
parameters:
720715
- id: stylesJson
721716
description: Required. A JSON-formatted string representing the styles.
722717
type: string
723-
- id: importedStylesConflictBehavior
724-
description: >-
725-
Optional. Specifies how to handle any imported styles with the same name as existing styles in the current
726-
document.
727-
type: Word.ImportedStylesConflictBehavior
728-
return:
729-
type: '<xref uid="office!OfficeExtension.ClientResult:class" />&lt;string[]&gt;'
730-
description: ''
731-
- name: 'importStylesFromJson(stylesJson, importedStylesConflictBehaviorString)'
732-
uid: 'word!Word.Document#importStylesFromJson:member(2)'
733-
package: word!
734-
fullName: 'importStylesFromJson(stylesJson, importedStylesConflictBehaviorString)'
735-
summary: Import styles from a JSON-formatted string.
736-
remarks: |-
737-
\[ [API set: WordApi 1.6](/javascript/api/requirement-sets/word/word-api-requirement-sets) \]
738-
739-
Note: The `importedStylesConflictBehavior` parameter was introduced in WordApiDesktop 1.1.
740-
isPreview: false
741-
isDeprecated: false
742-
syntax:
743-
content: >-
744-
importStylesFromJson(stylesJson: string, importedStylesConflictBehaviorString?: "Ignore" | "Overwrite" |
745-
"CreateNew"): OfficeExtension.ClientResult<string[]>;
746-
parameters:
747-
- id: stylesJson
748-
description: Required. A JSON-formatted string representing the styles.
749-
type: string
750-
- id: importedStylesConflictBehaviorString
751-
description: >-
752-
Optional. Specifies how to handle any imported styles with the same name as existing styles in the current
753-
document.
754-
type: '"Ignore" | "Overwrite" | "CreateNew"'
755718
return:
756719
type: '<xref uid="office!OfficeExtension.ClientResult:class" />&lt;string[]&gt;'
757720
description: ''

docs/docs-ref-autogen/word_online/word/word.document.yml

Lines changed: 3 additions & 40 deletions
Original file line numberDiff line numberDiff line change
@@ -678,18 +678,15 @@ methods:
678678
return:
679679
type: '<xref uid="word!Word.StyleCollection:class" />'
680680
description: ''
681-
- name: 'importStylesFromJson(stylesJson, importedStylesConflictBehavior)'
681+
- name: importStylesFromJson(stylesJson)
682682
uid: 'word!Word.Document#importStylesFromJson:member(1)'
683683
package: word!
684-
fullName: 'importStylesFromJson(stylesJson, importedStylesConflictBehavior)'
684+
fullName: importStylesFromJson(stylesJson)
685685
summary: Import styles from a JSON-formatted string.
686686
remarks: >-
687687
\[ [API set: WordApi 1.6](/javascript/api/requirement-sets/word/word-api-requirement-sets) \]
688688
689689
690-
Note: The `importedStylesConflictBehavior` parameter was introduced in WordApiDesktop 1.1.
691-
692-
693690
#### Examples
694691
695692
@@ -713,45 +710,11 @@ methods:
713710
isPreview: false
714711
isDeprecated: false
715712
syntax:
716-
content: >-
717-
importStylesFromJson(stylesJson: string, importedStylesConflictBehavior?: Word.ImportedStylesConflictBehavior):
718-
OfficeExtension.ClientResult<string[]>;
713+
content: 'importStylesFromJson(stylesJson: string): OfficeExtension.ClientResult<string[]>;'
719714
parameters:
720715
- id: stylesJson
721716
description: Required. A JSON-formatted string representing the styles.
722717
type: string
723-
- id: importedStylesConflictBehavior
724-
description: >-
725-
Optional. Specifies how to handle any imported styles with the same name as existing styles in the current
726-
document.
727-
type: Word.ImportedStylesConflictBehavior
728-
return:
729-
type: '<xref uid="office!OfficeExtension.ClientResult:class" />&lt;string[]&gt;'
730-
description: ''
731-
- name: 'importStylesFromJson(stylesJson, importedStylesConflictBehaviorString)'
732-
uid: 'word!Word.Document#importStylesFromJson:member(2)'
733-
package: word!
734-
fullName: 'importStylesFromJson(stylesJson, importedStylesConflictBehaviorString)'
735-
summary: Import styles from a JSON-formatted string.
736-
remarks: |-
737-
\[ [API set: WordApi 1.6](/javascript/api/requirement-sets/word/word-api-requirement-sets) \]
738-
739-
Note: The `importedStylesConflictBehavior` parameter was introduced in WordApiDesktop 1.1.
740-
isPreview: false
741-
isDeprecated: false
742-
syntax:
743-
content: >-
744-
importStylesFromJson(stylesJson: string, importedStylesConflictBehaviorString?: "Ignore" | "Overwrite" |
745-
"CreateNew"): OfficeExtension.ClientResult<string[]>;
746-
parameters:
747-
- id: stylesJson
748-
description: Required. A JSON-formatted string representing the styles.
749-
type: string
750-
- id: importedStylesConflictBehaviorString
751-
description: >-
752-
Optional. Specifies how to handle any imported styles with the same name as existing styles in the current
753-
document.
754-
type: '"Ignore" | "Overwrite" | "CreateNew"'
755718
return:
756719
type: '<xref uid="office!OfficeExtension.ClientResult:class" />&lt;string[]&gt;'
757720
description: ''

docs/includes/word-1_6.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
|[Body](/javascript/api/word/word.body)|[getTrackedChanges()](/javascript/api/word/word.body#word-word-body-gettrackedchanges-member(1))|Gets the collection of the TrackedChange objects in the body.|
55
|[ContentControl](/javascript/api/word/word.contentcontrol)|[getTrackedChanges()](/javascript/api/word/word.contentcontrol#word-word-contentcontrol-gettrackedchanges-member(1))|Gets the collection of the TrackedChange objects in the content control.|
66
|[Document](/javascript/api/word/word.document)|[getParagraphByUniqueLocalId(id: string)](/javascript/api/word/word.document#word-word-document-getparagraphbyuniquelocalid-member(1))|Gets the paragraph by its unique local ID.|
7-
||[importStylesFromJson(stylesJson: string, importedStylesConflictBehavior?: Word.ImportedStylesConflictBehavior)](/javascript/api/word/word.document#word-word-document-importstylesfromjson-member(1))|Import styles from a JSON-formatted string.|
7+
||[importStylesFromJson(stylesJson: string)](/javascript/api/word/word.document#word-word-document-importstylesfromjson-member(1))|Import styles from a JSON-formatted string.|
88
||[onParagraphAdded](/javascript/api/word/word.document#word-word-document-onparagraphadded-member)|Occurs when the user adds new paragraphs.|
99
||[onParagraphChanged](/javascript/api/word/word.document#word-word-document-onparagraphchanged-member)|Occurs when the user changes paragraphs.|
1010
||[onParagraphDeleted](/javascript/api/word/word.document#word-word-document-onparagraphdeleted-member)|Occurs when the user deletes paragraphs.|

docs/includes/word-desktop-1.1.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@
1717
||[outsideBorderType](/javascript/api/word/word.bordercollection#word-word-bordercollection-outsidebordertype-member)|Specifies the border type of the outside borders.|
1818
||[outsideBorderWidth](/javascript/api/word/word.bordercollection#word-word-bordercollection-outsideborderwidth-member)|Specifies the width of the outside borders.|
1919
|[Document](/javascript/api/word/word.document)|[compare(filePath: string, documentCompareOptions?: Word.DocumentCompareOptions)](/javascript/api/word/word.document#word-word-document-compare-member(1))|Displays revision marks that indicate where the specified document differs from another document.|
20+
||[importStylesFromJson(stylesJson: string, importedStylesConflictBehavior?: Word.ImportedStylesConflictBehavior)](/javascript/api/word/word.document#word-word-document-importstylesfromjson-member(1))|Import styles from a JSON-formatted string.|
2021
|[DocumentCompareOptions](/javascript/api/word/word.documentcompareoptions)|[addToRecentFiles](/javascript/api/word/word.documentcompareoptions#word-word-documentcompareoptions-addtorecentfiles-member)|True adds the document to the list of recently used files on the File menu.|
2122
||[authorName](/javascript/api/word/word.documentcompareoptions#word-word-documentcompareoptions-authorname-member)|The reviewer name associated with the differences generated by the comparison.|
2223
||[compareTarget](/javascript/api/word/word.documentcompareoptions#word-word-documentcompareoptions-comparetarget-member)|The target document for the comparison.|

generate-docs/api-extractor-inputs-word-release/word_1_1/word.d.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -777,7 +777,6 @@ export declare namespace Word {
777777

778778

779779

780-
781780
/**
782781
* Saves the document.
783782
*

0 commit comments

Comments
 (0)