aboutsummaryrefslogtreecommitdiff
path: root/src/client/views/PropertiesView.tsx
diff options
context:
space:
mode:
Diffstat (limited to 'src/client/views/PropertiesView.tsx')
-rw-r--r--src/client/views/PropertiesView.tsx19
1 files changed, 7 insertions, 12 deletions
diff --git a/src/client/views/PropertiesView.tsx b/src/client/views/PropertiesView.tsx
index 6383d4947..9299705ee 100644
--- a/src/client/views/PropertiesView.tsx
+++ b/src/client/views/PropertiesView.tsx
@@ -868,18 +868,13 @@ export class PropertiesView extends ObservableReactComponent<PropertiesViewProps
@computed get colorFil() { return this.containsInkDoc ? StrCast(this.inkDoc?.[DocData].fillColor) : StrCast(this.selectedDoc?.[DocData].fillColor); } // prettier-ignore
set colorFil(value) {
- if (this.containsInkDoc) {
- const childDocs = DocListCast(this.selectedDoc[DocData].data);
- childDocs.forEach(doc => {
- const inkStroke = DocumentView.getDocumentView(doc)?.ComponentView as InkingStroke;
- const { inkData } = inkStroke.inkScaledData();
- if (InkingStroke.IsClosed(inkData)) {
- doc[DocData].fillColor = value || undefined;
- }
- });
- } else {
- this.selectedDoc && (this.selectedDoc[DocData].fillColor = value || undefined);
- }
+ this.selectedStrokes.forEach(doc => {
+ const inkStroke = DocumentView.getDocumentView(doc)?.ComponentView as InkingStroke;
+ const { inkData } = inkStroke.inkScaledData();
+ if (InkingStroke.IsClosed(inkData)) {
+ doc[DocData].fillColor = value || undefined;
+ }
+ });
}
@computed get colorStk() { return this.containsInkDoc ? StrCast(this.inkDoc?.[DocData].color) : StrCast(this.selectedDoc?.[DocData].color); } // prettier-ignore
set colorStk(value) {