Giter VIP home page Giter VIP logo

gigatables / reactables Goto Github PK

View Code? Open in Web Editor NEW
142.0 142.0 32.0 14.77 MB

GigaTables is a ReactJS plug-in to help web-developers process table-data in applications and CMS, CRM, ERP or similar systems.

License: MIT License

HTML 0.13% JavaScript 93.50% CSS 6.37%
autoload grid grids infinite-scroll javascript material-ui pagination react reactjs reactjs-components reactjs-es6 sortable table table-search tables webpack2

reactables's Issues

Implement arrow row selection movements by W3C wai-aria-practices-1.1

Ctrl+Down Arrow: Moves focus one cell down. If focus is on the bottom cell in the column, focus does not move.
Ctrl+Up Arrow: Moves focus one cell Up. If focus is on the top cell in the column, focus does not move.
Ctrl+End: Moves focus down an author-determined number of rows, typically scrolling so the bottom row in the currently visible set of rows becomes one of the first visible rows. If focus is in the last row of the grid, focus does not move.
Ctrl+Home: Moves focus up an author-determined number of rows, typically scrolling so the top row in the currently visible set of rows becomes one of the last visible rows. If focus is in the first row of the grid, focus does not move.

Ctrl is crucial to move selection of rows bc user may want to just scroll by those keys.

Unable to render Reactables

Hello! I am implementing a table without editor settings for a React app I'm creating, as I don't need the editor portion. I get error Uncaught TypeError: Cannot read property 'fields' of undefined when the component attempts to load in browser. In Firefox, I see TypeError: t is undefined, but I don't know if that's a separate issue.

React Version: 15.5.4

Not an issue - Just help needed

Hi,

I am trying to test your tables in my react project as your component is the closest to my requirement.

I cant for the life of me get it to work though, here is my code below, maybe you can tell me if im doing something wrong. Im a newbie with react, so this could be adding to the problem but Ive tried for many hours, so please bare with me.

I have populated the test.php file with the same code from your php file and when i run it in my terminal it renders the results.

When I run this my main container div in the app is rendering nothing, not even the card.

import React from 'react';
import { Reactables, Header, editor } from 'gigatables-react';
import { Card, CardTitle} from 'reactstrap';

var settings = {
struct: {
search: ['top', 'bottom'],
rowsSelector: ['desc', 'top', 'bottom'],
pagination: ['bottom']
},
lang: 'en', // english default
perPageRows: [25, 50, 100, 200],
defaultPerPage: 100,
ajax: 'test.php',
// ajaxAutoloadData: true, // default false
// ajaxAutoloadPeriod: 8, // sec
requestType: 'GET',
columns: [
{// include all defaults
data: "id",
sortable: true, // true by defualt
visible: true, // true by defualt
searchable: true, // true by defualt
discreteSearch: true, // false by default
discreteSearchValue: function (title) {
return 'Search by field - ' + title;
}
},
{
data: "title",
cISearch: true // default false
},
{
data: "desc",
sortable: false,
discreteSearch: true,
discreteCISearch: true // default false
},
{
data: "date",
searchable: false
},
{
data: "info"
},
{data:"field1"},
{data:"field2"},
{data:"field3", visible: false}
],
columnOpts: [
{
render: (data, row, type) => (





{data}


),
target: 'title' // provide data column index to match opts
},
{
render: (data, row, type) => (

{data}

{(row.id % 2 === 0) ? '**' : '*'}


),
target: 'date'
}
],
tableOpts: {
buttons: [
{extended: "editor_create", editor: editor, triggerAfter: (function () {
console.log('after create');
}), triggerBefore: (function () {
console.log('before create');
})},
{extended: "editor_edit", editor: editor, triggerBefore: (function () {
console.log('before edit');
})},
{extended: "editor_remove", editor: editor, triggerAfter: (function () {
console.log('after del');
})}
],
buttonsPosition: ['top', 'bottom'],
theme: 'std'
}
};

export default class UserManPage extends React.Component {

render() {
return (

  <div>
    <Card block>
      <CardTitle>My Table</CardTitle>
        <Reactables editor={editor} settings={settings}>
          <Header data="id">ID</Header>
          <Header data="title">Name</Header>
          <Header data="desc">Description</Header>
          <Header data="date">Date</Header>
          <Header data="info">Info</Header>
          <Header data="field2">Field123 but data from field2</Header>
          <Header data="field1">Field1</Header>
          <Header data="field3">Field3 invisible</Header>
          <Header>Field3 invisible</Header>
        </Reactables>
    </Card>
  </div>
);

}
}

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.