From 7fb2e7648f516705cda93ab50c65219d44386bc1 Mon Sep 17 00:00:00 2001 From: Kirk Swenson Date: Wed, 27 Nov 2024 15:50:04 -0800 Subject: [PATCH] Odds and ends (#1661) * chore: fix lint warnings * chore: update README --- v3/README.md | 1 + v3/src/components/tool-shelf/tool-shelf.test.tsx | 2 +- v3/src/lib/handle-cfm-event.ts | 2 ++ 3 files changed, 4 insertions(+), 1 deletion(-) diff --git a/v3/README.md b/v3/README.md index 98a366ea4..051470ed1 100644 --- a/v3/README.md +++ b/v3/README.md @@ -130,6 +130,7 @@ Inside of your `package.json` file: Various developer features can be enabled by adding a `debug` local storage key with one or more of the following flags separated by spaces. Local storage is specific to the domain that CODAP is running on. In Chrome local storage can be edited by opening the developer tools and going to the "Application" tab. Then find "Storage/Local storage" and the domain that CODAP is running on. +- `caseIds` displays the id of each case in the index column of the case table - `cfmEvents` console log all events received from the CFM - `cfmLocalStorage` enable the CFM local storage provider so documents can be saved and loaded from the browser's local storage - `cfmNoAutoSave` disable CFM auto-save for any document loaded by the CFM diff --git a/v3/src/components/tool-shelf/tool-shelf.test.tsx b/v3/src/components/tool-shelf/tool-shelf.test.tsx index a433eb8db..90107fe4c 100644 --- a/v3/src/components/tool-shelf/tool-shelf.test.tsx +++ b/v3/src/components/tool-shelf/tool-shelf.test.tsx @@ -4,7 +4,7 @@ import { ToolShelf } from "./tool-shelf" import { render, screen } from "@testing-library/react" import { createCodapDocument } from "../../models/codap/create-codap-document" import { IDocumentModel } from "../../models/document/document" -import { ITestTileContent, TestTileContent } from "../../test/test-tile-content" +import { TestTileContent } from "../../test/test-tile-content" import { TileModel } from "../../models/tiles/tile-model" // way to get a writable reference to libDebug diff --git a/v3/src/lib/handle-cfm-event.ts b/v3/src/lib/handle-cfm-event.ts index f53991cf2..1a2964043 100644 --- a/v3/src/lib/handle-cfm-event.ts +++ b/v3/src/lib/handle-cfm-event.ts @@ -93,10 +93,12 @@ export async function handleCFMEvent(cfmClient: CloudFileManagerClient, event: C // The message and stack of the error are logged in a group so it is easier // to view them in the console. if (isError(e)) { + /* eslint-disable no-console */ console.groupCollapsed("Details of document error") console.log(e.message) console.log(e.stack) console.groupEnd() + /* eslint-enable no-console */ } // Have the CFM show an error dialog