diff --git a/change/@microsoft-fast-html-host-bindings-409612bf-386a-4d49-8a10-e9a2cc1cfb59.json b/change/@microsoft-fast-html-host-bindings-409612bf-386a-4d49-8a10-e9a2cc1cfb59.json new file mode 100644 index 00000000000..5281bd0c319 --- /dev/null +++ b/change/@microsoft-fast-html-host-bindings-409612bf-386a-4d49-8a10-e9a2cc1cfb59.json @@ -0,0 +1,7 @@ +{ + "type": "none", + "comment": "chore(fast-html): use @microsoft/fast-build to build host-bindings fixture", + "packageName": "@microsoft/fast-html", + "email": "7559015+janechu@users.noreply.github.com", + "dependentChangeType": "none" +} diff --git a/packages/fast-html/scripts/build-fixtures.js b/packages/fast-html/scripts/build-fixtures.js index 1b7ee628d16..5b2b4008dfe 100644 --- a/packages/fast-html/scripts/build-fixtures.js +++ b/packages/fast-html/scripts/build-fixtures.js @@ -7,7 +7,7 @@ import { fileURLToPath } from "node:url"; // Builds test fixtures using @microsoft/fast-build. Add fixture names here // incrementally as each one is verified to work with the fast-build CLI. -const fixtures = ["attribute", "binding", "event", "ref", "slotted", "when", "repeat", "repeat-event", "children"]; +const fixtures = ["attribute", "binding", "event", "ref", "slotted", "when", "repeat", "repeat-event", "children", "host-bindings"]; const __dirname = dirname(fileURLToPath(import.meta.url)); const require = createRequire(import.meta.url); diff --git a/packages/fast-html/test/fixtures/host-bindings/entry.html b/packages/fast-html/test/fixtures/host-bindings/entry.html new file mode 100644 index 00000000000..6547931ca8e --- /dev/null +++ b/packages/fast-html/test/fixtures/host-bindings/entry.html @@ -0,0 +1,40 @@ + + + + + Host Bindings Test + + + + + + + + + + + + + + + + + diff --git a/packages/fast-html/test/fixtures/host-bindings/index.html b/packages/fast-html/test/fixtures/host-bindings/index.html index aabac6e9545..2f9c9c66e32 100644 --- a/packages/fast-html/test/fixtures/host-bindings/index.html +++ b/packages/fast-html/test/fixtures/host-bindings/index.html @@ -1,7 +1,7 @@ - + Host Bindings Test - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/packages/fast-html/test/fixtures/host-bindings/main.ts b/packages/fast-html/test/fixtures/host-bindings/main.ts index 8640b862364..97fea5ab272 100644 --- a/packages/fast-html/test/fixtures/host-bindings/main.ts +++ b/packages/fast-html/test/fixtures/host-bindings/main.ts @@ -1,5 +1,5 @@ -import { RenderableFASTElement, TemplateElement } from "@microsoft/fast-html"; import { attr, FASTElement, observable } from "@microsoft/fast-element"; +import { RenderableFASTElement, TemplateElement } from "@microsoft/fast-html"; // Test 1: Element with single host event binding and content attribute binding class HostEventElement extends FASTElement { diff --git a/packages/fast-html/test/fixtures/host-bindings/state.json b/packages/fast-html/test/fixtures/host-bindings/state.json new file mode 100644 index 00000000000..0370aa3d1f6 --- /dev/null +++ b/packages/fast-html/test/fixtures/host-bindings/state.json @@ -0,0 +1,9 @@ +{ + "greeting": "Hello", + "text": "World", + "isDisabled": true, + "first": "first", + "second": "second", + "hostTitle": "tooltip", + "hostAttr": "value" +} diff --git a/packages/fast-html/test/fixtures/host-bindings/templates.html b/packages/fast-html/test/fixtures/host-bindings/templates.html new file mode 100644 index 00000000000..b30366baa25 --- /dev/null +++ b/packages/fast-html/test/fixtures/host-bindings/templates.html @@ -0,0 +1,55 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +