Skip to content

Commit 68f9339

Browse files
committed
deprecate old gridset nonsense
1 parent 4a8ea6c commit 68f9339

1 file changed

Lines changed: 0 additions & 45 deletions

File tree

src/processors/gridsetProcessor.ts

Lines changed: 0 additions & 45 deletions
Original file line numberDiff line numberDiff line change
@@ -2809,51 +2809,6 @@ class GridsetProcessor extends BaseProcessor {
28092809
}
28102810
}
28112811

2812-
// Process WordList items attached to the page (from personalisation)
2813-
// These are tracked separately and shouldn't create new cells
2814-
// Use a known symbol key to check for WordList items
2815-
const WORDLIST_ITEMS_KEY = 'wordListItems';
2816-
const wordListItems = (page as any)[WORDLIST_ITEMS_KEY] as
2817-
| Array<{ label: string; message: string }>
2818-
| undefined;
2819-
2820-
if (wordListItems && wordListItems.length > 0) {
2821-
// Ensure WordList structure exists
2822-
if (!originalGrid.Grid) {
2823-
originalGrid.Grid = {};
2824-
}
2825-
if (!originalGrid.Grid.WordList) {
2826-
originalGrid.Grid.WordList = {};
2827-
}
2828-
if (!originalGrid.Grid.WordList.Items) {
2829-
originalGrid.Grid.WordList.Items = {};
2830-
}
2831-
2832-
const existingItems =
2833-
originalGrid.Grid.WordList.Items.WordListItem ||
2834-
originalGrid.Grid.WordList.Items.wordlistitem ||
2835-
[];
2836-
const itemsArray = Array.isArray(existingItems) ? existingItems : [existingItems];
2837-
2838-
// Add new WordList items with proper Grid 3 format
2839-
for (const item of wordListItems) {
2840-
itemsArray.push({
2841-
Text: {
2842-
p: {
2843-
s: {
2844-
r: item.label,
2845-
},
2846-
},
2847-
},
2848-
Image: '',
2849-
PartOfSpeech: 'Unknown',
2850-
});
2851-
}
2852-
2853-
// Update the WordList
2854-
originalGrid.Grid.WordList.Items.WordListItem = itemsArray;
2855-
}
2856-
28572812
// Build the updated grid XML and format for Grid 3 compatibility
28582813
let builtXml = gridBuilder.build(originalGrid);
28592814
builtXml = formatGrid3XmlComplete(builtXml);

0 commit comments

Comments
 (0)