diff options
Diffstat (limited to 'src/client/util')
| -rw-r--r-- | src/client/util/BranchingTrailManager.tsx | 3 | ||||
| -rw-r--r-- | src/client/util/CalendarManager.tsx | 2 | ||||
| -rw-r--r-- | src/client/util/CaptureManager.scss | 6 | ||||
| -rw-r--r-- | src/client/util/CurrentUserUtils.ts | 12 | ||||
| -rw-r--r-- | src/client/util/DocumentManager.ts | 3 | ||||
| -rw-r--r-- | src/client/util/GroupManager.scss | 19 | ||||
| -rw-r--r-- | src/client/util/GroupMemberView.scss | 20 | ||||
| -rw-r--r-- | src/client/util/LinkFollower.ts | 2 | ||||
| -rw-r--r-- | src/client/util/PingManager.ts | 2 | ||||
| -rw-r--r-- | src/client/util/SearchUtil.ts | 36 | ||||
| -rw-r--r-- | src/client/util/SettingsManager.scss | 30 | ||||
| -rw-r--r-- | src/client/util/SettingsManager.tsx | 2 | ||||
| -rw-r--r-- | src/client/util/SharingManager.scss | 51 | ||||
| -rw-r--r-- | src/client/util/TrackMovements.ts | 2 | ||||
| -rw-r--r-- | src/client/util/clamp.js | 24 | ||||
| -rw-r--r-- | src/client/util/convertToCSSPTValue.js | 9 | ||||
| -rw-r--r-- | src/client/util/reportManager/ReportManager.scss | 30 | ||||
| -rw-r--r-- | src/client/util/reportManager/ReportManager.tsx | 2 |
18 files changed, 128 insertions, 127 deletions
diff --git a/src/client/util/BranchingTrailManager.tsx b/src/client/util/BranchingTrailManager.tsx index 65336812d..a0871514c 100644 --- a/src/client/util/BranchingTrailManager.tsx +++ b/src/client/util/BranchingTrailManager.tsx @@ -1,5 +1,3 @@ -/* eslint-disable react/no-unused-class-component-methods */ -/* eslint-disable react/no-array-index-key */ import { action, computed, makeObservable, observable } from 'mobx'; import { observer } from 'mobx-react'; import * as React from 'react'; @@ -52,7 +50,6 @@ export class BranchingTrailManager extends React.Component { this.slideHistoryStack = newArr; }); - // eslint-disable-next-line react/sort-comp observeDocumentChange = (targetDoc: Doc, pres: PresBox) => { const presId = pres.Document[Id]; if (this.prevPresId === presId) { diff --git a/src/client/util/CalendarManager.tsx b/src/client/util/CalendarManager.tsx index b50e39c02..a8460ed4b 100644 --- a/src/client/util/CalendarManager.tsx +++ b/src/client/util/CalendarManager.tsx @@ -156,7 +156,7 @@ export class CalendarManager extends ObservableReactComponent<object> { const subDocEmbedding = Doc.MakeEmbedding(targetDoc); // embedding console.log('subdoc embedding', subDocEmbedding); subDocEmbedding.embedContainer = calendar; // set embed container - subDocEmbedding.date_range = `${startDateStr}|${endDateStr}`; // set subDoc date range + subDocEmbedding.task_dateRange = `${startDateStr}|${endDateStr}`; // set subDoc date range Doc.AddDocToList(calendar, 'data', subDocEmbedding); // add embedded subDoc to calendar diff --git a/src/client/util/CaptureManager.scss b/src/client/util/CaptureManager.scss index e7cbb4287..9e81f2669 100644 --- a/src/client/util/CaptureManager.scss +++ b/src/client/util/CaptureManager.scss @@ -67,7 +67,7 @@ font-weight: bold; text-align: left; color: black; - width: 80; + width: 80px; margin-right: 50px; margin-bottom: 5px; } @@ -114,8 +114,8 @@ .buttons { display: flex; position: absolute; - bottom: 0; - right: 15; + bottom: 0px; + right: 15px; justify-content: flex-end; align-items: center; height: 60px; diff --git a/src/client/util/CurrentUserUtils.ts b/src/client/util/CurrentUserUtils.ts index 28b19d55e..9fbc82bef 100644 --- a/src/client/util/CurrentUserUtils.ts +++ b/src/client/util/CurrentUserUtils.ts @@ -407,7 +407,8 @@ pie title Minerals in my tap water {key: "DataViz", creator: opts => Docs.Create.DataVizDocument("", opts), opts: { _width: 300, _height: 300, }}, // AARAV ADD // {key: "DailyJournal",creator:opts => Docs.Create.DailyJournalDocument("", opts),opts: { _width: 300, _height: 300, }}, - {key: "Scrapbook",creator:opts => Docs.Create.ScrapbookDocument([], opts),opts:{ _width: 300, _height: 300}}, + {key: "Task", creator: opts => Docs.Create.TaskDocument("", opts), opts: { _width: 300, _height: 300, _layout_autoHeight: true, title: "Task", }}, + {key: "Scrapbook", creator: opts => Docs.Create.ScrapbookDocument([], opts), opts: { _width: 300, _height: 300}}, //{key: "Scrapbook",creator:opts => Docs.Create.ScrapbookDocument([], opts),opts:{ _width: 300, _height: 300}}, {key: "Chat", creator: Docs.Create.ChatDocument, opts: { _width: 500, _height: 500, _layout_fitWidth: true, }}, {key: "MetaNote", creator: metaNoteTemplate, opts: { _width: 300, _height: 120, _header_pointerEvents: "all", _header_height: 50, _header_fontSize: 9,_layout_autoHeightMargins: 50, _layout_autoHeight: true, treeView_HideUnrendered: true}}, @@ -453,6 +454,7 @@ pie title Minerals in my tap water { toolTip: "Tap or drag to create a data viz node", title: "DataViz", icon: "chart-bar", dragFactory: doc.emptyDataViz as Doc, clickFactory: DocCast(doc.emptyDataViz)}, { toolTip: "Tap or drag to create a scrapbook template", title: "Scrapbook", icon: "palette", dragFactory: doc.emptyScrapbook as Doc,clickFactory:DocCast(doc.emptyScrapbook), }, { toolTip: "Tap or drag to create a journal entry", title: "Journal", icon: "book", dragFactory:doc.emptyDailyJournal as Doc,clickFactory: DocCast(doc.emptyDataJournal), }, + { toolTip: "Tap or drag to create a task", title: "Task", icon: "check-square", dragFactory: doc.emptyTask as Doc, clickFactory: DocCast(doc.emptyTask), }, { toolTip: "Tap or drag to create a bullet slide", title: "PPT Slide", icon:"person-chalkboard",dragFactory: doc.emptySlide as Doc, clickFactory: DocCast(doc.emptySlide), openFactoryLocation: OpenWhere.overlay, funcs: { hidden: "IsNoviceMode()"}}, { toolTip: "Tap or drag to create a view slide", title: "View Slide", icon: "address-card", dragFactory: doc.emptyViewSlide as Doc, clickFactory: DocCast(doc.emptyViewSlide), openFactoryLocation: OpenWhere.overlay, funcs: { hidden: "IsNoviceMode()"}}, { toolTip: "Tap or drag to create a data note", title: "MetaNote", icon: "window-maximize", dragFactory: doc.emptyMetaNote as Doc, clickFactory: DocCast(doc.emptyMetaNote), openFactoryAsDelegate: true, funcs: { hidden: "IsNoviceMode()"} }, @@ -560,7 +562,7 @@ pie title Minerals in my tap water const reqdToolOps:DocumentOptions = { title: "My Tools", isSystem: true, ignoreClick: true, layout_boxShadow: "0 0", layout_explainer: "This is a palette of documents that can be created.", _layout_dontCenter: "y", - _layout_showTitle: "title", _width: 500, _yMargin: 20, _lockedPosition: true, _forceActive: true, _dragOnlyWithinContainer: true, layout_hideContextMenu: true, _chromeHidden: true, + _layout_showTitle: "title", _width: 500, _lockedPosition: true, _forceActive: true, _dragOnlyWithinContainer: true, layout_hideContextMenu: true, _chromeHidden: true, }; return DocUtils.AssignDocField(doc, field, (opts, items) => Docs.Create.StackingDocument(items??[], opts), reqdToolOps, [creatorBtns, userBtns]); } @@ -794,6 +796,7 @@ pie title Minerals in my tap water { title: "Pen", toolTip: "Pen (Ctrl+P)", btnType: ButtonType.ToggleButton, icon: "pen-nib", toolType: InkInkTool.Pen, ignoreClick: true, scripts: {onClick:'{ return setActiveTool(this.toolType, true, _readOnly_);}' }}, { title: "Highlight",toolTip: "Highlight (Ctrl+H)", btnType: ButtonType.ToggleButton, icon: "highlighter", toolType: InkInkTool.Highlight, ignoreClick: true, scripts: {onClick:'{ return setActiveTool(this.toolType, true, _readOnly_);}' }}, { title: "Write", toolTip: "Write (Ctrl+Shift+P)", btnType: ButtonType.ToggleButton, icon: "pen", toolType: InkInkTool.Write, ignoreClick: true, scripts: {onClick:'{ return setActiveTool(this.toolType, true, _readOnly_);}' }, funcs: {hidden:"IsNoviceMode()" }}, + { title: "Math", toolTip: "Math", btnType: ButtonType.ToggleButton, icon: "calculator", toolType: InkInkTool.Math, ignoreClick: true, scripts: {onClick:'{ return setActiveTool(this.toolType, true, _readOnly_);}' }, funcs: {hidden:"IsNoviceMode()" }}, ]}, { title: "Width", toolTip: "Stroke width", btnType: ButtonType.NumberSliderButton, toolType: InkProperty.StrokeWidth,ignoreClick: true, scripts: {script: '{ return setInkProperty(this.toolType, value, _readOnly_);}'}, funcs: {hidden:"!activeInkTool()"}, numBtnMin: 1, linearView_btnWidth:40}, { title: "Color", toolTip: "Stroke color", btnType: ButtonType.ColorButton, icon: "pen", toolType: InkProperty.StrokeColor,ignoreClick: true, scripts: {script: '{ return setInkProperty(this.toolType, value, _readOnly_);}'}, funcs: {hidden:"!activeInkTool()"}}, @@ -992,7 +995,7 @@ pie title Minerals in my tap water const reqdOpts:DocumentOptions = { title: "My Imports", _forceActive: true, _layout_showTitle: "title", childLayoutString: ImportElementBox.LayoutString('data'), _dragOnlyWithinContainer: true, layout_hideContextMenu: true, childLimitHeight: 0, onClickScriptDisable:"never", - childDragAction: dropActionType.copy, _layout_autoHeight: true, _yMargin: 50, _gridGap: 15, layout_boxShadow: "0 0", _lockedPosition: true, isSystem: true, _chromeHidden: true, + childDragAction: dropActionType.copy, _layout_autoHeight: true, _gridGap: 15, layout_boxShadow: "0 0", _lockedPosition: true, isSystem: true, dontRegisterView: true, layout_explainer: "This is where documents that are Imported into Dash will go." }; const myImports = DocUtils.AssignDocField(doc, field, (opts) => Docs.Create.MasonryDocument([], opts), reqdOpts, undefined, {onClick: "deselectAll()"}); @@ -1030,6 +1033,9 @@ pie title Minerals in my tap water doc[`active${InkInkTool.Write}Color`] ?? (doc[`active${InkInkTool.Write}Color`] = "rgb(255, 0, 0)"); doc[`active${InkInkTool.Write}Width`] ?? (doc[`active${InkInkTool.Write}Width`] = 1); doc[`active${InkInkTool.Write}Bezier`] ?? (doc[`active${InkInkTool.Write}Bezier`] = "0"); + doc[`active${InkInkTool.Math}Color`] ?? (doc[`active${InkInkTool.Math}Color`] = "rgb(0, 0, 255)"); + doc[`active${InkInkTool.Math}Width`] ?? (doc[`active${InkInkTool.Math}Width`] = 1); + doc[`active${InkInkTool.Math}Bezier`] ?? (doc[`active${InkInkTool.Math}Bezier`] = "0"); doc[`active${InkInkTool.Highlight}Color`] ?? (doc[`active${InkInkTool.Highlight}Color`] = 'transparent'); doc[`active${InkInkTool.Highlight}Width`] ?? (doc[`active${InkInkTool.Highlight}Width`] = 20); doc[`active${InkInkTool.Highlight}Bezier`] ?? (doc[`active${InkInkTool.Highlight}Bezier`] = "0"); diff --git a/src/client/util/DocumentManager.ts b/src/client/util/DocumentManager.ts index fc8f22cf3..1c2ffab1b 100644 --- a/src/client/util/DocumentManager.ts +++ b/src/client/util/DocumentManager.ts @@ -250,7 +250,7 @@ export class DocumentManager { const options = optionsIn; Doc.MyRecentlyClosed && Doc.RemoveDocFromList(Doc.MyRecentlyClosed, undefined, targetDoc); const docContextPath = DocumentManager.GetContextPath(targetDoc, true); - if (docContextPath.some(doc => doc.hidden)) options.toggleTarget = false; + if (docContextPath.some(doc => doc !== targetDoc && doc.hidden)) options.toggleTarget = false; let activatedTab = false; if (DocumentView.activateTabView(docContextPath[0])) { options.toggleTarget = false; @@ -274,6 +274,7 @@ export class DocumentManager { // even if we found the document view, if the target is a lightbox, we try to open it in the lightbox to preserve lightbox semantics (eg, there's only one active doc in the lightbox) const target = DocCast(targetDoc.annotationOn, targetDoc)!; const compView = this.getDocumentView(DocCast(target.embedContainer))?.ComponentView; + options.didMove = target.hidden || options.didMove ? true : false; if ((compView?.addDocTab ?? compView?._props.addDocTab)?.(target, options.openLocation)) { await new Promise<void>(waitres => { setTimeout(() => waitres()); diff --git a/src/client/util/GroupManager.scss b/src/client/util/GroupManager.scss index 673af16ee..66f11c529 100644 --- a/src/client/util/GroupManager.scss +++ b/src/client/util/GroupManager.scss @@ -21,7 +21,6 @@ } .group-input { - input { padding: 8px; width: 100%; @@ -33,13 +32,13 @@ border-color: inherit; background: white; color: black; - height: 30; + height: 30px; } } .select-users { - margin-right: 3; - max-height: 30; + margin-right: 3px; + max-height: 30px; width: 100%; display: inline-flex; flex-direction: row; @@ -51,7 +50,6 @@ } } - button { align-self: center; outline: none; @@ -108,7 +106,7 @@ .sort-groups { text-align: left; - margin-left: 5; + margin-left: 5px; width: 50px; cursor: pointer; display: flex; @@ -122,7 +120,7 @@ .group-body { justify-content: space-between; - height: 225; + height: 225px; padding-right: 1em; justify-content: space-around; @@ -149,8 +147,8 @@ button { position: absolute; width: 30%; - right: 2; - margin-top: 0; + right: 2px; + margin-top: 0px; } } @@ -161,7 +159,6 @@ min-width: 100%; margin: 2px 0; } - } } -}
\ No newline at end of file +} diff --git a/src/client/util/GroupMemberView.scss b/src/client/util/GroupMemberView.scss index d50569b26..cb1a4e098 100644 --- a/src/client/util/GroupMemberView.scss +++ b/src/client/util/GroupMemberView.scss @@ -6,7 +6,7 @@ overflow: visible; hr { - margin-top: 20; + margin-top: 20px; } button { @@ -31,7 +31,7 @@ } .editing-header { - margin-bottom: 5; + margin-bottom: 5px; .group-title { font-weight: bold; @@ -39,7 +39,7 @@ text-align: center; border: none; outline: none; - height: 20; + height: 20px; text-overflow: ellipsis; background: none; @@ -57,12 +57,12 @@ .group-buttons { display: flex; - margin-top: 5; - margin-bottom: 25; + margin-top: 5px; + margin-bottom: 25px; .add-member-dropdown { - margin-right: 3; - max-height: 30; + margin-right: 3px; + max-height: 30px; width: 250px; display: inline-flex; flex-direction: row; @@ -108,11 +108,9 @@ .remove-button { position: absolute; - right: 10; + right: 10px; cursor: pointer; } } } - - -}
\ No newline at end of file +} diff --git a/src/client/util/LinkFollower.ts b/src/client/util/LinkFollower.ts index 6081c3fae..a4f54f1cf 100644 --- a/src/client/util/LinkFollower.ts +++ b/src/client/util/LinkFollower.ts @@ -134,6 +134,6 @@ export class LinkFollower { // eslint-disable-next-line prefer-arrow-callback ScriptingGlobals.add(function followLink(doc: Doc, altKey: boolean) { - DocumentView.DeselectAll(); + // DocumentView.DeselectAll(); return LinkFollower.FollowLink(undefined, doc, altKey) ? undefined : { select: true }; }); diff --git a/src/client/util/PingManager.ts b/src/client/util/PingManager.ts index 0e4f8cab0..593978b4a 100644 --- a/src/client/util/PingManager.ts +++ b/src/client/util/PingManager.ts @@ -27,7 +27,7 @@ export class PingManager { this.IsBeating = status; setTimeout(this.showAlert, 100); }); - Networking.PostToServer('/ping', { date: new Date() }) + Networking.PostToServer('/DashPing', { date: new Date() }) .then(res => { SnappingManager.SetServerVersion((res as { message: string }).message); !this.IsBeating && setIsBeating(true); diff --git a/src/client/util/SearchUtil.ts b/src/client/util/SearchUtil.ts index fc3bb99ab..2f23d07dc 100644 --- a/src/client/util/SearchUtil.ts +++ b/src/client/util/SearchUtil.ts @@ -8,6 +8,13 @@ import { DocOptions, FInfo } from '../documents/Documents'; export namespace SearchUtil { export type HighlightingResult = { [id: string]: { [key: string]: string[] } }; + /** + * Recursively search all Docs within the collection for the query string. + * @param {Doc} collectionDoc - The collection document to search within. + * @param {string} queryIn - The query string to search for. + * @param {boolean} matchKeyNames - Whether to match metadata field names in addition to field values + * @param {string[]} onlyKeys - Optional: restrict search to only look in the specified array of field names. + */ export function SearchCollection(collectionDoc: Opt<Doc>, queryIn: string, matchKeyNames: boolean, onlyKeys?: string[]) { const blockedTypes = [DocumentType.PRESSLIDE, DocumentType.CONFIG, DocumentType.KVP, DocumentType.FONTICON, DocumentType.BUTTON, DocumentType.SCRIPTING]; const blockedKeys = matchKeyNames @@ -27,11 +34,13 @@ export namespace SearchUtil { const dtype = StrCast(doc.type) as DocumentType; if (dtype && !blockedTypes.includes(dtype) && !docIDs.includes(doc[Id]) && depth >= 0) { const hlights = new Set<string>(); - (onlyKeys ?? SearchUtil.documentKeys(doc)).forEach( - key => - (val => (exact ? val === query.toLowerCase() : val.includes(query.toLowerCase())))( - matchKeyNames ? key : Field.toString(doc[key] as FieldType)) - && hlights.add(key) + const fieldsToSearch = onlyKeys ?? SearchUtil.documentKeys(doc); + fieldsToSearch.forEach( + key => { + const val = (matchKeyNames ? key : Field.toString(doc[key] as FieldType)).toLowerCase(); + const accept = (exact ? val === query.toLowerCase() : val.includes(query.toLowerCase())); + accept && hlights.add(key); + } ); // prettier-ignore blockedKeys.forEach(key => hlights.delete(key)); @@ -45,18 +54,17 @@ export namespace SearchUtil { return results; } /** - * @param {Doc} doc - doc for which keys are returned + * @param {Doc} doc - Doc to search for used field names * - * This method returns a list of a document doc's keys. + * An array of all field names used by the Doc or its prototypes. */ export function documentKeys(doc: Doc) { - const keys: { [key: string]: boolean } = {}; - Doc.GetAllPrototypes(doc).map(proto => - Object.keys(proto).forEach(key => { - keys[key] = false; - }) - ); - return Array.from(Object.keys(keys)); + return Object.keys(Doc.GetAllPrototypes(doc).filter(proto => proto).reduce( + (keys, proto) => { + Object.keys(proto).forEach(keys.add.bind(keys)); + return keys; + }, + new Set<string>())); // prettier-ignore } /** diff --git a/src/client/util/SettingsManager.scss b/src/client/util/SettingsManager.scss index f81f17589..51b719200 100644 --- a/src/client/util/SettingsManager.scss +++ b/src/client/util/SettingsManager.scss @@ -26,7 +26,7 @@ font-size: 16; font-weight: bold; text-align: left; - width: 80; + width: 80px; margin-right: 50px; } @@ -81,7 +81,7 @@ .acl-text { color: black; - margin-top: 2; + margin-top: 2px; text-align: left; } } @@ -119,7 +119,7 @@ .preferences-color-text { margin-top: 3px; - margin-right: 4; + margin-right: 4px; flex: 1 1 auto; text-align: left; } @@ -134,8 +134,8 @@ margin-top: 2px; .preferences-font-text { - margin-top: 4; - margin-right: 4; + margin-top: 4px; + margin-right: 4px; margin-bottom: 2px; text-align: left; } @@ -149,7 +149,7 @@ .font-select { height: 35px; font-size: 9; - margin-right: 6; + margin-right: 6px; border-radius: 5px; width: 65%; @@ -171,9 +171,9 @@ } .preferences-check { - margin-right: 4; + margin-right: 4px; margin-bottom: -3; - margin-left: 5; + margin-left: 5px; margin-top: -1px; display: inline-block; padding-left: 5px; @@ -205,14 +205,14 @@ .error-text { color: #c40233; font-size: 10; - margin-bottom: 4; + margin-bottom: 4px; } .success-text { - width: 300; + width: 300px; margin-left: -20; font-size: 10; - margin-bottom: 4; + margin-bottom: 4px; margin-top: -3; color: #009f6b; } @@ -225,7 +225,7 @@ text-transform: uppercase; letter-spacing: 2px; font-size: 19; - margin-top: 0; + margin-top: 0px; font-weight: bold; } @@ -246,7 +246,7 @@ font-style: normal; font-size: 15; font-weight: normal; - padding: 0; + padding: 0px; .padding { padding: 0 0 0 20px; @@ -273,8 +273,8 @@ align-items: center; flex-direction: column; bottom: 10px; - left: 0; - right: 0; + left: 0px; + right: 0px; .settings-username { padding-right: 0px; diff --git a/src/client/util/SettingsManager.tsx b/src/client/util/SettingsManager.tsx index 9e79fd870..f54dea90c 100644 --- a/src/client/util/SettingsManager.tsx +++ b/src/client/util/SettingsManager.tsx @@ -40,7 +40,7 @@ export class SettingsManager extends React.Component<object> { @observable private _activeTab = 'Accounts'; @observable private _isOpen = false; - private googleAuthorize = action(() => GoogleAuthenticationManager.Instance.fetchOrGenerateAccessToken(true)); + private googleAuthorize = action(() => GoogleAuthenticationManager.Instance.fetchOrGenerateAccessToken()); public closeMgr = action(() => { this._isOpen = false; diff --git a/src/client/util/SharingManager.scss b/src/client/util/SharingManager.scss index c9f86f0e1..553f3a184 100644 --- a/src/client/util/SharingManager.scss +++ b/src/client/util/SharingManager.scss @@ -4,7 +4,7 @@ .select { text-align: justify; - text-align-last: end + text-align-last: end; } .sharing-contents { @@ -36,15 +36,14 @@ } .share-container { - .share-setup { display: flex; margin-bottom: 20px; align-items: center; - max-height: 28; + max-height: 28px; .user-search { - max-height: 30; + max-height: 30px; width: 90%; display: inline-flex; flex-direction: row; @@ -68,7 +67,7 @@ text-align-last: end; font-size: 13px; min-width: 90px; - height: 28; + height: 28px; margin-left: 2px; } @@ -99,8 +98,8 @@ display: flex; float: right; align-items: baseline; - margin-top: -12; - margin-bottom: 10; + margin-top: -12px; + margin-bottom: 10px; .layoutDoc-acls, .myDocs-acls { @@ -109,7 +108,7 @@ label { font-weight: normal; font-style: italic; - padding-right: 12; + padding-right: 12px; } input { @@ -127,13 +126,13 @@ .group-container { width: 50%; display: flex; - top:0; + top: 0px; flex-direction: column; border-radius: 4px; .user-sort { text-align: left; - margin-left: 10; + margin-left: 10px; width: 100%; cursor: pointer; } @@ -180,7 +179,7 @@ padding: 0 10; margin: 0 5; transition: transform 0.2s; - height: 25; + height: 25px; } } @@ -205,7 +204,7 @@ .people-with { font-size: 14px; - margin: 0; + margin: 0px; padding-top: 3px; font-style: normal; } @@ -216,30 +215,30 @@ } } - .title-individual{ + .title-individual { height: 25px; - padding-left: 2; + padding-left: 2px; width: 97%; border-radius: 4px; margin-top: 10px; margin-left: -8px; font-size: 14; - margin-bottom: -4; + margin-bottom: -4px; border: 2px solid; border-bottom: none; align-items: center; display: flex; } - .title-group{ + .title-group { height: 25px; - padding-left: 2; + padding-left: 2px; width: 97%; border-radius: 4px; margin-top: 10px; margin-left: -8px; font-size: 14; - margin-bottom: -4; + margin-bottom: -4px; border: 2px solid; border-bottom: none; align-items: center; @@ -289,18 +288,17 @@ text-align: right; margin-left: auto; margin-right: -12px; - } .edit-actions { display: flex; position: absolute; align-items: flex-end; - right: -10; + right: -10px; } } - .permissions-dropdown-None{ + .permissions-dropdown-None { height: 100%; min-width: 85px; text-align: right; @@ -325,7 +323,7 @@ border-radius: 6px; border: 1px solid rgb(75, 75, 5); } - .permissions-dropdown-Augment{ + .permissions-dropdown-Augment { height: 100%; min-width: 85px; text-align: right; @@ -333,12 +331,11 @@ padding: 0px; padding-left: 3px; background: rgb(208, 255, 208); - color:rgb(19, 80, 19); + color: rgb(19, 80, 19); border-radius: 6px; border: 1px solid rgb(19, 80, 19); - } - .permissions-dropdown-View{ + .permissions-dropdown-View { height: 100%; min-width: 85px; text-align: right; @@ -350,7 +347,7 @@ border-radius: 6px; border: 1px solid rgb(25, 25, 101); } - .permissions-dropdown-Not-Shared{ + .permissions-dropdown-Not-Shared { height: 100%; min-width: 85px; text-align: right; @@ -398,4 +395,4 @@ // padding-top: 12px; // } // } -}
\ No newline at end of file +} diff --git a/src/client/util/TrackMovements.ts b/src/client/util/TrackMovements.ts index 7da0281c0..74a3be83d 100644 --- a/src/client/util/TrackMovements.ts +++ b/src/client/util/TrackMovements.ts @@ -98,7 +98,6 @@ export class TrackMovements { // new tab was added - need to add it if (tabbedFFViews.size > this.recordingFFViews.size) { - // eslint-disable-next-line no-restricted-syntax for (const DashDoc of tabbedDocs) { if (!this.recordingFFViews.has(DashDoc)) { if (isFFView(DashDoc)) { @@ -112,7 +111,6 @@ export class TrackMovements { } // tab was removed - need to remove it from recordingFFViews else if (tabbedFFViews.size < this.recordingFFViews.size) { - // eslint-disable-next-line no-restricted-syntax for (const [doc] of this.recordingFFViews) { if (!tabbedFFViews.has(doc)) { this.removeRecordingFFView(doc); diff --git a/src/client/util/clamp.js b/src/client/util/clamp.js index 9c7fd78a4..8d74b5636 100644 --- a/src/client/util/clamp.js +++ b/src/client/util/clamp.js @@ -1,15 +1,15 @@ -"use strict"; +'use strict'; -Object.defineProperty(exports, "__esModule", { - value: true +Object.defineProperty(exports, '__esModule', { + value: true, }); -exports.default = clamp; function clamp(min, val, max) { - if (val < min) { - return min; - } - if (val > max) { - return max; - } - return val; -}
\ No newline at end of file + if (val < min) { + return min; + } + if (val > max) { + return max; + } + return val; +} +exports.default = clamp; diff --git a/src/client/util/convertToCSSPTValue.js b/src/client/util/convertToCSSPTValue.js index 66f8db5a1..032385d81 100644 --- a/src/client/util/convertToCSSPTValue.js +++ b/src/client/util/convertToCSSPTValue.js @@ -3,11 +3,8 @@ Object.defineProperty(exports, '__esModule', { value: true, }); -exports.PT_TO_PX_RATIO = exports.PX_TO_PT_RATIO = undefined; -exports.default = convertToCSSPTValue; -exports.toClosestFontPtSize = toClosestFontPtSize; -var SIZE_PATTERN = /([\d\.]+)(px|pt)/i; +var SIZE_PATTERN = /([\d.]+)(px|pt)/i; var PX_TO_PT_RATIO = (exports.PX_TO_PT_RATIO = 0.7518796992481203); // 1 / 1.33. var PT_TO_PX_RATIO = (exports.PT_TO_PX_RATIO = 1.33); @@ -39,3 +36,7 @@ function toClosestFontPtSize(styleValue) { return Math.abs(curr - originalPTValue) < Math.abs(prev - originalPTValue) ? curr : prev; }, Number.NEGATIVE_INFINITY); } + +exports.PT_TO_PX_RATIO = exports.PX_TO_PT_RATIO = undefined; +exports.default = convertToCSSPTValue; +exports.toClosestFontPtSize = toClosestFontPtSize; diff --git a/src/client/util/reportManager/ReportManager.scss b/src/client/util/reportManager/ReportManager.scss index 806741c22..65894fbd6 100644 --- a/src/client/util/reportManager/ReportManager.scss +++ b/src/client/util/reportManager/ReportManager.scss @@ -14,8 +14,8 @@ } h2 { - margin: 0; - padding: 0; + margin: 0px; + padding: 0px; font-size: 24px; } } @@ -27,8 +27,8 @@ gap: 4px; h2 { - margin: 0; - padding: 0; + margin: 0px; + padding: 0px; padding-bottom: 8px; font-size: 24px; } @@ -92,7 +92,7 @@ outline: none; border-bottom: 1px solid; padding: 8px; - padding-left: 0; + padding-left: 0px; transition: all 0.2s ease; background: transparent; @@ -178,15 +178,15 @@ cursor: pointer; font-size: 14px; font-weight: 400; - padding: 0; - margin: 0; + padding: 0px; + margin: 0px; } .issue-title { font-size: 16px; font-weight: 500; - padding: 0; - margin: 0; + padding: 0px; + margin: 0px; } } @@ -211,8 +211,8 @@ .file-list { box-sizing: border-box; - margin: 0; - padding: 0; + margin: 0px; + padding: 0px; font-size: 14px; width: 100%; overflow-x: auto; @@ -251,8 +251,8 @@ .issue-title { font-size: 24px; - margin: 0; - padding: 0; + margin: 0px; + padding: 0px; } .issue-date { @@ -314,8 +314,8 @@ .report-media-content::after { content: ''; position: absolute; - top: 0; - left: 0; + top: 0px; + left: 0px; width: 100%; height: 100%; background-color: rgba(0, 0, 0, 0.5); /* Adjust the opacity as desired */ diff --git a/src/client/util/reportManager/ReportManager.tsx b/src/client/util/reportManager/ReportManager.tsx index a6b5911f7..87e8a8bf1 100644 --- a/src/client/util/reportManager/ReportManager.tsx +++ b/src/client/util/reportManager/ReportManager.tsx @@ -1,4 +1,3 @@ -/* eslint-disable react/no-unused-class-component-methods */ import { Octokit } from '@octokit/core'; import { Button, Dropdown, DropdownType, IconButton, Type } from '@dash/components'; import { action, makeObservable, observable } from 'mobx'; @@ -31,7 +30,6 @@ export class ReportManager extends React.Component<object> { @observable private isOpen = false; @observable private query = ''; - // eslint-disable-next-line react/sort-comp @action private setQuery = (q: string) => { this.query = q; }; |
