Skip to content

Commit cc9866b

Browse files
committed
use ConfigProvider instead
1 parent 1020ad3 commit cc9866b

File tree

5 files changed

+172
-153
lines changed

5 files changed

+172
-153
lines changed

.changeset/big-kangaroos-enjoy.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,4 @@
22
"@ensembleui/react-runtime": patch
33
---
44

5-
enhance DataGrid with rowHoverStyle and hideSelectAll props for improved styling and functionality
5+
enhance DataGrid with rowHoverBg and rowSelectedHoverBg styles

apps/kitchen-sink/src/ensemble/screens/widgets.yaml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -526,6 +526,8 @@ View:
526526
hasDivider: true
527527
borderBottom: false
528528
hidePagination: true
529+
allowSelection: true
530+
hideSelectAll: true
529531
DataColumns:
530532
- label: Number
531533
scroll:
@@ -540,6 +542,10 @@ View:
540542
name: dummyData
541543
template:
542544
DataRow:
545+
styles:
546+
backgroundColor: lime
547+
rowHoverStyle:
548+
backgroundColor: yellow
543549
children:
544550
- Text:
545551
id: ${'x_'+index}

packages/runtime/src/widgets/Collapsible.tsx

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -233,6 +233,12 @@ export const Collapsible: React.FC<CollapsibleProps> = (props) => {
233233
expandIconPosition={props.expandIconPosition}
234234
items={[...collapsibleItems, ...templateItems]}
235235
onChange={handleCollapsibleChange}
236+
style={{
237+
...values?.styles,
238+
...(values?.styles?.visible === false
239+
? { display: "none" }
240+
: undefined),
241+
}}
236242
/>
237243
</ConfigProvider>
238244
);

0 commit comments

Comments
 (0)