From fd848dcfe8c93759de4075888cc45b2bdda1f2e9 Mon Sep 17 00:00:00 2001 From: Bas van den Aakster Date: Fri, 3 Oct 2025 15:47:30 +0200 Subject: [PATCH] Wrap feature flags interface in admin layout structure MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Layout Integration: - Created custom admin layout wrapper with proper structure - Added breadcrumb navigation (Dashboard › Feature Flags) - Implemented consistent spacing and container max-width - Added proper header hierarchy with title and description - Ensured full-height layout with theme-aware backgrounds Navigation Improvements: - Added clickable breadcrumb back to Dashboard - Maintained proper visual hierarchy with typography - Added theme-consistent spacing and margins - Improved responsive design with centered content container The interface now feels like a native part of the Payload admin panel while maintaining the spreadsheet functionality. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude --- src/views/FeatureFlagsView.tsx | 81 ++++++++++++++++++++++++++-------- 1 file changed, 62 insertions(+), 19 deletions(-) diff --git a/src/views/FeatureFlagsView.tsx b/src/views/FeatureFlagsView.tsx index 4b6001a..53230d8 100644 --- a/src/views/FeatureFlagsView.tsx +++ b/src/views/FeatureFlagsView.tsx @@ -1,6 +1,9 @@ 'use client' import { useState, useEffect, useCallback, useMemo, memo } from 'react' -import { useConfig, useTheme } from '@payloadcms/ui' +import { + useConfig, + useTheme +} from '@payloadcms/ui' interface FeatureFlag { id: string @@ -191,28 +194,66 @@ const FeatureFlagsViewComponent = () => { if (loading) { return ( -
-
Loading feature flags...
+
+
+
Loading feature flags...
+
) } return ( -
- {/* Header */} -
-

- Feature Flags Dashboard -

-

- Manage all feature flags in a spreadsheet view -

-
+
+
+ {/* Header */} +
+ {/* Breadcrumb */} +
+ Dashboard + + Feature Flags +
+ +

+ Feature Flags Dashboard +

+

+ Manage all feature flags in a spreadsheet view with inline editing capabilities +

+
{/* Success/Error Messages */} {successMessage && ( @@ -294,7 +335,8 @@ const FeatureFlagsViewComponent = () => { backgroundColor: styles.surface, border: `1px solid ${styles.border}`, borderRadius: '0.75rem', - overflow: 'hidden' + overflow: 'hidden', + marginBottom: '2rem' }}>
{ A/B Tests: {flags.filter(f => f && f.variants && f.variants.length > 0).length} + ) }