+
+
+
+
+
+
+
+
+
+
+ {{ item.label }}
+
+
+
+
+
+ {{ item.label }}
+
+
+
+
+
+
+
+
+
+ {{ item.label }}
+
+
+
+
+
+ {{ item.label }}
+
+
+
+
+
diff --git a/tests/header.test.ts b/tests/header.test.ts
index 91a474c..421fa2b 100644
--- a/tests/header.test.ts
+++ b/tests/header.test.ts
@@ -1,9 +1,10 @@
import { afterEach, describe, expect, it, vi } from "vitest";
import { mount } from "@vue/test-utils";
import { defineComponent, nextTick, ref } from "vue";
-import { Header, HeaderRoot } from "../packages/vue/src";
+import { Header, HeaderRoot, ListBoxSection } from "../packages/vue/src";
import HeaderBasicDemo from "../apps/docs/demos/header-basic.vue";
+import HeaderCollectionGroupingDemo from "../apps/docs/demos/header-collection-grouping.vue";
import HeaderCustomClassDemo from "../apps/docs/demos/header-custom-class.vue";
import HeaderSemanticDemo from "../apps/docs/demos/header-semantic.vue";
@@ -122,6 +123,7 @@ describe("Header demos", () => {
});
for (const demo of [
HeaderBasicDemo,
+ HeaderCollectionGroupingDemo,
HeaderCustomClassDemo,
HeaderSemanticDemo,
]) {
@@ -136,6 +138,52 @@ describe("Header demos", () => {
});
});
+describe("Header collection grouping", () => {
+ it("registers its id as the MenuSection group label", async () => {
+ const { MenuSection } = await import("../packages/vue/src");
+ const w = mount(
+ defineComponent({
+ components: { MenuSection, Header },
+ template: `
+