hikaya-io / hakawati

A collection of UI components
GNU General Public License v3.0
2 stars 1 forks source link

feat: Add default filter on h-table #360

Closed michaelbukachi closed 2 years ago

michaelbukachi commented 2 years ago

What is the Purpose?

Adds default filters on each column based on values of the h-table

What was the approach?

Briefly describe the approach used to address the issue

Are there any concerns to addressed further before or after merging this PR?

State some additional info if any. For instance running install or setting some environment variable(s)

Mentions?

Mention persons you'd like to review this PR @andrewtpham @ninetteadhikari

Issue(s) affected?

List of issues addressed by this PR. Resolves #241

andrewtpham commented 2 years ago

Hey @michaelbukachi the filters look good! On the story H Table With Filters Enabled I noticed all the columns have the filters enabled. Are we able to control which columns have filters enabled when we use this component? I think being able to enable filters for columns we know will within a set of options is helpful while disabling for columns where it is a string field where each row might be unique: image

michaelbukachi commented 2 years ago

@andrewtpham yes. I've added a filterable-columns property which when populated, only enables filters on the passed columns.

michaelbukachi commented 2 years ago

@andrewtpham Done.

amosnjoroge commented 2 years ago

@michaelbukachi Is it possible to move the table to the 1.0 section as agreed on Monday?

ninetteadhikari commented 2 years ago

we can merge this and move to 1.0 in a separate PR cc: @amosnjoroge