File tree Expand file tree Collapse file tree
components/SiteContentEditor Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -882,11 +882,11 @@ const SiteContentEditor = () => {
882882 } = useContent ( )
883883
884884 const sectionOptions = useMemo ( ( ) => {
885- const base = [ ... CONTENT_SECTIONS ]
886- const extraKeys = content
887- ? Object . keys ( content ) . filter ( ( key ) => ! base . includes ( key ) )
888- : [ ]
889- return [ ... base , ... extraKeys . sort ( ) ]
885+ const keys = Object . keys ( content || { } )
886+ const defaultKeys = Object . keys ( DEFAULT_CONTENT )
887+ const combined = Array . from ( new Set ( [ ... keys , ... defaultKeys ] ) )
888+ // Only show sections that have a defined label (whitelist approach)
889+ return combined . filter ( key => sectionLabels . hasOwnProperty ( key ) ) . sort ( )
890890 } , [ content ] )
891891
892892 const [ selectedSection , setSelectedSection ] = useState ( null )
Original file line number Diff line number Diff line change @@ -65,21 +65,7 @@ export const DEFAULT_CONTENT = {
6565 title : 'IT Wissensportal - Security, Programming & Admin' ,
6666 description : 'Dein Portal für IT Security, Programmierung und Administration.' ,
6767 } ,
68- tutorial_section : {
69- title : 'Neueste Beiträge' ,
70- description : 'Aktuelle Artikel und Guides aus der IT-Welt' ,
71- heading : 'Wissen vertiefen' ,
72- ctaDescription : 'Stöbere in unseren Artikeln und erweitere dein Know-how.' ,
73- ctaPrimary : {
74- label : 'Alle Beiträge' ,
75- target : { type : 'route' , value : '/blog' } ,
76- } ,
77- ctaSecondary : {
78- label : 'Mehr erfahren' ,
79- target : { type : 'section' , value : 'home' } ,
80- } ,
81- tutorialCardButton : 'Artikel lesen' ,
82- } ,
68+
8369 header : {
8470 brand : {
8571 name : 'IT Portal' ,
You can’t perform that action at this time.
0 commit comments