JSFiddle - React, Tailwind, and code Playground

by Diman0o

JavaScript

import range from 'lodash/range'

export default function () {
  return {
    columns: [
      {
        title: 'M.S.',
        visible: true,
        fields: 'rating_ms',
        formatter: 'html',
        headerTooltip: (column) => 'индекс M.S.',
        width: 43,
        id: 1,
      },
      {
        title: 'ABC',
        visible: true,
        field: 'select_abc',
        formatter: 'html',
        headerTooltip: (column) => 'Селекция ABC',
        align: 'center',
        width: 43,
        id: 2,
      },
      {
        title: 'M.S.',
        visible: true,
        fields: 'edite',
        formatter: 'html',
        headerTooltip: (column) => 'индекс M.S.',
        width: 43,
        id: 3,
      },
      {
        title: 'Контракт',
        visible: true,
        field: 'contract_player',
        formatter: 'html',
        headerTooltip: (column) => 'Контракт',
        width: 43,
        id: 4,
      },
      {
        title: '<i class="fas fa-play"></i>',
        visible: true,
        field: 'game_views',
        formatter: 'html',
        headerTooltip: (column) => 'просмотры игр',
        width: 43,
        id: 5,
      },
      {
        title: '<i class="fas fa-star" styles="color: #1eb34d"></i>',
        visible: true,
        field: 'level_player',
        formatter: 'html',
        headerTooltip: (column) => 'Уровень Игрока',
        align: 'center',
        width: 50,
        id: 6,
      },
      {
        title: '"A"',
        visible: true,
        field: 'national_a',
        formatter: 'html',
        align: 'center',
        headerTooltip: (column) => 'Национальная команды',
        width: 43,
        id: 7,
      },
      {
        title: '"OL"',
        visible: true,
        field: 'national_ol',
        formatter: 'html',
        align: 'center',
        headerTooltip: (column) => 'Олимпийская сборная',
        width: 43,
        id: 8,
      },
      {
        title: '"U21"',
        visible: true,
        field: 'national_u21',
  ...