autowp/autowp-frontend

View on GitHub

Showing 175 of 175 total issues

Function Tracker has 64 lines of code (exceeds 25 allowed). Consider refactoring.
Open

const Tracker = (function() {
let onMove = function () {
},
onDone = function () {
};
Severity: Major
Found in src/app/jcrop/jquery.Jcrop.js - About 2 hrs to fix

    Function cataloguePathMatcher has a Cognitive Complexity of 17 (exceeds 5 allowed). Consider refactoring.
    Open

    export function cataloguePathMatcher(url: UrlSegment[]) {
    if (url.length <= 0) {
    return null;
    }
     
     
    Severity: Minor
    Found in src/app/catalogue/matcher.ts - About 2 hrs to fix

    Function getRect has 52 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

    function getRect() {
    let xsize = x2 - x1,
    ysize = y2 - y1,
    delta;
     
     
    Severity: Major
    Found in src/app/jcrop/jquery.Jcrop.js - About 2 hrs to fix

      Function cataloguePathMatcher has 47 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

      export function cataloguePathMatcher(url: UrlSegment[]) {
      if (url.length <= 0) {
      return null;
      }
       
       
      Severity: Minor
      Found in src/app/catalogue/matcher.ts - About 1 hr to fix

        Similar blocks of code found in 12 locations. Consider refactoring.
        Open

        export const routes: Routes = [
        {
        loadComponent: () => import('./map.component').then((m) => m.MapComponent),
        path: '',
        pathMatch: 'full',
        Severity: Major
        Found in src/app/map/map-routing.module.ts and 11 other locations - About 1 hr to fix
        src/app/about/about-routing.module.ts on lines 3..10
        src/app/brands/brands-routing.module.ts on lines 3..10
        src/app/chart/chart-routing.module.ts on lines 3..10
        src/app/index/index-routing.module.ts on lines 3..10
        src/app/log/log-routing.module.ts on lines 3..10
        src/app/mascots/mascots-routing.module.ts on lines 3..10
        src/app/policy/policy-routing.module.ts on lines 3..10
        src/app/pulse/pulse-routing.module.ts on lines 3..10
        src/app/rules/rules-routing.module.ts on lines 3..10
        src/app/telegram/telegram-routing.module.ts on lines 3..10
        src/app/top-view/top-view-routing.module.ts on lines 3..10

        Similar blocks of code found in 12 locations. Consider refactoring.
        Open

        export const routes: Routes = [
        {
        loadComponent: () => import('./policy.component').then((m) => m.PolicyComponent),
        path: '',
        pathMatch: 'full',
        Severity: Major
        Found in src/app/policy/policy-routing.module.ts and 11 other locations - About 1 hr to fix
        src/app/about/about-routing.module.ts on lines 3..10
        src/app/brands/brands-routing.module.ts on lines 3..10
        src/app/chart/chart-routing.module.ts on lines 3..10
        src/app/index/index-routing.module.ts on lines 3..10
        src/app/log/log-routing.module.ts on lines 3..10
        src/app/map/map-routing.module.ts on lines 3..10
        src/app/mascots/mascots-routing.module.ts on lines 3..10
        src/app/pulse/pulse-routing.module.ts on lines 3..10
        src/app/rules/rules-routing.module.ts on lines 3..10
        src/app/telegram/telegram-routing.module.ts on lines 3..10
        src/app/top-view/top-view-routing.module.ts on lines 3..10

        Similar blocks of code found in 12 locations. Consider refactoring.
        Open

        export const routes: Routes = [
        {
        loadComponent: () => import('./telegram.component').then((m) => m.TelegramComponent),
        path: '',
        pathMatch: 'full',
        Severity: Major
        Found in src/app/telegram/telegram-routing.module.ts and 11 other locations - About 1 hr to fix
        src/app/about/about-routing.module.ts on lines 3..10
        src/app/brands/brands-routing.module.ts on lines 3..10
        src/app/chart/chart-routing.module.ts on lines 3..10
        src/app/index/index-routing.module.ts on lines 3..10
        src/app/log/log-routing.module.ts on lines 3..10
        src/app/map/map-routing.module.ts on lines 3..10
        src/app/mascots/mascots-routing.module.ts on lines 3..10
        src/app/policy/policy-routing.module.ts on lines 3..10
        src/app/pulse/pulse-routing.module.ts on lines 3..10
        src/app/rules/rules-routing.module.ts on lines 3..10
        src/app/top-view/top-view-routing.module.ts on lines 3..10

        Similar blocks of code found in 12 locations. Consider refactoring.
        Open

        export const routes: Routes = [
        {
        loadComponent: () => import('./rules.component').then((m) => m.RulesComponent),
        path: '',
        pathMatch: 'full',
        Severity: Major
        Found in src/app/rules/rules-routing.module.ts and 11 other locations - About 1 hr to fix
        src/app/about/about-routing.module.ts on lines 3..10
        src/app/brands/brands-routing.module.ts on lines 3..10
        src/app/chart/chart-routing.module.ts on lines 3..10
        src/app/index/index-routing.module.ts on lines 3..10
        src/app/log/log-routing.module.ts on lines 3..10
        src/app/map/map-routing.module.ts on lines 3..10
        src/app/mascots/mascots-routing.module.ts on lines 3..10
        src/app/policy/policy-routing.module.ts on lines 3..10
        src/app/pulse/pulse-routing.module.ts on lines 3..10
        src/app/telegram/telegram-routing.module.ts on lines 3..10
        src/app/top-view/top-view-routing.module.ts on lines 3..10

        Similar blocks of code found in 12 locations. Consider refactoring.
        Open

        export const routes: Routes = [
        {
        loadComponent: () => import('./pulse.component').then((m) => m.PulseComponent),
        path: '',
        pathMatch: 'full',
        Severity: Major
        Found in src/app/pulse/pulse-routing.module.ts and 11 other locations - About 1 hr to fix
        src/app/about/about-routing.module.ts on lines 3..10
        src/app/brands/brands-routing.module.ts on lines 3..10
        src/app/chart/chart-routing.module.ts on lines 3..10
        src/app/index/index-routing.module.ts on lines 3..10
        src/app/log/log-routing.module.ts on lines 3..10
        src/app/map/map-routing.module.ts on lines 3..10
        src/app/mascots/mascots-routing.module.ts on lines 3..10
        src/app/policy/policy-routing.module.ts on lines 3..10
        src/app/rules/rules-routing.module.ts on lines 3..10
        src/app/telegram/telegram-routing.module.ts on lines 3..10
        src/app/top-view/top-view-routing.module.ts on lines 3..10

        Similar blocks of code found in 12 locations. Consider refactoring.
        Open

        export const routes: Routes = [
        {
        loadComponent: () => import('./log.component').then((m) => m.LogComponent),
        path: '',
        pathMatch: 'full',
        Severity: Major
        Found in src/app/log/log-routing.module.ts and 11 other locations - About 1 hr to fix
        src/app/about/about-routing.module.ts on lines 3..10
        src/app/brands/brands-routing.module.ts on lines 3..10
        src/app/chart/chart-routing.module.ts on lines 3..10
        src/app/index/index-routing.module.ts on lines 3..10
        src/app/map/map-routing.module.ts on lines 3..10
        src/app/mascots/mascots-routing.module.ts on lines 3..10
        src/app/policy/policy-routing.module.ts on lines 3..10
        src/app/pulse/pulse-routing.module.ts on lines 3..10
        src/app/rules/rules-routing.module.ts on lines 3..10
        src/app/telegram/telegram-routing.module.ts on lines 3..10
        src/app/top-view/top-view-routing.module.ts on lines 3..10

        Similar blocks of code found in 12 locations. Consider refactoring.
        Open

        export const routes: Routes = [
        {
        loadComponent: () => import('./chart.component').then((m) => m.ChartComponent),
        path: '',
        pathMatch: 'full',
        Severity: Major
        Found in src/app/chart/chart-routing.module.ts and 11 other locations - About 1 hr to fix
        src/app/about/about-routing.module.ts on lines 3..10
        src/app/brands/brands-routing.module.ts on lines 3..10
        src/app/index/index-routing.module.ts on lines 3..10
        src/app/log/log-routing.module.ts on lines 3..10
        src/app/map/map-routing.module.ts on lines 3..10
        src/app/mascots/mascots-routing.module.ts on lines 3..10
        src/app/policy/policy-routing.module.ts on lines 3..10
        src/app/pulse/pulse-routing.module.ts on lines 3..10
        src/app/rules/rules-routing.module.ts on lines 3..10
        src/app/telegram/telegram-routing.module.ts on lines 3..10
        src/app/top-view/top-view-routing.module.ts on lines 3..10

        Similar blocks of code found in 12 locations. Consider refactoring.
        Open

        export const routes: Routes = [
        {
        loadComponent: () => import('./mascots.component').then((m) => m.MascotsComponent),
        path: '',
        pathMatch: 'full',
        Severity: Major
        Found in src/app/mascots/mascots-routing.module.ts and 11 other locations - About 1 hr to fix
        src/app/about/about-routing.module.ts on lines 3..10
        src/app/brands/brands-routing.module.ts on lines 3..10
        src/app/chart/chart-routing.module.ts on lines 3..10
        src/app/index/index-routing.module.ts on lines 3..10
        src/app/log/log-routing.module.ts on lines 3..10
        src/app/map/map-routing.module.ts on lines 3..10
        src/app/policy/policy-routing.module.ts on lines 3..10
        src/app/pulse/pulse-routing.module.ts on lines 3..10
        src/app/rules/rules-routing.module.ts on lines 3..10
        src/app/telegram/telegram-routing.module.ts on lines 3..10
        src/app/top-view/top-view-routing.module.ts on lines 3..10

        Similar blocks of code found in 12 locations. Consider refactoring.
        Open

        export const routes: Routes = [
        {
        loadComponent: () => import('./index.component').then((m) => m.IndexComponent),
        path: '',
        pathMatch: 'full',
        Severity: Major
        Found in src/app/index/index-routing.module.ts and 11 other locations - About 1 hr to fix
        src/app/about/about-routing.module.ts on lines 3..10
        src/app/brands/brands-routing.module.ts on lines 3..10
        src/app/chart/chart-routing.module.ts on lines 3..10
        src/app/log/log-routing.module.ts on lines 3..10
        src/app/map/map-routing.module.ts on lines 3..10
        src/app/mascots/mascots-routing.module.ts on lines 3..10
        src/app/policy/policy-routing.module.ts on lines 3..10
        src/app/pulse/pulse-routing.module.ts on lines 3..10
        src/app/rules/rules-routing.module.ts on lines 3..10
        src/app/telegram/telegram-routing.module.ts on lines 3..10
        src/app/top-view/top-view-routing.module.ts on lines 3..10

        Similar blocks of code found in 12 locations. Consider refactoring.
        Open

        export const routes: Routes = [
        {
        loadComponent: () => import('./top-view.component').then((m) => m.TopViewComponent),
        path: 'top-view',
        pathMatch: 'full',
        Severity: Major
        Found in src/app/top-view/top-view-routing.module.ts and 11 other locations - About 1 hr to fix
        src/app/about/about-routing.module.ts on lines 3..10
        src/app/brands/brands-routing.module.ts on lines 3..10
        src/app/chart/chart-routing.module.ts on lines 3..10
        src/app/index/index-routing.module.ts on lines 3..10
        src/app/log/log-routing.module.ts on lines 3..10
        src/app/map/map-routing.module.ts on lines 3..10
        src/app/mascots/mascots-routing.module.ts on lines 3..10
        src/app/policy/policy-routing.module.ts on lines 3..10
        src/app/pulse/pulse-routing.module.ts on lines 3..10
        src/app/rules/rules-routing.module.ts on lines 3..10
        src/app/telegram/telegram-routing.module.ts on lines 3..10

        Similar blocks of code found in 12 locations. Consider refactoring.
        Open

        export const routes: Routes = [
        {
        loadComponent: () => import('./about.component').then((m) => m.AboutComponent),
        path: '',
        pathMatch: 'full',
        Severity: Major
        Found in src/app/about/about-routing.module.ts and 11 other locations - About 1 hr to fix
        src/app/brands/brands-routing.module.ts on lines 3..10
        src/app/chart/chart-routing.module.ts on lines 3..10
        src/app/index/index-routing.module.ts on lines 3..10
        src/app/log/log-routing.module.ts on lines 3..10
        src/app/map/map-routing.module.ts on lines 3..10
        src/app/mascots/mascots-routing.module.ts on lines 3..10
        src/app/policy/policy-routing.module.ts on lines 3..10
        src/app/pulse/pulse-routing.module.ts on lines 3..10
        src/app/rules/rules-routing.module.ts on lines 3..10
        src/app/telegram/telegram-routing.module.ts on lines 3..10
        src/app/top-view/top-view-routing.module.ts on lines 3..10

        Similar blocks of code found in 12 locations. Consider refactoring.
        Open

        export const routes: Routes = [
        {
        loadComponent: () => import('./brands.component').then((m) => m.BrandsComponent),
        path: '',
        pathMatch: 'full',
        Severity: Major
        Found in src/app/brands/brands-routing.module.ts and 11 other locations - About 1 hr to fix
        src/app/about/about-routing.module.ts on lines 3..10
        src/app/chart/chart-routing.module.ts on lines 3..10
        src/app/index/index-routing.module.ts on lines 3..10
        src/app/log/log-routing.module.ts on lines 3..10
        src/app/map/map-routing.module.ts on lines 3..10
        src/app/mascots/mascots-routing.module.ts on lines 3..10
        src/app/policy/policy-routing.module.ts on lines 3..10
        src/app/pulse/pulse-routing.module.ts on lines 3..10
        src/app/rules/rules-routing.module.ts on lines 3..10
        src/app/telegram/telegram-routing.module.ts on lines 3..10
        src/app/top-view/top-view-routing.module.ts on lines 3..10

        Similar blocks of code found in 2 locations. Consider refactoring.
        Open

        if (xmin / xscale && Math.abs(xsize) < xmin / xscale) {
        x2 = xsize > 0 ? x1 + xmin / xscale : x1 - xmin / xscale;
        }
        Severity: Major
        Found in src/app/jcrop/jquery.Jcrop.js and 1 other location - About 1 hr to fix
        src/app/jcrop/jquery.Jcrop.js on lines 734..736

        Similar blocks of code found in 2 locations. Consider refactoring.
        Open

        if (ymin / yscale && Math.abs(ysize) < ymin / yscale) {
        y2 = ysize > 0 ? y1 + ymin / yscale : y1 - ymin / yscale;
        }
        Severity: Major
        Found in src/app/jcrop/jquery.Jcrop.js and 1 other location - About 1 hr to fix
        src/app/jcrop/jquery.Jcrop.js on lines 737..739

        Function dragmodeHandler has 35 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

        function dragmodeHandler(mode, f) {
        return function(pos) {
        if (!options.aspectRatio) {
        switch (mode) {
        case 'e':
        Severity: Minor
        Found in src/app/jcrop/jquery.Jcrop.js - About 1 hr to fix

          Similar blocks of code found in 9 locations. Consider refactoring.
          Open

          2: {
          'add-sub-item': $localize`Add sub-engine`,
          name: $localize`Engine`,
          'name-plural': $localize`Engines`,
          'new-item': $localize`New engine`,
          Severity: Major
          Found in src/app/utils/translations.ts and 8 other locations - About 1 hr to fix
          src/app/utils/translations.ts on lines 4..9
          src/app/utils/translations.ts on lines 16..21
          src/app/utils/translations.ts on lines 22..27
          src/app/utils/translations.ts on lines 28..33
          src/app/utils/translations.ts on lines 34..39
          src/app/utils/translations.ts on lines 40..45
          src/app/utils/translations.ts on lines 46..51
          src/app/utils/translations.ts on lines 52..57
          Severity
          Category
          Status
          Source
          Language