innoq / tabelle Goto Github PK
View Code? Open in Web Editor NEWA library for generating pretty filterable and sortable tables that use your backend of choice
License: Apache License 2.0
A library for generating pretty filterable and sortable tables that use your backend of choice
License: Apache License 2.0
When a user does a search that comes back with no results, I want to show a helpful hint like "Your search did not return any results." I want to be able to translate this and I want to be able to style it, so I would like to generate that answer on the server side. However, I can currently only return a tbody, so I don't have that option. Suggestion:
The user needs to provide an id
on the ta-belle
element. If they don't, they will receive an error (I think I would just do a console.error("...")
and then not activate ta-belle). When ta-belle receives the answer from the server, it will search for the element with the same ID and replace its content with the content of that element. Afterwards, it will re-add the filters. This allows users to add additional elements to the response other than the table.
What do you think? Thanks for the project, it really helps me get things done <3
Currently, the labels for the components that are generated by the custom element (e.g. sort arrows, filter field) are hard coded so that they contain English text. We should add an option to customize the texts so that Tabelle can be used in other languages.
The SVGs for the arrows have hard-coded paths, so if you install tabelle as an NPM package, the images won't be found:
https://github.com/innoq/tabelle/blob/master/components/atoms/radio-arrow/_radio-arrow.scss#L7
This needs to be configurable somehow ๐ค
I think the README would benefit from a GIF screencapture of ta-belle in action. When I search for libraries that offer UI stuff, I always like to see it in action โ and I prefer to do that without needing to install it first ๐ธ
The customElements polyfill should not be a part of this bundle, but rather should be able to be added explicitly by users only when they need it.
I used tabelle for a form where I have a query parameter that I need to be submitted alongside the tabelle parameters. Let's say I have invoices
, and I always filter them by their status:
/invoices?status=paid
So I did this:
<ta-belle search-src="/invoices?status=paid">
...
</ta-belle>
When I do this, I get the following exception:
query strings are invalid within
GET
forms' action
The solution is to do this:
<ta-belle>
<form action="/invoices">
<input type="hidden" name="status" value="paid">
</form>
</ta-belle>
I like the solution, but I think that:
What do you think? Thanks for the project, it really helps me get things done <3
This is a JavaScript only feature (because you can't deselect a radio button in HTML), but it would be nice.
If you install tabelle as an NPM package, you have to import it like this:
import 'tabelle/dist/tabelle';
We can shorten that to:
import 'tabelle';
by setting the main
attribute in the package.json to dist/tabelle.js
๐
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.