Showing 711 of 1,553 total issues
Function getAtomByFullname
has 34 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
getAtomByFullname(fullName) {
const parts = fullName.split('.')
if (parts.length !== 3) {
return null
}
Function setOptions
has 34 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
setOptions(opts) {
if (typeof opts === 'string') {
opts = Miew.options.fromAttr(opts)
}
if (opts.reps) {
Function _renderShadowMap
has 34 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
_renderShadowMap() {
if (!settings.now.shadow.on) {
return
}
Consider simplifying this complex logical expression. Open
Open
if (
t &&
(!(t.position.x === 0 && t.position.y === 0 && t.position.z === 0) ||
!(
t.quaternion.x === 0 &&
Function propagateProp
has 33 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
value: function propagateProp(path, arg) {
if (path !== undefined) {
var argExc = {};
var adapter = options.adapters[_typeof(lodash.get(settings.defaults, path))];
if (adapter === undefined) {
Function fillToolbar
has 33 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function fillToolbar(type, name, option, entityList) {
const toolbar = $(`${self._menuId} [data-toolbar-type=${type}]`).get(0)
const list = entityList.all
for (let i = 0, n = list.length; i < n; i++) {
let entry = list[i]
Function propagateProp
has 33 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
value: function propagateProp(path, arg) {
if (path !== undefined) {
var argExc = {};
var adapter = options.adapters[_typeof(get(settings.defaults, path))];
if (adapter === undefined) {
Function onError
has 33 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function onError(err) {
const doc = document.createDocumentFragment()
const containers = document.getElementsByClassName('miew-container')
const parent = containers.length > 0 ? containers[0] : null
Function setItem
has 33 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
setItem(itemIdx, botPos, topPos, itemRad) {
const chunkSize = this._chunkSize
const firstOffset = chunkSize * 2 * itemIdx * VEC_SIZE
const secondOffset = firstOffset + chunkSize * VEC_SIZE
Function withinRadii
has 33 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
this.withinRadii = function (x, y, z, rExtra, out) {
let outIdx = 0
const nearI = hashFunc(x, minX)
const nearJ = hashFunc(y, minY)
Function createShadowmapMaterial
has 33 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
const createShadowmapMaterial = (function () {
const matValues = {
colorFromDepth: true,
orthoCam: true,
lights: false,
Function change
has 33 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
change(repSettings, complex, mode, color) {
const diff = {}
// modify selector
if (repSettings.selector) {
Function constructor
has 33 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
constructor(source, options) {
super(source, options)
this._tags = [
'HEADER',
'TITLE',
Function _collectGeoInfo
has 33 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
_collectGeoInfo(mesh) {
const {
geometry: {
attributes: { position, color, normal },
index
Function _fillHeader
has 33 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
_fillHeader(headerFormat, arrays) {
for (const key in headerFormat) {
if (Object.hasOwn(headerFormat, key)) {
switch (headerFormat[key][0]) {
case valueType.singular:
Function RenderSettingsPanel
has 32 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
const RenderSettingsPanel = () => {
const options = [
{
name: 'Resolution'
},
Function vertexFusion
has 32 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
vertexFusion(offset, len) {
const faceVer = this._indices.length
const vertices = this._position
const normals = this._normals
const oldVerCount = vertices.length | 0
Function constructor
has 32 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
constructor(
ResidueGroup,
geoParams,
complex,
colorer,
Function _polygonize
has 32 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
_polygonize(grid, isoLevel, triangles) {
const { cubeIndex } = grid
let i = 0
const arrSize = IsoSurface._arrSize
const firstIndices = IsoSurface._firstIndices
Function W
has 32 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function W(r, t, n, e) {
switch (r) {
case 1:
return h(t)
case 2: