chore(frontend/viewer): fixes some eslint errors
This commit is contained in:
@@ -128,15 +128,11 @@ import { useQuery } from '@vue/apollo-composable'
|
||||
import { computed } from 'vue'
|
||||
import gql from 'graphql-tag'
|
||||
import {
|
||||
hideObjects,
|
||||
hideObjects2,
|
||||
hideTree,
|
||||
showTree,
|
||||
showObjects,
|
||||
showObjects2,
|
||||
isolateObjects,
|
||||
isolateObjects2,
|
||||
unisolateObjects,
|
||||
unIsolateObjects2,
|
||||
getInitializedViewer
|
||||
} from '@/main/lib/viewer/commit-object-viewer/stateManager'
|
||||
@@ -265,23 +261,17 @@ export default {
|
||||
},
|
||||
toggleFilter() {
|
||||
if (this.prop.type === 'object') {
|
||||
// TODO: isolateTree?
|
||||
if (this.isolated) {
|
||||
// TODO
|
||||
unIsolateObjects2([this.prop.value.referencedId], 'ui-iso')
|
||||
} else {
|
||||
// TODO
|
||||
isolateObjects2([this.prop.value.referencedId], 'ui-iso')
|
||||
}
|
||||
}
|
||||
if (this.prop.type === 'array') {
|
||||
const targetIds = this.prop.value.map((o) => o.referencedId)
|
||||
// TODO: isolateObjects?
|
||||
if (this.isolated) {
|
||||
// TODO
|
||||
unIsolateObjects2(targetIds, 'ui-iso')
|
||||
} else {
|
||||
// TODO
|
||||
isolateObjects2(targetIds, 'ui-iso')
|
||||
}
|
||||
}
|
||||
|
||||
@@ -6,7 +6,7 @@ import { setupNewViewerInjection } from '@/main/lib/viewer/core/composables/view
|
||||
import { makeVar, TypePolicies } from '@apollo/client/cache'
|
||||
import { DefaultViewerParams, Viewer, SelectionEvent } from '@speckle/viewer'
|
||||
import emojis from '@/main/store/emojis'
|
||||
import { cloneDeep, has, isArray, update } from 'lodash'
|
||||
import { cloneDeep, has, isArray } from 'lodash'
|
||||
import { computed, ComputedRef, inject, InjectionKey, provide, Ref } from 'vue'
|
||||
|
||||
const ViewerStreamIdKey: InjectionKey<Ref<string>> = Symbol(
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
* @returns an object with all its props flattened into `prop.subprop.subsubprop`.
|
||||
*/
|
||||
const flattenObject = function (obj) {
|
||||
const flatten = {} as any
|
||||
const flatten = {} as Record<string, unknown>
|
||||
for (const k in obj) {
|
||||
if (['id', '__closure', '__parents', 'bbox', 'totalChildrenCount'].includes(k))
|
||||
continue
|
||||
|
||||
@@ -672,6 +672,7 @@ export class FilteringManager {
|
||||
public handleLegacyFilter(filter) {
|
||||
// TODO
|
||||
console.warn('Not yet implemented.')
|
||||
console.log(filter)
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -569,7 +569,7 @@ export default class SpeckleRenderer {
|
||||
)
|
||||
const hitId = rv.renderData.id
|
||||
|
||||
const hitNode = WorldTree.getInstance().findId(hitId)
|
||||
// const hitNode = WorldTree.getInstance().findId(hitId)
|
||||
// console.log(hitNode)
|
||||
|
||||
this.batcher.resetBatchesDrawRanges()
|
||||
|
||||
@@ -33,8 +33,9 @@ export default class Input extends EventEmitter {
|
||||
|
||||
if (delta > 250) return
|
||||
|
||||
const loc = this._getNormalisedClickPosition(e) as any
|
||||
if (e.shiftKey) loc.multiSelect = true
|
||||
const loc = this._getNormalisedClickPosition(e)
|
||||
|
||||
if (e.shiftKey) (loc as unknown as Record<string, unknown>).multiSelect = true
|
||||
if (e.ctrlKey) this.emit('object-clicked-debug', loc)
|
||||
else this.emit('object-clicked', loc)
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user