diff options
author | bobzel <zzzman@gmail.com> | 2021-08-04 20:14:30 -0400 |
---|---|---|
committer | bobzel <zzzman@gmail.com> | 2021-08-04 20:14:30 -0400 |
commit | 43119dc3fc8b156f9e15deab7b2e3dd5b541d7af (patch) | |
tree | a18826ce382637f954504206bf3f50f492040241 /src | |
parent | 3c78da4d7724ca411486083176e394b18177231d (diff) |
fixed toggle ink as a mask.
Diffstat (limited to 'src')
-rw-r--r-- | src/client/views/InkingStroke.tsx | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/src/client/views/InkingStroke.tsx b/src/client/views/InkingStroke.tsx index 21059b330..63cefbf67 100644 --- a/src/client/views/InkingStroke.tsx +++ b/src/client/views/InkingStroke.tsx @@ -44,14 +44,13 @@ export class InkingStroke extends ViewBoxBaseComponent<FieldViewProps, InkDocume CognitiveServices.Inking.Appliers.ConcatenateHandwriting(this.dataDoc, ["inkAnalysis", "handwriting"], [data]); } - @action - public static toggleMask = (inkDoc: Doc) => { + public static toggleMask = action((inkDoc: Doc) => { inkDoc.isInkMask = !inkDoc.isInkMask; inkDoc._backgroundColor = inkDoc.isInkMask ? "rgba(0,0,0,0.7)" : undefined; inkDoc.mixBlendMode = inkDoc.isInkMask ? "hard-light" : undefined; inkDoc.color = "#9b9b9bff"; inkDoc._stayInCollection = inkDoc.isInkMask ? true : undefined; - } + }); /** * Handles the movement of the entire ink object when the user clicks and drags. |