kos / rtable Goto Github PK
View Code? Open in Web Editor NEWAJAX-powered table / data grid component
License: ISC License
AJAX-powered table / data grid component
License: ISC License
I want to be able to define:
The idea I have is to break down RTable.render() so that it doesn't produce any HTML on its own, but rather delegates pieces of its own state to sub-components that can be replaced individually.
The default sub-components should also offer some more flexibility, esp. the class names used, so that it's easy to make it "look like bootstrap" or "look like semantic ui" without actually redefining the react components.
Currently there can reasonably be only one RTable on a page, and it completely dominates the URL's query string.
In order to have several of these on one page, one of the following needs to happen:
a. they no longer read from or update window.location. The table state might be retained somewhere else in this case (like the session storage).
b. they still work with window.location, but each has a separate prefix. The page URL contains parameters for each table on the page.
Both approaches could be implemented as opt-in.
The code assumes a lot about page numbers - that they are integers and the initial page is 1.
When possible, the page number should be treated as an opaque identifier, so that you can paginate using cursors as well as page numbers. Page numbers shouldn't be generally produced by RTable, only taken from incoming DataResponses.
However, we'd still want to allow extra features that base on numerical pages, like "showing page 5 of 123" or "go to page 5". This might mean that RTable would have a separate mode for numerical and opaque page identifiers. Or we could just look at DataResponse and decide what to show (as in, if we have count and the page identifier is numeric, then assume sequential pages)
Currently the ordering works on only one column at the time. Why?
Clicking on several headers in sequence should remember the state of previous headers clicked, giving the functional equivalent of stable sorting.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.