chore(client): fix a type error in tests

This commit is contained in:
Elian Doran 2025-05-28 21:36:00 +03:00
parent c597ad7694
commit 7af44f609d
No known key found for this signature in database

View File

@ -6,7 +6,7 @@ type ToolbarConfig = string | "|" | { items: ToolbarConfig[] };
describe("CKEditor config", () => {
it("has same toolbar items for fixed and floating", () => {
function traverseItems(config: ToolbarConfig): string[] {
const result = [];
const result: (string | string[])[] = [];
if (typeof config === "object") {
for (const item of config.items) {
result.push(traverseItems(item));