Commit graph

77 commits

Author SHA1 Message Date
Eric Liu
7481b9a995
feat(data-table): allow custom inputName for radio/checkbox (#2087)
Closes #2085
2025-03-09 13:47:08 -07:00
Eric Liu
e874ac19d7 fix(data-table): improve expandable accessibility (#2086) 2025-01-19 17:38:25 -08:00
Eric Liu
dd6cbac3ee fix(data-table): prefix internal ID for radio button, checkbox (#2082)
Fixes #2081
2025-01-19 17:38:25 -08:00
Eric Liu
8e996dc683 chore: format files with Prettier 3 2024-11-11 21:35:48 -08:00
Eric Liu
dd43224119
feat(data-table): support generics (#1954)
Co-authored-by: K.Kiyokawa <koichi20110068@gmail.com>
Co-authored-by: brunnerh <brunnerh@users.noreply.github.com>
2024-11-11 21:10:45 -08:00
Eric Liu
3192824322
fix(data-table): handle ToolbarSearch filtering in DataTable (#2037) 2024-11-10 09:27:27 -08:00
Eric Liu
44daa775d5
fix(data-table): fix DataTableValue type reference in DataTable (#2023) 2024-10-25 15:49:35 -07:00
berndfuhrmann
9132bf8e5a
fix(data-table): loosen sort return type to be a number (#1935)
Fixes #1934

Loosen the `sort` return type from `0 | 1 | -1` to `number`.
2024-03-13 09:55:02 -07:00
Alex Rock
9456eaab3c
feat(data-table): pass row to display function (#1810) 2023-10-01 10:19:13 -07:00
Bilux
ae34451583
fix(data-table): remove unused import from "svelte/store" (#1529) 2022-10-20 10:21:12 -07:00
metonym
f794cb5312
feat(data-table): dispatch on:click:header--select event (#1453)
* feat(data-table): dispatch `on:click:header--select` event

* Run "yarn build:docs"
2022-08-17 10:19:31 -07:00
naegelin
30487128b3
feat(data-table): dispatch on:click:row--select event (#1450) 2022-08-17 06:39:03 -07:00
jorgebv
0f060ea035
fix(data-table): table header keys should be reactive (#1346)
Fixes #1345

Co-authored-by: Jorge Vergara <jbvergara@bethel.jw.org>
2022-06-12 18:09:33 -07:00
metonym
e56ee83dc4
hotfix(data-table): column sort direction order should be independent (#1342)
Fixes #1341
2022-06-09 11:14:14 -07:00
metonym
95b32937d6
perf(data-table): save rows reference when reducing (#1338)
d2cdb8eb0f (r75383503)
2022-06-05 14:24:37 -07:00
metonym
72c24b83b2
feat(data-table): support programmatic sorting (#1337)
* refactor(data-table): pass down sortable props instead of using context

* feat(data-table): support programmatic sorting

* test(data-table): assert new props

* docs(data-table): add "Programmatic sorting" example

* refactor(data-table): remove unused tableSortable store

* refactor(data-table): remove unused indices
2022-06-05 13:37:50 -07:00
metonym
d2cdb8eb0f
fix(data-table): do not overwrite row.cells property (#1336)
* refactor(data-table): remove unneeded third argument from resolvePath call

* fix(data-table): do not overwrite `cells` property (#667)

* perf(data-table): early return if path in object when resolving path
2022-06-05 13:29:58 -07:00
metonym
260bf4e040
breaking(types): type arrays as read-only (#1335)
Closes #1259

* breaking(types): type arrays as read-only

* Run "yarn build:docs"

* test: assert read-only arrays
2022-06-05 13:25:43 -07:00
metonym
31dacd53ab
fix(data-table): apply custom widths to empty columns (#1314)
Fixes #1313
2022-05-25 18:50:55 -07:00
metonym
c6f210899b
feat(data-table): allow custom column widths (#1265)
* feat(data-table): allow header column `width`, `minWidth` values

* Run "yarn build:docs"

* test(data-table): assert width, minWidth properties

* docs(data-table): add "Custom column widths" example
2022-05-14 09:24:24 -07:00
metonym
6239c11024
breaking(data-table): use data attribute instead of id for table header/row (#1297)
Fixes #1294
2022-05-13 20:18:32 -07:00
Nicolas Peugnet
43e2986434
fix(data-table): rows should be reactive (#1255) 2022-04-18 17:50:19 -07:00
metonym
ba58ba8f00
refactor: use icons from carbon-icons-svelte@11 (#1227)
* chore: update ignore rules, remove unused files

* refactor(icons): use icons from carbon-icons-svelte@11

* docs(time-picker): fix default value

* chore: upgrade carbon-icons-svelte to v11

* docs: update examples to use icons from carbon-icons-svelte@11

* docs: update number of icons [ci skip]
2022-04-03 11:57:28 -07:00
metonym
051a8702e3
perf(data-table): only render table row content when expanded (#1211)
Closes #1209
2022-03-25 06:49:58 -07:00
metonym
53fdbdf991
fix(data-table): expandable rows should work with zebra styles (#1200)
Fixes #1199
2022-03-23 08:04:08 -07:00
metonym
2df7b92269
feat(toolbar-search): support auto-filterable rows (#1179)
Closes #591
2022-03-19 12:01:03 -07:00
metonym
95a1dfa1af
feat(data-table): support non-selectable rows (#1166)
Closes #1148
2022-03-12 19:36:02 -08:00
metonym
48348df43d
perf: use direct imports where possible (#1158) 2022-03-12 13:50:40 -08:00
metonym
dce0309bab
fix(data-table): pass header key to TableHeader (#1114)
The id is needed to update the sort icon direction accordingly.

Fixes #1113
2022-02-21 08:33:41 -08:00
metonym
3b70a35df6
feat(data-table): pass row index, cell index to "cell" slot (#1086) 2022-02-11 07:13:55 -08:00
metonym
34affd851a
fix(data-table): batch selection checkbox should be reactive (#1085) 2022-02-10 19:51:26 -08:00
metonym
a5f5550aa0
fix(data-table): headers should be reactive (#1075)
If `headers` is dynamically updated, clicking a sortable table header will sort the incorrect column. Instead of randomly generating an id and keeping track of it through context, we can simply use the required key in `headers` as the id.
2022-02-09 19:48:20 -08:00
kwieszalka-maystreet
5da83ec869
feat(data-table): support paginated data table (#880)
Closes #702
2022-01-19 07:51:42 -08:00
Eric Liu
ae96fdf3d9
fix(data-table): forgo "click", "click:row" events if target is a checkbox, radio button (#951)
Fixes #933
2021-12-28 13:26:09 -08:00
Eric Liu
4f83b2d1e1
fix(data-table): forgo "click", "click:row" events if target is an OverflowMenu (#918)
#917
2021-11-19 08:29:16 -08:00
Eric Liu
040e3d3372
Inline carbon icons, remove carbon-icons-svelte from dependencies (#904)
* feat(icons): inline carbon icons used by components

* feat(icons): update svelte components to use inlined carbon icons

* breaking(deps): remove carbon-icons-svelte

* chore(deps-dev): install carbon-icons-svelte as a devDependency
2021-11-11 08:54:45 -08:00
Eric Liu
b3a73cf80c
fix(data-table): avoid triggering click:row when clicking expandable row chevron (#890)
Fixes #889
2021-11-06 10:33:33 -07:00
Eric Liu
fb7ebb93cb
fix(data-table): expand batch expansion chevron if all rows are expanded #867 (#873)
Fixes #867
2021-10-22 07:18:03 -07:00
Eric Liu
2aeeb728a2
fix(data-table): collapse batch expansion button if one or more rows collapsed #867 (#868) 2021-10-20 17:45:53 -07:00
Eric Liu
c64075acbe
fix(data-table): include border style for non-expandable rows (#864)
* fix(data-table): include border style for non-expandable rows

Fixes #861

* docs(data-table): use batchExpansion for non-expandable rows example [ci skip]
2021-10-20 10:02:10 -07:00
Eric Liu
96d848e9ef
feat(data-table): add nonExpandableRowIds prop (#862)
* feat(data-table): add nonExpandableRowIds prop #861

* test(data-table): validate nonExpandableRowIds prop

* docs(data-table): add Non-expandable rows example
2021-10-19 07:25:22 -07:00
Paweł Malinowski
d3eb146fb5
fix(DataTable): handle null/undefined values when sorting (#846) 2021-10-11 10:11:59 -07:00
Florian-Schoenherr
dbf1f225dc
fix(DataTable): useStaticWidth fix for title/description (#824)
* fix(DataTable): useStaticWidth title/description

Signed-off-by: Florian-Schoenherr <florian.schoenherr99@gmail.com>

* docs(DataTable): useStaticWidth title/description

Signed-off-by: Florian-Schoenherr <florian.schoenherr99@gmail.com>

* chore(deps-dev): upgrade carbon-components, sass

Co-authored-by: metonym <ericyl.us@gmail.com>
2021-09-23 08:55:06 -07:00
Nguyễn Trường Minh
89513fb4cb
fix(DataTable): undefined cell value fallback (#745)
* fix(DataTable): undefined cell value fallback

* Update DataTable.svelte

* fix(data-table): remove "" as the default value for table cells

Co-authored-by: Eric Y Liu <ericyl.us@gmail.com>
2021-07-15 06:37:42 -07:00
Eric Liu
a1e56bd135
Fixes (#749)
* fix(data-table): type DataTableRowId as "any" #530

Fixes #530

* fix(tree-view): make first node focusable if activeId does not match selected

* fix(overflow-menu): set type="button" to prevent default submit behavior #554

Fixes #554

* fix(overflow-menu): update semantic attributes in OverflowMenuItem

* fix(number-input): do not dispatch change event on initialization #561

Fixes #561

* fix(tree-view): make first focusable node tabbable regardless of active/selected states

* fix(date-picker): load rangePlugin dynamically

* build(rollup): enable inlineDynamicImports

* build(rollup): remove "clipboard-copy" global

* fix(overflow-menu): do not render title if using a slot #537

Fixes #537

* fix(select): forward missing focus, input events #501

Fixes #501
2021-07-14 13:48:23 -07:00
Eric Liu
0a69f8ec74
Various features/fixes (#727)
* fix(data-table): export useStaticWidth prop

* docs(data-table): add static width example

* fix(data-table): do not render table header if title/description not provided

* feat(modal): dispatch "click:button--primary" as an alias to "submit"

* test: update DataTable types test

* test(modal): update modal type tests

* docs(data-table): add clear reminder to key headers/rows
2021-07-05 13:22:56 -07:00
Eric Liu
5fee13b2eb
feat(data-table): make title, description slottable #720 (#722)
Closes #720
2021-07-05 08:44:07 -07:00
Eric Liu
f9909827d0
Align v10.34 (#621)
* feat(theme): add g80 theme

* docs(data-table): use link with icon variant

* feat(search): support expandable variant

* fix(file-uploaded): use semantic p element instead of strong

* feat(side-nav): dispatch open, close, click:overlay events

* refactor(ui-shell): remove usage of deprecated Icon component

* feat(ui-shell): allow custom hamburger menu icons

* feat(button): support xl size

* fix(code-snippet): wrap code element with pre

* refactor(button): use button specific tooltip class for icon-only variant

* feat(password-input): support warning, inline props

* feat(data-table): support medium size
2021-06-25 03:45:30 -07:00
Eric Y Liu
cff16e5d7d v0.33.0 2021-04-30 17:12:02 -07:00
mabentley85
081783c719
Fix the colspan when a DataTable is Expandable and Selectable (#618) 2021-04-30 16:24:35 -07:00