@@ -69,6 +69,12 @@ public static function form(Form $form): Form
69
69
->helperText (flexiblePagesTrans ('menus.form.code_help ' )),
70
70
];
71
71
72
+ $ formFields [] = Textarea::make ('description ' )
73
+ ->label (flexiblePagesTrans ('menus.form.description_lbl ' ))
74
+ ->rows (3 )
75
+ ->helperText (flexiblePagesTrans ('menus.form.description_help ' ))
76
+ ->columnSpan (2 );
77
+
72
78
// Only show style field if there are multiple styles available
73
79
if ($ showStyleField ) {
74
80
$ formFields [] = Select::make ('style ' )
@@ -87,16 +93,11 @@ public static function form(Form $form): Form
87
93
->placeholder (FilamentFlexibleContentBlockPages::config ()->getMenuMaxDepth ())
88
94
->helperText (flexiblePagesTrans ('menus.form.max_depth_help ' ));
89
95
90
- $ formFields [] = Textarea::make ('description ' )
91
- ->label (flexiblePagesTrans ('menus.form.description_lbl ' ))
92
- ->rows (3 )
93
- ->helperText (flexiblePagesTrans ('menus.form.description_help ' ));
94
-
95
96
return $ form
96
97
->schema ([
97
98
Section::make (flexiblePagesTrans ('menus.form.general_section ' ))
98
99
->schema ($ formFields )
99
- ->columns (1 ),
100
+ ->columns (2 ),
100
101
]);
101
102
}
102
103
@@ -123,24 +124,6 @@ public static function table(Table $table): Table
123
124
->badge ()
124
125
->color ('gray ' )
125
126
->visible (fn () => count (FilamentFlexibleContentBlockPages::config ()->getMenuStyles ()) > 1 ),
126
-
127
- TextColumn::make ('max_depth ' )
128
- ->label (flexiblePagesTrans ('menus.table.max_depth_col ' ))
129
- ->formatStateUsing (function (?int $ state ): string {
130
- return $ state ? (string ) $ state : flexiblePagesTrans ('menus.table.default_depth ' );
131
- })
132
- ->sortable (),
133
-
134
- TextColumn::make ('menuItems_count ' )
135
- ->label (flexiblePagesTrans ('menus.table.items_count_col ' ))
136
- ->counts ('menuItems ' )
137
- ->sortable (),
138
-
139
- TextColumn::make ('created_at ' )
140
- ->label (flexiblePagesTrans ('menus.table.created_at_col ' ))
141
- ->dateTime ()
142
- ->sortable ()
143
- ->toggleable (isToggledHiddenByDefault: true ),
144
127
])
145
128
->filters ([
146
129
//
@@ -149,7 +132,7 @@ public static function table(Table $table): Table
149
132
Action::make ('manage_items ' )
150
133
->label (flexiblePagesTrans ('menus.actions.manage_items ' ))
151
134
->icon ('heroicon-o-bars-3 ' )
152
- ->color ('primary ' )
135
+ ->color ('secondary ' )
153
136
->url (fn ($ record ) => static ::getUrl ('items ' , ['record ' => $ record ])),
154
137
EditAction::make (),
155
138
])
0 commit comments