@oods/component-contracts 0.4.1 → 0.4.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -29,4 +29,4 @@ Use matching versions of the OODS packages. These packages are separate from the
29
29
 
30
30
  ## License
31
31
 
32
- Apache License 2.0. See [LICENSE](https://cdn.jsdelivr.net/npm/@oods/component-contracts@0.4.1/LICENSE) and [NOTICE](https://cdn.jsdelivr.net/npm/@oods/component-contracts@0.4.1/NOTICE). Generated output belongs to its user; installed package dependencies retain their own licenses.
32
+ Apache License 2.0. See [LICENSE](https://cdn.jsdelivr.net/npm/@oods/component-contracts@0.4.3/LICENSE) and [NOTICE](https://cdn.jsdelivr.net/npm/@oods/component-contracts@0.4.3/NOTICE). Generated output belongs to its user; installed package dependencies retain their own licenses.
package/dist/index.cjs CHANGED
@@ -15867,13 +15867,13 @@ var authoredContracts = {
15867
15867
  ArchiveSummary: {
15868
15868
  id: "ArchiveSummary",
15869
15869
  version: COMPONENT_CONTRACT_VERSION,
15870
- props: ["title", "label", "heading", "name", "isArchived", "archived", "status", "archivedAt", "reason", "archiveReason", "summary", "text", "description"],
15870
+ props: ["title", "label", "heading", "name", "isArchived", "archived", "status", "archivedAt", "reason", "archiveReason", "summary", "text", "description", "hideWhenDefault"],
15871
15871
  slots: ["default"],
15872
15872
  events: [],
15873
15873
  states: ["populated", "fallback", "empty"],
15874
15874
  tokenRoles: ["summary.background", "summary.border", "summary.text", "summary.label"],
15875
15875
  accessibility: ["false renders No in its named term", "archive date and reason remain associated terms"],
15876
- compatibility: "Mirrors renderArchiveSummary: h3 heading and Archived (isArchived/archived/status), Archived At (archivedAt), Reason (reason/archiveReason) description-list terms. A nullable archivedAt omits its date term; boolean summary terms render No and Yes; an absent flag remains absent. summary/text/description fallback and authored body override preserve the heading. archivedField, archivedAtField and reasonField lower to their runtime keys. restoredAtField, archivedByField, metadataField, retainHistoryParameter, restoreWindowParameter and allowPartialRestoreParameter are consumed unbound: HTML has no restore, actor or archive metadata term or action. Noninteractive."
15876
+ compatibility: 'Mirrors renderArchiveSummary: h3 heading and Archived (isArchived/archived/status), Archived At (archivedAt), Reason (reason/archiveReason) description-list terms. A nullable archivedAt omits its date term; boolean summary terms render No and Yes; an absent flag remains absent. summary/text/description fallback and authored body override preserve the heading. archivedField, archivedAtField and reasonField lower to their runtime keys. restoredAtField, archivedByField, metadataField, retainHistoryParameter, restoreWindowParameter and allowPartialRestoreParameter are consumed unbound: HTML has no restore, actor or archive metadata term or action. With hideWhenDefault the card renders nothing while it would only state the default: a false flag with no archive date, reason or authored content (s224-m01: a detail page does not state "Archived: No" as content); an archived record, or one with a date or reason, keeps its card. Noninteractive.'
15877
15877
  },
15878
15878
  ArchivedRowOverlay: {
15879
15879
  id: "ArchivedRowOverlay",
@@ -16023,14 +16023,14 @@ var authoredContracts = {
16023
16023
  CancellationSummary: {
16024
16024
  id: "CancellationSummary",
16025
16025
  version: COMPONENT_CONTRACT_VERSION,
16026
- props: ["title", "label", "cancelAtPeriodEnd", "requestedAt", "reason", "code"],
16026
+ props: ["title", "label", "cancelAtPeriodEnd", "requestedAt", "reason", "code", "hideWhenDefault"],
16027
16027
  directives: ["field", "cancelAtPeriodEndField", "requestedAtField", "reasonField", "codeField"],
16028
16028
  slots: ["default"],
16029
16029
  events: [],
16030
16030
  states: ["scheduled", "not-scheduled"],
16031
16031
  tokenRoles: ["summary.background", "summary.border", "summary.text", "summary.label"],
16032
16032
  accessibility: ["Summary terms and values preserve description-list relationships"],
16033
- compatibility: "Boolean cancellation state renders a declared label, never a raw boolean literal."
16033
+ compatibility: 'Boolean cancellation state renders a declared label, never a raw boolean literal. With hideWhenDefault the card renders nothing while it would only state the default: cancelAtPeriodEnd false with no request time, reason, code or authored content (s224-m01: a detail page does not state "Cancel at period end: No" as content); a scheduled or recorded cancellation keeps its card.'
16034
16034
  },
16035
16035
  Card: {
16036
16036
  id: "Card",
@@ -16931,7 +16931,7 @@ var authoredScenarios = [
16931
16931
  { id: "address-summary-badge-role", oodsComponentId: "AddressSummaryBadge", props: { label: "Billing address", role: "billing" }, slots: {}, initialState: { status: "billing" }, renderExpectation: { name: "render", trigger: "mount", expected: "visible Billing address label with data-badge-status billing and the address variant" }, assertions: ["label is visible text", "data-badge-status is billing", "data-badge-variant is address", "badge is noninteractive"] },
16932
16932
  { id: "address-validation-timeline-events", oodsComponentId: "AddressValidationTimeline", props: { title: "Address checks", validations: [{ label: "Postal code verified", timestamp: "2026-09-05T12:00:00Z", detail: "Matched carrier database" }, "Geocoded"] }, slots: {}, initialState: { events: 2 }, renderExpectation: { name: "render", trigger: "mount", expected: "a log region titled Address checks with two ordered events, the first timestamped and detailed" }, assertions: ["region has role log and an h2 title", "events are ordered list items", "the timestamp is a time element", "scalar entries render as text"] },
16933
16933
  { id: "archive-pill-false", oodsComponentId: "ArchivePill", props: { "isArchived": false }, slots: {}, initialState: { content: "populated" }, renderExpectation: { name: "render", trigger: "mount", expected: "Not archived remains visible; machine status remains false; archive is the badge variant; with hideWhenFalse a false flag renders nothing and a true flag reads Archived" }, assertions: ["Not archived remains visible; machine status remains false", "archive is the badge variant", "hideWhenFalse hides only the default"] },
16934
- { id: "archive-summary-false-and-reason", oodsComponentId: "ArchiveSummary", props: { "isArchived": false, "archivedAt": "2026-09-05T12:00:00Z", "reason": "Retention policy" }, slots: {}, initialState: { content: "populated" }, renderExpectation: { name: "render", trigger: "mount", expected: "No remains visible in its named term; archive date and reason remain associated terms" }, assertions: ["No remains visible in its named term", "archive date and reason remain associated terms"] },
16934
+ { id: "archive-summary-false-and-reason", oodsComponentId: "ArchiveSummary", props: { "isArchived": false, "archivedAt": "2026-09-05T12:00:00Z", "reason": "Retention policy" }, slots: {}, initialState: { content: "populated" }, renderExpectation: { name: "render", trigger: "mount", expected: "No remains visible in its named term; archive date and reason remain associated terms; with hideWhenDefault this record keeps its card, and a false flag with no date or reason renders nothing" }, assertions: ["No remains visible in its named term", "archive date and reason remain associated terms", "hideWhenDefault hides only the default"] },
16935
16935
  { id: "archived-row-presentation", oodsComponentId: "ArchivedRowOverlay", props: { "isArchived": true, "showBadge": true, "separateTab": true, "tabLabel": "Archived", "label": "Team subscription" }, slots: {}, initialState: {}, renderExpectation: { name: "render", trigger: "mount", expected: "Archived row stays accessible and its badge and tab label agree" }, assertions: ["Archived row stays accessible and its badge and tab label agree"] },
16936
16936
  { id: "audit-event-type-and-timestamp", oodsComponentId: "AuditEvent", props: { event: "user.updated", timestamp: "2026-09-05T12:00:00Z", detail: "Display name changed" }, slots: {}, initialState: { timestamped: true }, renderExpectation: { name: "render", trigger: "mount", expected: "one audit article with a machine-readable time, the event label and the detail" }, assertions: ["article carries data-event-type audit", "time element has a datetime", "label and detail are visible text"] },
16937
16937
  {
@@ -16958,8 +16958,8 @@ var authoredScenarios = [
16958
16958
  props: { cancelAtPeriodEnd: true, requestedAt: "2026-09-05T12:00:00Z", reason: "Customer request" },
16959
16959
  slots: {},
16960
16960
  initialState: { cancelAtPeriodEnd: true },
16961
- renderExpectation: { name: "render", trigger: "mount", expected: "scheduled cancellation label is visible" },
16962
- assertions: ["boolean state is not rendered as literal true", "terms name their values"]
16961
+ renderExpectation: { name: "render", trigger: "mount", expected: "scheduled cancellation label is visible; with hideWhenDefault a scheduled or recorded cancellation keeps its card, and a false flag with nothing recorded renders nothing" },
16962
+ assertions: ["boolean state is not rendered as literal true", "terms name their values", "hideWhenDefault hides only the default"]
16963
16963
  },
16964
16964
  { id: "card-elevated-content", oodsComponentId: "Card", props: { elevated: true }, slots: { default: "Account summary" }, initialState: { elevated: true }, renderExpectation: { name: "render", trigger: "mount", expected: "semantic container with visible content" }, assertions: ["content is not empty", "elevated state is exposed"] },
16965
16965
  { id: "card-header-supporting-text", oodsComponentId: "CardHeader", props: { title: "Account summary", supportingText: "Current subscription" }, slots: {}, initialState: { heading: "h2" }, renderExpectation: { name: "render", trigger: "mount", expected: "h2 heading and visible supporting text" }, assertions: ["title is a real h2 heading", "supporting text is visible"] },
package/dist/index.js CHANGED
@@ -15865,13 +15865,13 @@ var authoredContracts = {
15865
15865
  ArchiveSummary: {
15866
15866
  id: "ArchiveSummary",
15867
15867
  version: COMPONENT_CONTRACT_VERSION,
15868
- props: ["title", "label", "heading", "name", "isArchived", "archived", "status", "archivedAt", "reason", "archiveReason", "summary", "text", "description"],
15868
+ props: ["title", "label", "heading", "name", "isArchived", "archived", "status", "archivedAt", "reason", "archiveReason", "summary", "text", "description", "hideWhenDefault"],
15869
15869
  slots: ["default"],
15870
15870
  events: [],
15871
15871
  states: ["populated", "fallback", "empty"],
15872
15872
  tokenRoles: ["summary.background", "summary.border", "summary.text", "summary.label"],
15873
15873
  accessibility: ["false renders No in its named term", "archive date and reason remain associated terms"],
15874
- compatibility: "Mirrors renderArchiveSummary: h3 heading and Archived (isArchived/archived/status), Archived At (archivedAt), Reason (reason/archiveReason) description-list terms. A nullable archivedAt omits its date term; boolean summary terms render No and Yes; an absent flag remains absent. summary/text/description fallback and authored body override preserve the heading. archivedField, archivedAtField and reasonField lower to their runtime keys. restoredAtField, archivedByField, metadataField, retainHistoryParameter, restoreWindowParameter and allowPartialRestoreParameter are consumed unbound: HTML has no restore, actor or archive metadata term or action. Noninteractive."
15874
+ compatibility: 'Mirrors renderArchiveSummary: h3 heading and Archived (isArchived/archived/status), Archived At (archivedAt), Reason (reason/archiveReason) description-list terms. A nullable archivedAt omits its date term; boolean summary terms render No and Yes; an absent flag remains absent. summary/text/description fallback and authored body override preserve the heading. archivedField, archivedAtField and reasonField lower to their runtime keys. restoredAtField, archivedByField, metadataField, retainHistoryParameter, restoreWindowParameter and allowPartialRestoreParameter are consumed unbound: HTML has no restore, actor or archive metadata term or action. With hideWhenDefault the card renders nothing while it would only state the default: a false flag with no archive date, reason or authored content (s224-m01: a detail page does not state "Archived: No" as content); an archived record, or one with a date or reason, keeps its card. Noninteractive.'
15875
15875
  },
15876
15876
  ArchivedRowOverlay: {
15877
15877
  id: "ArchivedRowOverlay",
@@ -16021,14 +16021,14 @@ var authoredContracts = {
16021
16021
  CancellationSummary: {
16022
16022
  id: "CancellationSummary",
16023
16023
  version: COMPONENT_CONTRACT_VERSION,
16024
- props: ["title", "label", "cancelAtPeriodEnd", "requestedAt", "reason", "code"],
16024
+ props: ["title", "label", "cancelAtPeriodEnd", "requestedAt", "reason", "code", "hideWhenDefault"],
16025
16025
  directives: ["field", "cancelAtPeriodEndField", "requestedAtField", "reasonField", "codeField"],
16026
16026
  slots: ["default"],
16027
16027
  events: [],
16028
16028
  states: ["scheduled", "not-scheduled"],
16029
16029
  tokenRoles: ["summary.background", "summary.border", "summary.text", "summary.label"],
16030
16030
  accessibility: ["Summary terms and values preserve description-list relationships"],
16031
- compatibility: "Boolean cancellation state renders a declared label, never a raw boolean literal."
16031
+ compatibility: 'Boolean cancellation state renders a declared label, never a raw boolean literal. With hideWhenDefault the card renders nothing while it would only state the default: cancelAtPeriodEnd false with no request time, reason, code or authored content (s224-m01: a detail page does not state "Cancel at period end: No" as content); a scheduled or recorded cancellation keeps its card.'
16032
16032
  },
16033
16033
  Card: {
16034
16034
  id: "Card",
@@ -16929,7 +16929,7 @@ var authoredScenarios = [
16929
16929
  { id: "address-summary-badge-role", oodsComponentId: "AddressSummaryBadge", props: { label: "Billing address", role: "billing" }, slots: {}, initialState: { status: "billing" }, renderExpectation: { name: "render", trigger: "mount", expected: "visible Billing address label with data-badge-status billing and the address variant" }, assertions: ["label is visible text", "data-badge-status is billing", "data-badge-variant is address", "badge is noninteractive"] },
16930
16930
  { id: "address-validation-timeline-events", oodsComponentId: "AddressValidationTimeline", props: { title: "Address checks", validations: [{ label: "Postal code verified", timestamp: "2026-09-05T12:00:00Z", detail: "Matched carrier database" }, "Geocoded"] }, slots: {}, initialState: { events: 2 }, renderExpectation: { name: "render", trigger: "mount", expected: "a log region titled Address checks with two ordered events, the first timestamped and detailed" }, assertions: ["region has role log and an h2 title", "events are ordered list items", "the timestamp is a time element", "scalar entries render as text"] },
16931
16931
  { id: "archive-pill-false", oodsComponentId: "ArchivePill", props: { "isArchived": false }, slots: {}, initialState: { content: "populated" }, renderExpectation: { name: "render", trigger: "mount", expected: "Not archived remains visible; machine status remains false; archive is the badge variant; with hideWhenFalse a false flag renders nothing and a true flag reads Archived" }, assertions: ["Not archived remains visible; machine status remains false", "archive is the badge variant", "hideWhenFalse hides only the default"] },
16932
- { id: "archive-summary-false-and-reason", oodsComponentId: "ArchiveSummary", props: { "isArchived": false, "archivedAt": "2026-09-05T12:00:00Z", "reason": "Retention policy" }, slots: {}, initialState: { content: "populated" }, renderExpectation: { name: "render", trigger: "mount", expected: "No remains visible in its named term; archive date and reason remain associated terms" }, assertions: ["No remains visible in its named term", "archive date and reason remain associated terms"] },
16932
+ { id: "archive-summary-false-and-reason", oodsComponentId: "ArchiveSummary", props: { "isArchived": false, "archivedAt": "2026-09-05T12:00:00Z", "reason": "Retention policy" }, slots: {}, initialState: { content: "populated" }, renderExpectation: { name: "render", trigger: "mount", expected: "No remains visible in its named term; archive date and reason remain associated terms; with hideWhenDefault this record keeps its card, and a false flag with no date or reason renders nothing" }, assertions: ["No remains visible in its named term", "archive date and reason remain associated terms", "hideWhenDefault hides only the default"] },
16933
16933
  { id: "archived-row-presentation", oodsComponentId: "ArchivedRowOverlay", props: { "isArchived": true, "showBadge": true, "separateTab": true, "tabLabel": "Archived", "label": "Team subscription" }, slots: {}, initialState: {}, renderExpectation: { name: "render", trigger: "mount", expected: "Archived row stays accessible and its badge and tab label agree" }, assertions: ["Archived row stays accessible and its badge and tab label agree"] },
16934
16934
  { id: "audit-event-type-and-timestamp", oodsComponentId: "AuditEvent", props: { event: "user.updated", timestamp: "2026-09-05T12:00:00Z", detail: "Display name changed" }, slots: {}, initialState: { timestamped: true }, renderExpectation: { name: "render", trigger: "mount", expected: "one audit article with a machine-readable time, the event label and the detail" }, assertions: ["article carries data-event-type audit", "time element has a datetime", "label and detail are visible text"] },
16935
16935
  {
@@ -16956,8 +16956,8 @@ var authoredScenarios = [
16956
16956
  props: { cancelAtPeriodEnd: true, requestedAt: "2026-09-05T12:00:00Z", reason: "Customer request" },
16957
16957
  slots: {},
16958
16958
  initialState: { cancelAtPeriodEnd: true },
16959
- renderExpectation: { name: "render", trigger: "mount", expected: "scheduled cancellation label is visible" },
16960
- assertions: ["boolean state is not rendered as literal true", "terms name their values"]
16959
+ renderExpectation: { name: "render", trigger: "mount", expected: "scheduled cancellation label is visible; with hideWhenDefault a scheduled or recorded cancellation keeps its card, and a false flag with nothing recorded renders nothing" },
16960
+ assertions: ["boolean state is not rendered as literal true", "terms name their values", "hideWhenDefault hides only the default"]
16961
16961
  },
16962
16962
  { id: "card-elevated-content", oodsComponentId: "Card", props: { elevated: true }, slots: { default: "Account summary" }, initialState: { elevated: true }, renderExpectation: { name: "render", trigger: "mount", expected: "semantic container with visible content" }, assertions: ["content is not empty", "elevated state is exposed"] },
16963
16963
  { id: "card-header-supporting-text", oodsComponentId: "CardHeader", props: { title: "Account summary", supportingText: "Current subscription" }, slots: {}, initialState: { heading: "h2" }, renderExpectation: { name: "render", trigger: "mount", expected: "h2 heading and visible supporting text" }, assertions: ["title is a real h2 heading", "supporting text is visible"] },
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@oods/component-contracts",
3
- "version": "0.4.1",
3
+ "version": "0.4.3",
4
4
  "description": "Component contracts for OODS Foundry: each component's identity, props, events, states, token roles and accessibility obligations, with shared formatting helpers.",
5
5
  "homepage": "https://oods-foundry.com/",
6
6
  "bugs": {