diff options
Diffstat (limited to 'src/client')
| -rw-r--r-- | src/client/Network.ts | 2 | ||||
| -rw-r--r-- | src/client/documents/DocUtils.ts | 3 | ||||
| -rw-r--r-- | src/client/documents/Documents.ts | 4 | ||||
| -rw-r--r-- | src/client/util/DictationManager.ts | 4 | ||||
| -rw-r--r-- | src/client/util/DragManager.ts | 1 | ||||
| -rw-r--r-- | src/client/util/History.ts | 1 | ||||
| -rw-r--r-- | src/client/util/InteractionUtils.tsx | 1 | ||||
| -rw-r--r-- | src/client/util/ScriptingGlobals.ts | 2 | ||||
| -rw-r--r-- | src/client/util/SearchUtil.ts | 1 | ||||
| -rw-r--r-- | src/client/util/SerializationHelper.ts | 1 | ||||
| -rw-r--r-- | src/client/util/UndoManager.ts | 1 | ||||
| -rw-r--r-- | src/client/views/DocViewUtils.ts | 1 |
12 files changed, 4 insertions, 18 deletions
diff --git a/src/client/Network.ts b/src/client/Network.ts index 17f8a6534..204fcf0ac 100644 --- a/src/client/Network.ts +++ b/src/client/Network.ts @@ -9,7 +9,7 @@ import { Upload } from '../server/SharedMediaTypes'; * mainly provides methods that the client can use to begin the process of * interacting with the server, such as fetching or uploading files. */ -// eslint-disable-next-line @typescript-eslint/no-namespace + export namespace Networking { export async function FetchFromServer(relativeRoute: string) { return (await fetch(relativeRoute)).text(); diff --git a/src/client/documents/DocUtils.ts b/src/client/documents/DocUtils.ts index 0168e0a3b..30b71a09b 100644 --- a/src/client/documents/DocUtils.ts +++ b/src/client/documents/DocUtils.ts @@ -40,7 +40,6 @@ const { DFLT_IMAGE_NATIVE_DIM } = require('../views/global/globalCssVariables.mo const defaultNativeImageDim = Number(DFLT_IMAGE_NATIVE_DIM.replace('px', '')); -// eslint-disable-next-line @typescript-eslint/no-namespace export namespace DocUtils { function matchFieldValue(doc: Doc, key: string, valueIn: unknown): boolean { let value = valueIn; @@ -467,7 +466,7 @@ export namespace DocUtils { .concat(userTypes) .concat(clickFuncs) .map(btnDoc => (btnDoc.dragFactory as Doc) || btnDoc) - .filter(doc => doc.isTemplateDoc); + .filter(d => d.isTemplateDoc); // bcz: this is hacky -- want to have different templates be applied depending on the "type" of a document. but type is not reliable and there could be other types of template searches so this should be generalized // first try to find a template that matches the specific document type (<typeName>_<templateName>). otherwise, fallback to a general match on <templateName> !docLayoutTemplate && diff --git a/src/client/documents/Documents.ts b/src/client/documents/Documents.ts index 9ce465538..6b5469cca 100644 --- a/src/client/documents/Documents.ts +++ b/src/client/documents/Documents.ts @@ -494,9 +494,7 @@ export class DocumentOptions { export const DocOptions = new DocumentOptions(); -// eslint-disable-next-line @typescript-eslint/no-namespace export namespace Docs { - // eslint-disable-next-line @typescript-eslint/no-namespace export namespace Prototypes { type LayoutSource = { LayoutString: (key: string) => string }; type PrototypeTemplate = { @@ -654,7 +652,7 @@ export namespace Docs { * Encapsulates the factory used to create new document instances * delegated from top-level prototypes */ - // eslint-disable-next-line @typescript-eslint/no-namespace + export namespace Create { /** * This function receives the relevant document prototype and uses diff --git a/src/client/util/DictationManager.ts b/src/client/util/DictationManager.ts index 16a0df120..a0e1413b6 100644 --- a/src/client/util/DictationManager.ts +++ b/src/client/util/DictationManager.ts @@ -32,14 +32,12 @@ import { UndoManager } from './UndoManager'; * to add new commands as classes or components are constructed. */ -// eslint-disable-next-line @typescript-eslint/no-namespace export namespace DictationManager { /** * Some type maneuvering to access Webkit's built-in * speech recognizer. */ - // eslint-disable-next-line @typescript-eslint/no-namespace namespace CORE { export interface IWindow extends Window { webkitSpeechRecognition: { new (): SpeechRecognition }; @@ -48,7 +46,6 @@ export namespace DictationManager { const { webkitSpeechRecognition }: CORE.IWindow = window as unknown as CORE.IWindow; export const placeholder = 'Listening...'; - // eslint-disable-next-line @typescript-eslint/no-namespace export namespace Controls { export const Infringed = 'unable to process: dictation manager still involved in previous session'; const browser = (() => { @@ -230,7 +227,6 @@ export namespace DictationManager { }; } - // eslint-disable-next-line @typescript-eslint/no-namespace export namespace Commands { export const dictationFadeDuration = 2000; diff --git a/src/client/util/DragManager.ts b/src/client/util/DragManager.ts index c237a75de..7db13689d 100644 --- a/src/client/util/DragManager.ts +++ b/src/client/util/DragManager.ts @@ -70,7 +70,6 @@ export function SetupDrag(_reference: React.RefObject<HTMLElement>, docFunc: () return onItemDown; } -// eslint-disable-next-line @typescript-eslint/no-namespace export namespace DragManager { export const dragClassName = 'collectionFreeFormDocumentView-container'; let dragDiv: HTMLDivElement; diff --git a/src/client/util/History.ts b/src/client/util/History.ts index 067c28c6b..0d0c056a4 100644 --- a/src/client/util/History.ts +++ b/src/client/util/History.ts @@ -10,7 +10,6 @@ import { OmitKeys, ClientUtils } from '../../ClientUtils'; import { DocServer } from '../DocServer'; import { DashboardView } from '../views/DashboardView'; -// eslint-disable-next-line @typescript-eslint/no-namespace export namespace HistoryUtil { export interface DocInitializerList { [key: string]: string | number; diff --git a/src/client/util/InteractionUtils.tsx b/src/client/util/InteractionUtils.tsx index f3ede596d..4231c2ca8 100644 --- a/src/client/util/InteractionUtils.tsx +++ b/src/client/util/InteractionUtils.tsx @@ -4,7 +4,6 @@ import { Utils } from '../../Utils'; import { Gestures } from '../../pen-gestures/GestureTypes'; import './InteractionUtils.scss'; -// eslint-disable-next-line @typescript-eslint/no-namespace export namespace InteractionUtils { export const MOUSETYPE = 'mouse'; export const TOUCHTYPE = 'touch'; diff --git a/src/client/util/ScriptingGlobals.ts b/src/client/util/ScriptingGlobals.ts index 4a1a70633..444e8fc0a 100644 --- a/src/client/util/ScriptingGlobals.ts +++ b/src/client/util/ScriptingGlobals.ts @@ -6,7 +6,7 @@ const _scriptingGlobals: { [name: string]: unknown } = {}; const _scriptingDescriptions: { [name: string]: string } = {}; const _scriptingParams: { [name: string]: string } = {}; export let scriptingGlobals: { [name: string]: unknown } = _scriptingGlobals; -// eslint-disable-next-line @typescript-eslint/no-namespace + export namespace ScriptingGlobals { export function getGlobals() { return Object.keys(_scriptingGlobals); } // prettier-ignore export function getGlobalObj() { return _scriptingGlobals; } // prettier-ignore diff --git a/src/client/util/SearchUtil.ts b/src/client/util/SearchUtil.ts index 6cad7060b..733eae5f4 100644 --- a/src/client/util/SearchUtil.ts +++ b/src/client/util/SearchUtil.ts @@ -5,7 +5,6 @@ import { StrCast } from '../../fields/Types'; import { DocumentType } from '../documents/DocumentTypes'; import { DocOptions, FInfo } from '../documents/Documents'; -// eslint-disable-next-line @typescript-eslint/no-namespace export namespace SearchUtil { export type HighlightingResult = { [id: string]: { [key: string]: string[] } }; diff --git a/src/client/util/SerializationHelper.ts b/src/client/util/SerializationHelper.ts index 0386b2455..ccb02fb79 100644 --- a/src/client/util/SerializationHelper.ts +++ b/src/client/util/SerializationHelper.ts @@ -12,7 +12,6 @@ export function afterDocDeserialize(cb: (err: unknown, val: unknown) => void, er const serializationTypes: { [name: string]: { ctor: { new (): unknown }; afterDeserialize?: (obj: unknown) => void | Promise<unknown> } } = {}; const reverseMap: { [ctor: string]: string } = {}; -// eslint-disable-next-line @typescript-eslint/no-namespace export namespace SerializationHelper { export function IsSerializing() { return serializing > 0; diff --git a/src/client/util/UndoManager.ts b/src/client/util/UndoManager.ts index 5fd935370..ce0e7768b 100644 --- a/src/client/util/UndoManager.ts +++ b/src/client/util/UndoManager.ts @@ -83,7 +83,6 @@ export function undoBatch(target: any, key?: string | symbol, descriptor?: Typed return descriptor; } -// eslint-disable-next-line @typescript-eslint/no-namespace export namespace UndoManager { export interface UndoEvent { undo: () => void; diff --git a/src/client/views/DocViewUtils.ts b/src/client/views/DocViewUtils.ts index 49a30aa08..1f5f29c7e 100644 --- a/src/client/views/DocViewUtils.ts +++ b/src/client/views/DocViewUtils.ts @@ -6,7 +6,6 @@ import { Doc, SetActiveAudioLinker } from '../../fields/Doc'; import { DocUtils } from '../documents/DocUtils'; import { FieldViewProps } from './nodes/FieldView'; -// eslint-disable-next-line @typescript-eslint/no-namespace export namespace DocViewUtils { export const ActiveRecordings: { props: FieldViewProps; getAnchor: (addAsAnnotation: boolean) => Doc }[] = []; |
