Skip to content

Commit 6ccd563

Browse files
committed
fix: resolve multiple UI issues in demo application
- Fix #78: Apply consistent middle alignment to all grid cells - Added display: flex and align-items: center to .ag-cell - Ensured custom renderers respect vertical alignment - Fix #76: Address AG Grid footer issues - Modified StatusRenderer and PriorityRenderer to return null in footer/total rows - This prevents empty pill outlines from rendering in grand total row - Fix #80: Remove NPM button from demo header - Removed NPM button, keeping only GitHub button - Header layout remains clean and functional All fixes maintain existing functionality without introducing regressions.
1 parent c6a2b74 commit 6ccd563

File tree

4 files changed

+30
-22
lines changed

4 files changed

+30
-22
lines changed

src/demo/components-showcase-complete.tsx

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -67,18 +67,6 @@ const Navigation: React.FC<{
6767
</div>
6868
<div className="flex items-center gap-4">
6969
<VersionInfo className="hidden md:block" />
70-
<a
71-
href="https://www.npmjs.com/package/ag-grid-react-components"
72-
target="_blank"
73-
rel="noopener noreferrer"
74-
className="flex items-center gap-2 px-4 py-2 bg-gray-800 hover:bg-gray-700 rounded-lg transition-colors"
75-
>
76-
<svg className="w-5 h-5" fill="currentColor" viewBox="0 0 256 256">
77-
<path d="M0 256V0h256v256z" />
78-
<path d="M128 128v128h128V0H128z" fill="#C12127" />
79-
</svg>
80-
NPM
81-
</a>
8270
<a
8371
href="https://github.com/ryanrozich/ag-grid-react-components"
8472
target="_blank"

src/demo/config/sharedGridConfig.tsx

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,12 @@ export const darkTheme = themeQuartz.withParams({
3434
});
3535

3636
// Status chip renderer
37-
export const StatusRenderer: React.FC<ICellRendererParams> = ({ value }) => {
37+
export const StatusRenderer: React.FC<ICellRendererParams> = ({ value, node }) => {
38+
// Don't render anything in footer/total rows
39+
if (node?.footer || node?.aggData) {
40+
return null;
41+
}
42+
3843
const getStatusColor = (status: string) => {
3944
switch (status) {
4045
case "Backlog":
@@ -68,7 +73,12 @@ export const StatusRenderer: React.FC<ICellRendererParams> = ({ value }) => {
6873
};
6974

7075
// Priority chip renderer
71-
export const PriorityRenderer: React.FC<ICellRendererParams> = ({ value }) => {
76+
export const PriorityRenderer: React.FC<ICellRendererParams> = ({ value, node }) => {
77+
// Don't render anything in footer/total rows
78+
if (node?.footer || node?.aggData) {
79+
return null;
80+
}
81+
7282
const getPriorityColor = (priority: string) => {
7383
switch (priority) {
7484
case "Critical":

src/demo/styles/showcase-dark.css

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -200,6 +200,8 @@ font-family:
200200

201201
.ag-theme-quartz-dark .ag-cell {
202202
line-height: var(--ag-row-height);
203+
display: flex;
204+
align-items: center;
203205
}
204206

205207
/* Numeric cells styling */
@@ -395,6 +397,14 @@ font-family:
395397
border-radius: 4px;
396398
}
397399

400+
/* Ensure custom cell renderers respect alignment */
401+
.ag-theme-quartz-dark .ag-cell .pill-renderer,
402+
.ag-theme-quartz-dark .ag-cell .avatar-renderer {
403+
display: flex;
404+
align-items: center;
405+
height: 100%;
406+
}
407+
398408
/* Custom scrollbar */
399409
.ag-theme-quartz-dark ::-webkit-scrollbar {
400410
width: 10px;

src/demo/version-info.json

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
{
22
"version": "0.2.0-rc1",
33
"git": {
4-
"commitHash": "b1ba6bf2f6c13897f70b4bceb9bf94a459525d5e",
5-
"shortHash": "b1ba6bf",
6-
"branch": "fix/e2e-test-selectors",
7-
"commitDate": "2025-07-09 18:27:31 -0500",
4+
"commitHash": "c6a2b7440d5a36f779178c92e13a5b5cbe16c7bd",
5+
"shortHash": "c6a2b74",
6+
"branch": "fix/bundled-ui-fixes",
7+
"commitDate": "2025-07-09 23:21:14 -0500",
88
"latestTag": "v0.1.1-rc1",
9-
"commitsSinceTag": 31,
9+
"commitsSinceTag": 34,
1010
"isDirty": true
1111
},
1212
"deployment": {
@@ -15,7 +15,7 @@
1515
"isMainBranch": false,
1616
"deployPath": "ag-grid-react-components"
1717
},
18-
"buildTime": "2025-07-10T02:55:14.965Z",
19-
"displayVersion": "v0.2.0-rc1+31",
20-
"displayLabel": "fix/e2e-test-selectors"
18+
"buildTime": "2025-07-10T04:51:20.271Z",
19+
"displayVersion": "v0.2.0-rc1+34",
20+
"displayLabel": "fix/bundled-ui-fixes"
2121
}

0 commit comments

Comments
 (0)