From 70a0bf12a1857c81a1bf3f2a59f43ef347890e69 Mon Sep 17 00:00:00 2001 From: Geireann Lindfield Roberts <60007097+geireann@users.noreply.github.com> Date: Tue, 18 Jul 2023 03:14:03 -0400 Subject: resolved pointer down issues with component library --- src/client/views/nodes/FontIconBox/FontIconBox.tsx | 18 ++++++++++++++---- 1 file changed, 14 insertions(+), 4 deletions(-) (limited to 'src/client/views/nodes/FontIconBox/FontIconBox.tsx') diff --git a/src/client/views/nodes/FontIconBox/FontIconBox.tsx b/src/client/views/nodes/FontIconBox/FontIconBox.tsx index e98faf2a0..39be4022e 100644 --- a/src/client/views/nodes/FontIconBox/FontIconBox.tsx +++ b/src/client/views/nodes/FontIconBox/FontIconBox.tsx @@ -211,6 +211,7 @@ export class FontIconBox extends DocComponent() { if (selected) { if (StrCast(selected.type) === DocumentType.COL) { text = StrCast(selected._type_collection); + console.log("collection selected", text) } else { console.log("doc selected", selected.title); dropdown = false; @@ -321,7 +322,17 @@ export class FontIconBox extends DocComponent() { console.log(tooltip, toggleStatus); return ( - + script.script.run({ self: this.rootDoc, value: !toggleStatus, _readOnly_: false })} + /> ) } @@ -365,7 +376,6 @@ export class FontIconBox extends DocComponent() { const color = this.props.styleProvider?.(this.rootDoc, this.props, StyleProp.Color); const backgroundColor = this.props.styleProvider?.(this.rootDoc, this.props, StyleProp.BackgroundColor); const tooltip: string = StrCast(this.rootDoc.toolTip); - // TODO:glr Add label of button type let button: JSX.Element = this.defaultButton; // prettier-ignore @@ -389,9 +399,9 @@ export class FontIconBox extends DocComponent() { break; case ButtonType.ToggleButton: button = this.toggleButton; break; case ButtonType.TextButton: - // Script for checking the outcome of the toggle const script = ScriptCast(this.rootDoc.script); const checkResult = script?.script.run({ _readOnly_: true }).result; + // Script for checking the outcome of the toggle button = (