@carbon/ibm-products-web-components 0.44.0 → 0.45.0

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.
Files changed (74) hide show
  1. package/custom-elements.json +67 -11
  2. package/es/components/about-modal/about-modal.scss.js +1 -1
  3. package/es/components/tearsheet-preview/tearsheet-header-content.d.ts +27 -1
  4. package/es/components/tearsheet-preview/tearsheet-header-content.d.ts.map +1 -1
  5. package/es/components/tearsheet-preview/tearsheet-header-content.js +137 -4
  6. package/es/components/tearsheet-preview/tearsheet-header-content.js.map +1 -1
  7. package/es/components/tearsheet-preview/tearsheet-header-content.scss.js +1 -1
  8. package/es/components/tearsheet-preview/tearsheet-header-content.scss.js.map +1 -1
  9. package/es/components/tearsheet-preview/tearsheet-header.d.ts +12 -16
  10. package/es/components/tearsheet-preview/tearsheet-header.d.ts.map +1 -1
  11. package/es/components/tearsheet-preview/tearsheet-header.js +29 -70
  12. package/es/components/tearsheet-preview/tearsheet-header.js.map +1 -1
  13. package/es/components/tearsheet-preview/tearsheet-header.scss.js +1 -1
  14. package/es/components/tearsheet-preview/tearsheet-header.scss.js.map +1 -1
  15. package/es/components/tearsheet-preview/tearsheet-influencer.js +1 -1
  16. package/es/components/tearsheet-preview/tearsheet-influencer.js.map +1 -1
  17. package/es/components/tearsheet-preview/tearsheet-navigation-bar.scss.js +1 -1
  18. package/es/components/tearsheet-preview/tearsheet-signal.d.ts +6 -0
  19. package/es/components/tearsheet-preview/tearsheet-signal.d.ts.map +1 -1
  20. package/es/components/tearsheet-preview/tearsheet-signal.js +4 -1
  21. package/es/components/tearsheet-preview/tearsheet-signal.js.map +1 -1
  22. package/es/components/tearsheet-preview/tearsheet-summary-content.d.ts.map +1 -1
  23. package/es/components/tearsheet-preview/tearsheet-summary-content.js +4 -1
  24. package/es/components/tearsheet-preview/tearsheet-summary-content.js.map +1 -1
  25. package/es/components/tearsheet-preview/tearsheet.d.ts +19 -0
  26. package/es/components/tearsheet-preview/tearsheet.d.ts.map +1 -1
  27. package/es/components/tearsheet-preview/tearsheet.js +38 -3
  28. package/es/components/tearsheet-preview/tearsheet.js.map +1 -1
  29. package/es/components/tearsheet-preview/tearsheet.scss.js +1 -1
  30. package/es/components/tearsheet-preview/tearsheet.scss.js.map +1 -1
  31. package/es/ibm-products-web-components/package.js +1 -1
  32. package/es/utilities/manageFocusTrap/manageFocusTrap.d.ts +12 -5
  33. package/es/utilities/manageFocusTrap/manageFocusTrap.d.ts.map +1 -1
  34. package/es/utilities/manageFocusTrap/manageFocusTrap.js +23 -10
  35. package/es/utilities/manageFocusTrap/manageFocusTrap.js.map +1 -1
  36. package/es-custom/components/about-modal/about-modal.scss.js +1 -1
  37. package/es-custom/components/tearsheet-preview/tearsheet-header-content.js +137 -4
  38. package/es-custom/components/tearsheet-preview/tearsheet-header-content.js.map +1 -1
  39. package/es-custom/components/tearsheet-preview/tearsheet-header-content.scss.js +1 -1
  40. package/es-custom/components/tearsheet-preview/tearsheet-header-content.scss.js.map +1 -1
  41. package/es-custom/components/tearsheet-preview/tearsheet-header.js +29 -70
  42. package/es-custom/components/tearsheet-preview/tearsheet-header.js.map +1 -1
  43. package/es-custom/components/tearsheet-preview/tearsheet-header.scss.js +1 -1
  44. package/es-custom/components/tearsheet-preview/tearsheet-header.scss.js.map +1 -1
  45. package/es-custom/components/tearsheet-preview/tearsheet-influencer.js +1 -1
  46. package/es-custom/components/tearsheet-preview/tearsheet-influencer.js.map +1 -1
  47. package/es-custom/components/tearsheet-preview/tearsheet-navigation-bar.scss.js +1 -1
  48. package/es-custom/components/tearsheet-preview/tearsheet-signal.js +4 -1
  49. package/es-custom/components/tearsheet-preview/tearsheet-signal.js.map +1 -1
  50. package/es-custom/components/tearsheet-preview/tearsheet-summary-content.js +4 -1
  51. package/es-custom/components/tearsheet-preview/tearsheet-summary-content.js.map +1 -1
  52. package/es-custom/components/tearsheet-preview/tearsheet.js +38 -3
  53. package/es-custom/components/tearsheet-preview/tearsheet.js.map +1 -1
  54. package/es-custom/components/tearsheet-preview/tearsheet.scss.js +1 -1
  55. package/es-custom/components/tearsheet-preview/tearsheet.scss.js.map +1 -1
  56. package/es-custom/ibm-products-web-components/package.js +1 -1
  57. package/es-custom/utilities/manageFocusTrap/manageFocusTrap.js +23 -10
  58. package/es-custom/utilities/manageFocusTrap/manageFocusTrap.js.map +1 -1
  59. package/lib/components/tearsheet-preview/tearsheet-header-content.d.ts +27 -1
  60. package/lib/components/tearsheet-preview/tearsheet-header-content.d.ts.map +1 -1
  61. package/lib/components/tearsheet-preview/tearsheet-header.d.ts +12 -16
  62. package/lib/components/tearsheet-preview/tearsheet-header.d.ts.map +1 -1
  63. package/lib/components/tearsheet-preview/tearsheet-signal.d.ts +6 -0
  64. package/lib/components/tearsheet-preview/tearsheet-signal.d.ts.map +1 -1
  65. package/lib/components/tearsheet-preview/tearsheet-summary-content.d.ts.map +1 -1
  66. package/lib/components/tearsheet-preview/tearsheet.d.ts +19 -0
  67. package/lib/components/tearsheet-preview/tearsheet.d.ts.map +1 -1
  68. package/lib/utilities/manageFocusTrap/manageFocusTrap.d.ts +12 -5
  69. package/lib/utilities/manageFocusTrap/manageFocusTrap.d.ts.map +1 -1
  70. package/package.json +4 -4
  71. package/scss/components/tearsheet-preview/tearsheet-header-content.scss +57 -11
  72. package/scss/components/tearsheet-preview/tearsheet-header.scss +4 -3
  73. package/scss/components/tearsheet-preview/tearsheet.scss +16 -0
  74. package/telemetry.yml +2 -1
@@ -8,6 +8,7 @@
8
8
  */
9
9
  import { LitElement, PropertyValues } from 'lit';
10
10
  import '@carbon/web-components/es/components/modal/index.js';
11
+ import '@carbon/web-components/es/components/icon-button/index.js';
11
12
  import '../truncated-text';
12
13
  declare const CDSTearsheetHeaderContent_base: {
13
14
  new (...args: any[]): {
@@ -22,7 +23,7 @@ declare const CDSTearsheetHeaderContent_base: {
22
23
  };
23
24
  };
24
25
  };
25
- } & typeof LitElement;
26
+ } & typeof LitElement & (new (...args: any[]) => import("@lit-labs/signals").SignalWatcherApi);
26
27
  /**
27
28
  * Tearsheet Header Content component - Contains the title, description, and decorative elements.
28
29
  *
@@ -49,16 +50,41 @@ declare class CDSTearsheetHeaderContent extends CDSTearsheetHeaderContent_base {
49
50
  get titleId(): string;
50
51
  private _titleStartSlot?;
51
52
  private _titleEndSlot?;
53
+ private _decoratorSlot?;
52
54
  private _hasTitleStart;
53
55
  private _hasTitleEnd;
56
+ private _hasDecorator;
57
+ private _hasAILabel;
54
58
  private _isMobileOrNarrow;
55
59
  private mdMediaQuery;
56
60
  private isMobileDevice;
57
61
  private get isNarrowVariant();
62
+ /**
63
+ * Returns the first focusable element in the header for the focus trap.
64
+
65
+ * Priority by screen size:
66
+ * Large (desktop): header-actions button → close button → AI label
67
+ * Small (mobile): AI label → close button → header-actions button
68
+ */
69
+ getFirstFocusable(): HTMLElement | null;
58
70
  protected firstUpdated(_changedProperties: PropertyValues): void;
59
71
  protected updated(_changedProperties: PropertyValues): void;
72
+ /**
73
+ * Applies `inert` to collapsed header regions so they are removed from
74
+ * the tab order and AT tree. CSS alone (opacity:0 / max-block-size:0)
75
+ * does not prevent keyboard focus on hidden elements.
76
+ *
77
+ * Collapsed regions:
78
+ * - Everything in header-content except the title wrapper
79
+ * (description, label, extra slot content, "Read more" button)
80
+ * - Header-actions on small/narrow screens
81
+ */
82
+ private _updateInertState;
60
83
  private _checkSlots;
61
84
  private _handleSlotChange;
85
+ private _handleDecoratorChange;
86
+ private _updateDecoratorSize;
87
+ private _updateHeaderOffset;
62
88
  render(): import("lit-html").TemplateResult<1>;
63
89
  static styles: any;
64
90
  }
@@ -1 +1 @@
1
- {"version":3,"file":"tearsheet-header-content.d.ts","sourceRoot":"","sources":["../../../src/components/tearsheet-preview/tearsheet-header-content.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH,OAAO,EAAQ,UAAU,EAAE,cAAc,EAAE,MAAM,KAAK,CAAC;AAIvD,OAAO,qDAAqD,CAAC;AAE7D,OAAO,mBAAmB,CAAC;;;;;;;;;;uBACkB,CAAC;;;;;AAQ9C;;;;;;;;;GASG;AACH,cACM,yBAA0B,SAAQ,8BAA6B;IAEnE,IAAI,SAAoB;IAExB;;OAEG;IAEH,KAAK,EAAE,MAAM,CAAM;IAEnB;;OAEG;IACH,OAAO,CAAC,QAAQ,CAA6E;IAE7F;;OAEG;IACH,IAAI,OAAO,IAAI,MAAM,CAEpB;IAGD,OAAO,CAAC,eAAe,CAAC,CAAkB;IAG1C,OAAO,CAAC,aAAa,CAAC,CAAkB;IAGxC,OAAO,CAAC,cAAc,CAAS;IAG/B,OAAO,CAAC,YAAY,CAAS;IAG7B,OAAO,CAAC,iBAAiB,CAAS;IAElC,OAAO,CAAC,YAAY,CAA0C;IAC9D,OAAO,CAAC,cAAc,CAIpB;IAEF,OAAO,KAAK,eAAe,GAG1B;IAED,SAAS,CAAC,YAAY,CAAC,kBAAkB,EAAE,cAAc,GAAG,IAAI;IAYhE,SAAS,CAAC,OAAO,CAAC,kBAAkB,EAAE,cAAc,GAAG,IAAI;IAU3D,OAAO,CAAC,WAAW;IAWnB,OAAO,CAAC,iBAAiB;IAIzB,MAAM;IA0EN,MAAM,CAAC,MAAM,MAAU;CACxB;AACD,eAAe,yBAAyB,CAAC"}
1
+ {"version":3,"file":"tearsheet-header-content.d.ts","sourceRoot":"","sources":["../../../src/components/tearsheet-preview/tearsheet-header-content.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH,OAAO,EAAQ,UAAU,EAAE,cAAc,EAAE,MAAM,KAAK,CAAC;AAIvD,OAAO,qDAAqD,CAAC;AAC7D,OAAO,2DAA2D,CAAC;AAEnE,OAAO,mBAAmB,CAAC;;;;;;;;;;uBAAtB,CAAC;;;;;AAaN;;;;;;;;;GASG;AACH,cACM,yBAA0B,SAAQ,8BAEvC;IAEC,IAAI,SAAoB;IAExB;;OAEG;IAEH,KAAK,EAAE,MAAM,CAAM;IAEnB;;OAEG;IACH,OAAO,CAAC,QAAQ,CAA6E;IAE7F;;OAEG;IACH,IAAI,OAAO,IAAI,MAAM,CAEpB;IAGD,OAAO,CAAC,eAAe,CAAC,CAAkB;IAG1C,OAAO,CAAC,aAAa,CAAC,CAAkB;IAGxC,OAAO,CAAC,cAAc,CAAC,CAAkB;IAGzC,OAAO,CAAC,cAAc,CAAS;IAG/B,OAAO,CAAC,YAAY,CAAS;IAG7B,OAAO,CAAC,aAAa,CAAS;IAG9B,OAAO,CAAC,WAAW,CAAS;IAG5B,OAAO,CAAC,iBAAiB,CAAS;IAElC,OAAO,CAAC,YAAY,CAA0C;IAC9D,OAAO,CAAC,cAAc,CAIpB;IAEF,OAAO,KAAK,eAAe,GAG1B;IAED;;;;;;OAMG;IACH,iBAAiB,IAAI,WAAW,GAAG,IAAI;IAqCvC,SAAS,CAAC,YAAY,CAAC,kBAAkB,EAAE,cAAc,GAAG,IAAI;IAehE,SAAS,CAAC,OAAO,CAAC,kBAAkB,EAAE,cAAc,GAAG,IAAI;IAc3D;;;;;;;;;OASG;IACH,OAAO,CAAC,iBAAiB;IA2BzB,OAAO,CAAC,WAAW;IAWnB,OAAO,CAAC,iBAAiB;IAIzB,OAAO,CAAC,sBAAsB;IAoC9B,OAAO,CAAC,oBAAoB;IAQ5B,OAAO,CAAC,mBAAmB;IAiB3B,MAAM;IAoIN,MAAM,CAAC,MAAM,MAAU;CACxB;AACD,eAAe,yBAAyB,CAAC"}
@@ -16,8 +16,12 @@ import { LitElement, html } from "lit";
16
16
  import { property, query, state } from "lit/decorators.js";
17
17
  import HostListenerMixin from "@carbon/web-components/es/globals/mixins/host-listener.js";
18
18
  import { carbonElement } from "@carbon/web-components/es/globals/decorators/carbon-element.js";
19
+ import { iconLoader } from "@carbon/web-components/es/globals/internal/icon-loader.js";
20
+ import "@carbon/web-components/es/components/icon-button/index.js";
19
21
  import "@carbon/web-components/es/components/modal/index.js";
20
22
  import { breakpoints } from "@carbon/layout";
23
+ import { SignalWatcher } from "@lit-labs/signals";
24
+ import Close20 from "@carbon/icons/es/close/20.js";
21
25
  //#region src/components/tearsheet-preview/tearsheet-header-content.ts
22
26
  /**
23
27
  * @license
@@ -38,7 +42,7 @@ const blockClass = `c4p--tearsheet__next`;
38
42
  * @slot description - Custom description content below the title
39
43
  * @slot decorator - AI label or other decorative elements
40
44
  */
41
- let CDSTearsheetHeaderContent = class CDSTearsheetHeaderContent extends HostListenerMixin(LitElement) {
45
+ let CDSTearsheetHeaderContent = class CDSTearsheetHeaderContent extends SignalWatcher(HostListenerMixin(LitElement)) {
42
46
  constructor(..._args) {
43
47
  super(..._args);
44
48
  this.slot = "header-content";
@@ -46,6 +50,8 @@ let CDSTearsheetHeaderContent = class CDSTearsheetHeaderContent extends HostList
46
50
  this._titleId = `${blockClass}__title-${Math.random().toString(36).substr(2, 9)}`;
47
51
  this._hasTitleStart = false;
48
52
  this._hasTitleEnd = false;
53
+ this._hasDecorator = false;
54
+ this._hasAILabel = false;
49
55
  this._isMobileOrNarrow = false;
50
56
  this.mdMediaQuery = `(max-width: ${breakpoints.md.width})`;
51
57
  this.isMobileDevice = new MatchMediaController(this, this.mdMediaQuery, false);
@@ -59,16 +65,59 @@ let CDSTearsheetHeaderContent = class CDSTearsheetHeaderContent extends HostList
59
65
  get isNarrowVariant() {
60
66
  return this.closest(`c4p-preview-tearsheet`)?.getAttribute("variant") === "narrow";
61
67
  }
68
+ /**
69
+ * Returns the first focusable element in the header for the focus trap.
70
+
71
+ * Priority by screen size:
72
+ * Large (desktop): header-actions button → close button → AI label
73
+ * Small (mobile): AI label → close button → header-actions button
74
+ */
75
+ getFirstFocusable() {
76
+ const headerActionSlot = this.querySelector("[slot=\"header-actions\"]");
77
+ const headerActionBtn = headerActionSlot ? headerActionSlot.matches(`cds-button:not([disabled]), button:not([disabled])`) ? headerActionSlot : headerActionSlot.querySelector(`cds-button:not([disabled]), button:not([disabled])`) : null;
78
+ const closeBtn = this.shadowRoot?.querySelector(`.${blockClass}__close-button cds-icon-button:not([disabled])`);
79
+ const decoratorSlot = this.querySelector("[slot=\"decorator\"]");
80
+ const aiLabel = decoratorSlot ? decoratorSlot.matches(`cds-ai-label`) ? decoratorSlot : decoratorSlot.querySelector(`cds-ai-label`) : null;
81
+ return this._isMobileOrNarrow ? aiLabel ?? closeBtn ?? headerActionBtn ?? null : headerActionBtn ?? closeBtn ?? aiLabel ?? null;
82
+ }
62
83
  firstUpdated(_changedProperties) {
63
84
  this._checkSlots();
64
85
  this._isMobileOrNarrow = this.isMobileDevice?.matches || this.isNarrowVariant;
65
86
  const uniqueId = tearsheetSignal.get().uniqueId;
66
- if (uniqueId) registerFocusableContainers(this.shadowRoot, uniqueId);
87
+ if (uniqueId) {
88
+ registerFocusableContainers(this, uniqueId);
89
+ registerFocusableContainers(this.shadowRoot, uniqueId);
90
+ }
67
91
  }
68
92
  updated(_changedProperties) {
69
93
  const previousIsMobileOrNarrow = this._isMobileOrNarrow;
70
94
  this._isMobileOrNarrow = this.isMobileDevice?.matches || this.isNarrowVariant;
71
95
  if (this._isMobileOrNarrow !== previousIsMobileOrNarrow) this.requestUpdate();
96
+ this._updateDecoratorSize();
97
+ this._updateHeaderOffset();
98
+ this._updateInertState();
99
+ }
100
+ /**
101
+ * Applies `inert` to collapsed header regions so they are removed from
102
+ * the tab order and AT tree. CSS alone (opacity:0 / max-block-size:0)
103
+ * does not prevent keyboard focus on hidden elements.
104
+ *
105
+ * Collapsed regions:
106
+ * - Everything in header-content except the title wrapper
107
+ * (description, label, extra slot content, "Read more" button)
108
+ * - Header-actions on small/narrow screens
109
+ */
110
+ _updateInertState() {
111
+ const { fullyCollapsed } = tearsheetSignal.get();
112
+ const headerContent = this.shadowRoot?.querySelector(`.${blockClass}__header-content`);
113
+ if (headerContent) headerContent.querySelectorAll(`:scope > *:not(.${blockClass}__content__title-wrapper)`).forEach((el) => {
114
+ el.toggleAttribute("inert", fullyCollapsed);
115
+ });
116
+ const headerActions = this.shadowRoot?.querySelector(`.${blockClass}__header-actions`);
117
+ if (headerActions) {
118
+ const shouldInert = fullyCollapsed && this._isMobileOrNarrow;
119
+ headerActions.toggleAttribute("inert", shouldInert);
120
+ }
72
121
  }
73
122
  _checkSlots() {
74
123
  if (this._titleStartSlot) {
@@ -83,7 +132,84 @@ let CDSTearsheetHeaderContent = class CDSTearsheetHeaderContent extends HostList
83
132
  _handleSlotChange() {
84
133
  this._checkSlots();
85
134
  }
135
+ _handleDecoratorChange(e) {
136
+ this._hasAILabel = false;
137
+ const childItems = e.target.assignedElements();
138
+ this._hasDecorator = childItems.length > 0;
139
+ if (this._hasDecorator) {
140
+ for (const item of childItems) if (item.tagName.toLowerCase() === `cds-ai-label`) {
141
+ this._hasAILabel = true;
142
+ break;
143
+ }
144
+ const { fullyCollapsed } = tearsheetSignal.get();
145
+ childItems[0].setAttribute("size", fullyCollapsed ? "xs" : "sm");
146
+ const host = this.closest(`c4p-tearsheet-header`);
147
+ if (host) {
148
+ host.setAttribute(this._hasAILabel ? "ai-label" : "decorator", "");
149
+ host.removeAttribute(this._hasAILabel ? "decorator" : "ai-label");
150
+ }
151
+ } else {
152
+ const host = this.closest(`c4p-tearsheet-header`);
153
+ if (host) {
154
+ host.removeAttribute("decorator");
155
+ host.removeAttribute("ai-label");
156
+ }
157
+ }
158
+ this._updateHeaderOffset();
159
+ }
160
+ _updateDecoratorSize() {
161
+ const { fullyCollapsed } = tearsheetSignal.get();
162
+ const assigned = this._decoratorSlot?.assignedElements({ flatten: true });
163
+ if (assigned?.length) assigned[0].setAttribute("size", fullyCollapsed ? "xs" : "sm");
164
+ }
165
+ _updateHeaderOffset() {
166
+ const { open, isSm } = tearsheetSignal.get();
167
+ if (!open) return;
168
+ const offset = (this.querySelector("[slot=\"decorator\"]")?.clientWidth ?? 0) + 24 + (isSm ? 8 : 0);
169
+ document.documentElement.style.setProperty("--tearsheet-header-action-offset", `${offset}px`);
170
+ }
86
171
  render() {
172
+ const { fullyCollapsed, hideCloseButton, closeIconDescription, onClose } = tearsheetSignal.get();
173
+ const decoratorTemplate = html`
174
+ <div
175
+ class="${blockClass}__decorator"
176
+ role="${this._hasDecorator ? "complementary" : void 0}"
177
+ aria-label="${this._hasDecorator ? "Decorator" : void 0}"
178
+ >
179
+ <slot
180
+ name="decorator"
181
+ @slotchange=${this._handleDecoratorChange}
182
+ ></slot>
183
+ </div>
184
+ `;
185
+ const closeButtonTemplate = !hideCloseButton ? html`
186
+ <div
187
+ class="${blockClass}__close-button ${"cds"}--modal-close-button"
188
+ >
189
+ <cds-icon-button
190
+ class="${"cds"}--modal-close"
191
+ kind="ghost"
192
+ size="${fullyCollapsed ? "md" : "lg"}"
193
+ align="left"
194
+ aria-label="${closeIconDescription || "Close"}"
195
+ @click="${() => {
196
+ onClose?.();
197
+ this.dispatchEvent(new CustomEvent(`c4p-tearsheet-header-close-button-clicked`, {
198
+ bubbles: true,
199
+ composed: true
200
+ }));
201
+ }}"
202
+ >
203
+ ${iconLoader(Close20, {
204
+ slot: "icon",
205
+ class: `cds--modal-close__icon`
206
+ })}
207
+ <span slot="tooltip-content"
208
+ >${closeIconDescription || "Close"}</span
209
+ >
210
+ </cds-icon-button>
211
+ </div>
212
+ ` : html``;
87
213
  const headerActionsTemplate = html`
88
214
  <div class="${blockClass}__header-actions">
89
215
  <slot name="header-actions"></slot>
@@ -111,11 +237,13 @@ let CDSTearsheetHeaderContent = class CDSTearsheetHeaderContent extends HostList
111
237
  @slotchange="${this._handleSlotChange}"
112
238
  ></slot>`}
113
239
 
114
- <!-- Title (main text) -->
240
+ <!-- Title (main text) — limit to 1 line when collapsed so it fits
241
+ in the reduced-height collapsed bar -->
115
242
  <c4p-truncated-text
116
243
  class="${blockClass}__content__title"
117
244
  id="${blockClass}__header-title__truncatedText"
118
245
  value="${this.title}"
246
+ lines="${tearsheetSignal.get().fullyCollapsed ? 1 : 2}"
119
247
  ></c4p-truncated-text>
120
248
 
121
249
  <!-- Title End -->
@@ -144,7 +272,9 @@ let CDSTearsheetHeaderContent = class CDSTearsheetHeaderContent extends HostList
144
272
  </div>
145
273
  </div>
146
274
  `;
147
- return this._isMobileOrNarrow ? html`${headerContentTemplate} ${headerActionsTemplate}` : html`${headerActionsTemplate} ${headerContentTemplate}`;
275
+ return this._isMobileOrNarrow ? html`${decoratorTemplate} ${closeButtonTemplate}
276
+ ${headerContentTemplate} ${headerActionsTemplate}` : html`${headerActionsTemplate} ${decoratorTemplate}
277
+ ${closeButtonTemplate} ${headerContentTemplate}`;
148
278
  }
149
279
  static {
150
280
  this.styles = tearsheet_header_content_default$1;
@@ -154,8 +284,11 @@ __decorate([property({ reflect: true })], CDSTearsheetHeaderContent.prototype, "
154
284
  __decorate([property({ reflect: true })], CDSTearsheetHeaderContent.prototype, "title", void 0);
155
285
  __decorate([query("slot[name=\"title-start\"]")], CDSTearsheetHeaderContent.prototype, "_titleStartSlot", void 0);
156
286
  __decorate([query("slot[name=\"title-end\"]")], CDSTearsheetHeaderContent.prototype, "_titleEndSlot", void 0);
287
+ __decorate([query("slot[name=\"decorator\"]")], CDSTearsheetHeaderContent.prototype, "_decoratorSlot", void 0);
157
288
  __decorate([state()], CDSTearsheetHeaderContent.prototype, "_hasTitleStart", void 0);
158
289
  __decorate([state()], CDSTearsheetHeaderContent.prototype, "_hasTitleEnd", void 0);
290
+ __decorate([state()], CDSTearsheetHeaderContent.prototype, "_hasDecorator", void 0);
291
+ __decorate([state()], CDSTearsheetHeaderContent.prototype, "_hasAILabel", void 0);
159
292
  __decorate([state()], CDSTearsheetHeaderContent.prototype, "_isMobileOrNarrow", void 0);
160
293
  CDSTearsheetHeaderContent = __decorate([carbonElement(`c4p-tearsheet-header-content`)], CDSTearsheetHeaderContent);
161
294
  var tearsheet_header_content_default = CDSTearsheetHeaderContent;
@@ -1 +1 @@
1
- {"version":3,"file":"tearsheet-header-content.js","names":["styles","customElement"],"sources":["../../../src/components/tearsheet-preview/tearsheet-header-content.ts"],"sourcesContent":["/**\n * @license\n *\n * Copyright IBM Corp. 2026\n *\n * This source code is licensed under the Apache-2.0 license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nimport { html, LitElement, PropertyValues } from 'lit';\nimport { property, query, state } from 'lit/decorators.js';\nimport { prefix } from '../../globals/settings';\nimport HostListenerMixin from '@carbon/web-components/es/globals/mixins/host-listener.js';\nimport '@carbon/web-components/es/components/modal/index.js';\nimport { carbonElement as customElement } from '@carbon/web-components/es/globals/decorators/carbon-element.js';\nimport '../truncated-text';\nimport styles from './tearsheet-header-content.scss?lit';\nimport { MatchMediaController } from '../../globals/js/utils/match-media-controller';\nimport { breakpoints } from '@carbon/layout';\nimport { registerFocusableContainers } from '../../utilities/manageFocusTrap/manageFocusTrap';\nimport { tearsheetSignal } from './tearsheet-signal';\n\nconst blockClass = `${prefix}--tearsheet__next`;\n\n/**\n * Tearsheet Header Content component - Contains the title, description, and decorative elements.\n *\n * @element c4p-tearsheet-header-content\n * @slot label - Optional label text above the title\n * @slot title-start - Content before the title (e.g., icons)\n * @slot title-end - Content after the title (e.g., badges, tags)\n * @slot description - Custom description content below the title\n * @slot decorator - AI label or other decorative elements\n */\n@customElement(`${prefix}-tearsheet-header-content`)\nclass CDSTearsheetHeaderContent extends HostListenerMixin(LitElement) {\n @property({ reflect: true })\n slot = 'header-content';\n\n /**\n * The main title of the tearsheet.\n */\n @property({ reflect: true })\n title: string = '';\n\n /**\n * Internal ID for the title element (auto-generated, used for aria-labelledby on the modal)\n */\n private _titleId: string = `${blockClass}__title-${Math.random().toString(36).substr(2, 9)}`;\n\n /**\n * Public getter for the title ID (used by parent tearsheet for aria-labelledby)\n */\n get titleId(): string {\n return this._titleId;\n }\n\n @query('slot[name=\"title-start\"]')\n private _titleStartSlot?: HTMLSlotElement;\n\n @query('slot[name=\"title-end\"]')\n private _titleEndSlot?: HTMLSlotElement;\n\n @state()\n private _hasTitleStart = false;\n\n @state()\n private _hasTitleEnd = false;\n\n @state()\n private _isMobileOrNarrow = false;\n\n private mdMediaQuery = `(max-width: ${breakpoints.md.width})`;\n private isMobileDevice = new MatchMediaController(\n this,\n this.mdMediaQuery,\n false\n );\n\n private get isNarrowVariant(): boolean {\n const tearsheet = this.closest(`${prefix}-preview-tearsheet`);\n return tearsheet?.getAttribute('variant') === 'narrow';\n }\n\n protected firstUpdated(_changedProperties: PropertyValues): void {\n this._checkSlots();\n this._isMobileOrNarrow =\n this.isMobileDevice?.matches || this.isNarrowVariant;\n\n // Register with the current tearsheet's uniqueId\n const uniqueId = tearsheetSignal.get().uniqueId;\n if (uniqueId) {\n registerFocusableContainers(this.shadowRoot, uniqueId);\n }\n }\n\n protected updated(_changedProperties: PropertyValues): void {\n const previousIsMobileOrNarrow = this._isMobileOrNarrow;\n this._isMobileOrNarrow =\n this.isMobileDevice?.matches || this.isNarrowVariant;\n\n if (this._isMobileOrNarrow !== previousIsMobileOrNarrow) {\n this.requestUpdate();\n }\n }\n\n private _checkSlots() {\n if (this._titleStartSlot) {\n const assignedNodes = this._titleStartSlot.assignedElements();\n this._hasTitleStart = assignedNodes.length > 0;\n }\n if (this._titleEndSlot) {\n const assignedNodes = this._titleEndSlot.assignedElements();\n this._hasTitleEnd = assignedNodes.length > 0;\n }\n }\n\n private _handleSlotChange() {\n this._checkSlots();\n }\n\n render() {\n const headerActionsTemplate = html`\n <div class=\"${blockClass}__header-actions\">\n <slot name=\"header-actions\"></slot>\n </div>\n `;\n\n const headerContentTemplate = html`\n <div class=\"${blockClass}__header-content\">\n <!-- Label -->\n <div class=\"${blockClass}__header-label\">\n <slot name=\"label\"></slot>\n </div>\n\n <div class=\"${blockClass}__content__title-wrapper\">\n <h2 class=\"${blockClass}__header-title\" id=\"${this._titleId}\">\n <!-- Title Start -->\n ${this._hasTitleStart\n ? html`\n <span class=\"${blockClass}__title-start\">\n <slot\n name=\"title-start\"\n @slotchange=\"${this._handleSlotChange}\"\n ></slot>\n </span>\n `\n : html`<slot\n name=\"title-start\"\n @slotchange=\"${this._handleSlotChange}\"\n ></slot>`}\n\n <!-- Title (main text) -->\n <c4p-truncated-text\n class=\"${blockClass}__content__title\"\n id=\"${blockClass}__header-title__truncatedText\"\n value=\"${this.title}\"\n ></c4p-truncated-text>\n\n <!-- Title End -->\n ${this._hasTitleEnd\n ? html`\n <span class=\"${blockClass}__title-end\">\n <slot\n name=\"title-end\"\n @slotchange=\"${this._handleSlotChange}\"\n ></slot>\n </span>\n `\n : html`<slot\n name=\"title-end\"\n @slotchange=\"${this._handleSlotChange}\"\n ></slot>`}\n </h2>\n </div>\n\n <!-- Description -->\n <div class=\"${blockClass}__header-description\">\n <slot name=\"description\"></slot>\n </div>\n\n <!-- Extra children -->\n <div class=\"${blockClass}__header-content--extra\">\n <slot></slot>\n </div>\n </div>\n `;\n\n // Desktop/Wide: header-actions first (for accessibility), CSS order handles visual layout\n // Mobile/Narrow: header-content first (natural DOM order)\n return this._isMobileOrNarrow\n ? html`${headerContentTemplate} ${headerActionsTemplate}`\n : html`${headerActionsTemplate} ${headerContentTemplate}`;\n }\n\n static styles = styles;\n}\nexport default CDSTearsheetHeaderContent;\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAsBA,MAAM,aAAa;;;;;;;;;;;AAYnB,IAAA,4BAAA,MACM,kCAAkC,kBAAkB,WAAW,CAAC;;;cAE7D;eAMS;kBAKW,GAAG,WAAW,UAAU,KAAK,QAAQ,CAAC,SAAS,GAAG,CAAC,OAAO,GAAG,EAAE;wBAgBjE;sBAGF;2BAGK;sBAEL,eAAe,YAAY,GAAG,MAAM;wBAClC,IAAI,qBAC3B,MACA,KAAK,cACL,MACD;;;;;CAxBD,IAAI,UAAkB;AACpB,SAAO,KAAK;;CAyBd,IAAY,kBAA2B;AAErC,SADkB,KAAK,QAAQ,wBACf,EAAE,aAAa,UAAU,KAAK;;CAGhD,aAAuB,oBAA0C;AAC/D,OAAK,aAAa;AAClB,OAAK,oBACH,KAAK,gBAAgB,WAAW,KAAK;EAGvC,MAAM,WAAW,gBAAgB,KAAK,CAAC;AACvC,MAAI,SACF,6BAA4B,KAAK,YAAY,SAAS;;CAI1D,QAAkB,oBAA0C;EAC1D,MAAM,2BAA2B,KAAK;AACtC,OAAK,oBACH,KAAK,gBAAgB,WAAW,KAAK;AAEvC,MAAI,KAAK,sBAAsB,yBAC7B,MAAK,eAAe;;CAIxB,cAAsB;AACpB,MAAI,KAAK,iBAAiB;GACxB,MAAM,gBAAgB,KAAK,gBAAgB,kBAAkB;AAC7D,QAAK,iBAAiB,cAAc,SAAS;;AAE/C,MAAI,KAAK,eAAe;GACtB,MAAM,gBAAgB,KAAK,cAAc,kBAAkB;AAC3D,QAAK,eAAe,cAAc,SAAS;;;CAI/C,oBAA4B;AAC1B,OAAK,aAAa;;CAGpB,SAAS;EACP,MAAM,wBAAwB,IAAI;oBAClB,WAAW;;;;EAK3B,MAAM,wBAAwB,IAAI;oBAClB,WAAW;;sBAET,WAAW;;;;sBAIX,WAAW;uBACV,WAAW,sBAAsB,KAAK,SAAS;;cAExD,KAAK,iBACH,IAAI;iCACa,WAAW;;;qCAGP,KAAK,kBAAkB;;;oBAI5C,IAAI;;iCAEa,KAAK,kBAAkB;0BAC9B;;;;uBAIH,WAAW;oBACd,WAAW;uBACR,KAAK,MAAM;;;;cAIpB,KAAK,eACH,IAAI;iCACa,WAAW;;;qCAGP,KAAK,kBAAkB;;;oBAI5C,IAAI;;iCAEa,KAAK,kBAAkB;0BAC9B;;;;;sBAKJ,WAAW;;;;;sBAKX,WAAW;;;;;AAQ7B,SAAO,KAAK,oBACR,IAAI,GAAG,sBAAsB,GAAG,0BAChC,IAAI,GAAG,sBAAsB,GAAG;;;gBAGtBA;;;YA/Jf,SAAS,EAAE,SAAS,MAAM,CAAC,CAAA,EAAA,0BAAA,WAAA,QAAA,KAAA,EAAA;YAM3B,SAAS,EAAE,SAAS,MAAM,CAAC,CAAA,EAAA,0BAAA,WAAA,SAAA,KAAA,EAAA;YAe3B,MAAM,6BAA2B,CAAA,EAAA,0BAAA,WAAA,mBAAA,KAAA,EAAA;YAGjC,MAAM,2BAAyB,CAAA,EAAA,0BAAA,WAAA,iBAAA,KAAA,EAAA;YAG/B,OAAO,CAAA,EAAA,0BAAA,WAAA,kBAAA,KAAA,EAAA;YAGP,OAAO,CAAA,EAAA,0BAAA,WAAA,gBAAA,KAAA,EAAA;YAGP,OAAO,CAAA,EAAA,0BAAA,WAAA,qBAAA,KAAA,EAAA;wCAnCTC,cAAc,+BAAqC,CAAA,EAAA,0BAAA;AAmKpD,IAAA,mCAAe"}
1
+ {"version":3,"file":"tearsheet-header-content.js","names":["styles","customElement"],"sources":["../../../src/components/tearsheet-preview/tearsheet-header-content.ts"],"sourcesContent":["/**\n * @license\n *\n * Copyright IBM Corp. 2026\n *\n * This source code is licensed under the Apache-2.0 license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nimport { html, LitElement, PropertyValues } from 'lit';\nimport { property, query, state } from 'lit/decorators.js';\nimport { prefix } from '../../globals/settings';\nimport HostListenerMixin from '@carbon/web-components/es/globals/mixins/host-listener.js';\nimport '@carbon/web-components/es/components/modal/index.js';\nimport '@carbon/web-components/es/components/icon-button/index.js';\nimport { carbonElement as customElement } from '@carbon/web-components/es/globals/decorators/carbon-element.js';\nimport '../truncated-text';\nimport styles from './tearsheet-header-content.scss?lit';\nimport { MatchMediaController } from '../../globals/js/utils/match-media-controller';\nimport { breakpoints } from '@carbon/layout';\nimport { registerFocusableContainers } from '../../utilities/manageFocusTrap/manageFocusTrap';\nimport { tearsheetSignal } from './tearsheet-signal';\nimport { SignalWatcher } from '@lit-labs/signals';\nimport Close20 from '@carbon/icons/es/close/20.js';\nimport { iconLoader } from '@carbon/web-components/es/globals/internal/icon-loader.js';\nimport { carbonPrefix } from '../../globals/settings';\n\nconst blockClass = `${prefix}--tearsheet__next`;\n\n/**\n * Tearsheet Header Content component - Contains the title, description, and decorative elements.\n *\n * @element c4p-tearsheet-header-content\n * @slot label - Optional label text above the title\n * @slot title-start - Content before the title (e.g., icons)\n * @slot title-end - Content after the title (e.g., badges, tags)\n * @slot description - Custom description content below the title\n * @slot decorator - AI label or other decorative elements\n */\n@customElement(`${prefix}-tearsheet-header-content`)\nclass CDSTearsheetHeaderContent extends SignalWatcher(\n HostListenerMixin(LitElement)\n) {\n @property({ reflect: true })\n slot = 'header-content';\n\n /**\n * The main title of the tearsheet.\n */\n @property({ reflect: true })\n title: string = '';\n\n /**\n * Internal ID for the title element (auto-generated, used for aria-labelledby on the modal)\n */\n private _titleId: string = `${blockClass}__title-${Math.random().toString(36).substr(2, 9)}`;\n\n /**\n * Public getter for the title ID (used by parent tearsheet for aria-labelledby)\n */\n get titleId(): string {\n return this._titleId;\n }\n\n @query('slot[name=\"title-start\"]')\n private _titleStartSlot?: HTMLSlotElement;\n\n @query('slot[name=\"title-end\"]')\n private _titleEndSlot?: HTMLSlotElement;\n\n @query('slot[name=\"decorator\"]')\n private _decoratorSlot?: HTMLSlotElement;\n\n @state()\n private _hasTitleStart = false;\n\n @state()\n private _hasTitleEnd = false;\n\n @state()\n private _hasDecorator = false;\n\n @state()\n private _hasAILabel = false;\n\n @state()\n private _isMobileOrNarrow = false;\n\n private mdMediaQuery = `(max-width: ${breakpoints.md.width})`;\n private isMobileDevice = new MatchMediaController(\n this,\n this.mdMediaQuery,\n false\n );\n\n private get isNarrowVariant(): boolean {\n const tearsheet = this.closest(`${prefix}-preview-tearsheet`);\n return tearsheet?.getAttribute('variant') === 'narrow';\n }\n\n /**\n * Returns the first focusable element in the header for the focus trap.\n \n * Priority by screen size:\n * Large (desktop): header-actions button → close button → AI label\n * Small (mobile): AI label → close button → header-actions button\n */\n getFirstFocusable(): HTMLElement | null {\n // header-actions: consumer may slot a button directly OR wrap buttons in a div.\n // <cds-button slot=\"header-actions\"> → slotted element IS the button\n // <div slot=\"header-actions\"><cds-button> → button is a child of the slotted div\n const headerActionSlot = this.querySelector<HTMLElement>(\n '[slot=\"header-actions\"]'\n );\n const headerActionBtn = headerActionSlot\n ? headerActionSlot.matches(\n `${carbonPrefix}-button:not([disabled]), button:not([disabled])`\n )\n ? headerActionSlot\n : headerActionSlot.querySelector<HTMLElement>(\n `${carbonPrefix}-button:not([disabled]), button:not([disabled])`\n )\n : null;\n\n // close button: inside this component's own shadow DOM\n const closeBtn = this.shadowRoot?.querySelector<HTMLElement>(\n `.${blockClass}__close-button ${carbonPrefix}-icon-button:not([disabled])`\n );\n\n // AI label: consumer may slot cds-ai-label directly OR wrap it in a div.\n // <cds-ai-label slot=\"decorator\"> → slotted element IS the ai-label\n // <div slot=\"decorator\"><cds-ai-label> → ai-label is a child of the slotted div\n const decoratorSlot = this.querySelector<HTMLElement>('[slot=\"decorator\"]');\n const aiLabel = decoratorSlot\n ? decoratorSlot.matches(`${carbonPrefix}-ai-label`)\n ? decoratorSlot\n : decoratorSlot.querySelector<HTMLElement>(`${carbonPrefix}-ai-label`)\n : null;\n\n return this._isMobileOrNarrow\n ? (aiLabel ?? closeBtn ?? headerActionBtn ?? null)\n : (headerActionBtn ?? closeBtn ?? aiLabel ?? null);\n }\n\n protected firstUpdated(_changedProperties: PropertyValues): void {\n this._checkSlots();\n this._isMobileOrNarrow =\n this.isMobileDevice?.matches || this.isNarrowVariant;\n\n // Register containers in intentional order:\n // 1. `this` (light DOM) — finds header-action buttons and AI label (slot=\"decorator\")\n // 2. `this.shadowRoot` — finds close button (cds-icon-button) and decorator slot host\n const uniqueId = tearsheetSignal.get().uniqueId;\n if (uniqueId) {\n registerFocusableContainers(this, uniqueId);\n registerFocusableContainers(this.shadowRoot, uniqueId);\n }\n }\n\n protected updated(_changedProperties: PropertyValues): void {\n const previousIsMobileOrNarrow = this._isMobileOrNarrow;\n this._isMobileOrNarrow =\n this.isMobileDevice?.matches || this.isNarrowVariant;\n\n if (this._isMobileOrNarrow !== previousIsMobileOrNarrow) {\n this.requestUpdate();\n }\n\n this._updateDecoratorSize();\n this._updateHeaderOffset();\n this._updateInertState();\n }\n\n /**\n * Applies `inert` to collapsed header regions so they are removed from\n * the tab order and AT tree. CSS alone (opacity:0 / max-block-size:0)\n * does not prevent keyboard focus on hidden elements.\n *\n * Collapsed regions:\n * - Everything in header-content except the title wrapper\n * (description, label, extra slot content, \"Read more\" button)\n * - Header-actions on small/narrow screens\n */\n private _updateInertState(): void {\n const { fullyCollapsed } = tearsheetSignal.get();\n\n // Header-content children except title wrapper\n const headerContent = this.shadowRoot?.querySelector(\n `.${blockClass}__header-content`\n );\n if (headerContent) {\n headerContent\n .querySelectorAll<HTMLElement>(\n `:scope > *:not(.${blockClass}__content__title-wrapper)`\n )\n .forEach((el) => {\n el.toggleAttribute('inert', fullyCollapsed);\n });\n }\n\n // Header-actions: inert on small/narrow when collapsed\n const headerActions = this.shadowRoot?.querySelector<HTMLElement>(\n `.${blockClass}__header-actions`\n );\n if (headerActions) {\n const shouldInert = fullyCollapsed && this._isMobileOrNarrow;\n headerActions.toggleAttribute('inert', shouldInert);\n }\n }\n\n private _checkSlots() {\n if (this._titleStartSlot) {\n const assignedNodes = this._titleStartSlot.assignedElements();\n this._hasTitleStart = assignedNodes.length > 0;\n }\n if (this._titleEndSlot) {\n const assignedNodes = this._titleEndSlot.assignedElements();\n this._hasTitleEnd = assignedNodes.length > 0;\n }\n }\n\n private _handleSlotChange() {\n this._checkSlots();\n }\n\n private _handleDecoratorChange(e: Event) {\n this._hasAILabel = false;\n const childItems = (e.target as HTMLSlotElement).assignedElements();\n this._hasDecorator = childItems.length > 0;\n if (this._hasDecorator) {\n for (const item of childItems) {\n if (item.tagName.toLowerCase() === `${carbonPrefix}-ai-label`) {\n this._hasAILabel = true;\n break;\n }\n }\n // Set decorator size based on collapse state\n const { fullyCollapsed } = tearsheetSignal.get();\n childItems[0].setAttribute('size', fullyCollapsed ? 'xs' : 'sm');\n\n // Update host attributes for CSS targeting\n const host = this.closest(\n `${prefix}-tearsheet-header`\n ) as HTMLElement | null;\n if (host) {\n host.setAttribute(this._hasAILabel ? 'ai-label' : 'decorator', '');\n host.removeAttribute(this._hasAILabel ? 'decorator' : 'ai-label');\n }\n } else {\n const host = this.closest(\n `${prefix}-tearsheet-header`\n ) as HTMLElement | null;\n if (host) {\n host.removeAttribute('decorator');\n host.removeAttribute('ai-label');\n }\n }\n // Update header offset CSS variable\n this._updateHeaderOffset();\n }\n\n private _updateDecoratorSize() {\n const { fullyCollapsed } = tearsheetSignal.get();\n const assigned = this._decoratorSlot?.assignedElements({ flatten: true });\n if (assigned?.length) {\n assigned[0].setAttribute('size', fullyCollapsed ? 'xs' : 'sm');\n }\n }\n\n private _updateHeaderOffset() {\n const { open, isSm } = tearsheetSignal.get();\n if (!open) {\n return;\n }\n // Mirror React: querySelector `.cds--ai-label` and read clientWidth.\n // clientWidth is available synchronously after render (no rAF needed).\n // React: `AILabelWidth + 24 + (isSm ? 8 : 0)`\n const AILabelWidth =\n this.querySelector('[slot=\"decorator\"]')?.clientWidth ?? 0;\n const offset = AILabelWidth + 24 + (isSm ? 8 : 0);\n document.documentElement.style.setProperty(\n '--tearsheet-header-action-offset',\n `${offset}px`\n );\n }\n\n render() {\n const { fullyCollapsed, hideCloseButton, closeIconDescription, onClose } =\n tearsheetSignal.get();\n\n const decoratorTemplate = html`\n <div\n class=\"${blockClass}__decorator\"\n role=\"${this._hasDecorator ? 'complementary' : undefined}\"\n aria-label=\"${this._hasDecorator ? 'Decorator' : undefined}\"\n >\n <slot\n name=\"decorator\"\n @slotchange=${this._handleDecoratorChange}\n ></slot>\n </div>\n `;\n\n const closeButtonTemplate = !hideCloseButton\n ? html`\n <div\n class=\"${blockClass}__close-button ${carbonPrefix}--modal-close-button\"\n >\n <cds-icon-button\n class=\"${carbonPrefix}--modal-close\"\n kind=\"ghost\"\n size=\"${fullyCollapsed ? 'md' : 'lg'}\"\n align=\"left\"\n aria-label=\"${closeIconDescription || 'Close'}\"\n @click=\"${() => {\n onClose?.();\n this.dispatchEvent(\n new CustomEvent(\n `${prefix}-tearsheet-header-close-button-clicked`,\n { bubbles: true, composed: true }\n )\n );\n }}\"\n >\n ${iconLoader(Close20, {\n slot: 'icon',\n class: `${carbonPrefix}--modal-close__icon`,\n })}\n <span slot=\"tooltip-content\"\n >${closeIconDescription || 'Close'}</span\n >\n </cds-icon-button>\n </div>\n `\n : html``;\n\n const headerActionsTemplate = html`\n <div class=\"${blockClass}__header-actions\">\n <slot name=\"header-actions\"></slot>\n </div>\n `;\n\n const headerContentTemplate = html`\n <div class=\"${blockClass}__header-content\">\n <!-- Label -->\n <div class=\"${blockClass}__header-label\">\n <slot name=\"label\"></slot>\n </div>\n\n <div class=\"${blockClass}__content__title-wrapper\">\n <h2 class=\"${blockClass}__header-title\" id=\"${this._titleId}\">\n <!-- Title Start -->\n ${this._hasTitleStart\n ? html`\n <span class=\"${blockClass}__title-start\">\n <slot\n name=\"title-start\"\n @slotchange=\"${this._handleSlotChange}\"\n ></slot>\n </span>\n `\n : html`<slot\n name=\"title-start\"\n @slotchange=\"${this._handleSlotChange}\"\n ></slot>`}\n\n <!-- Title (main text) — limit to 1 line when collapsed so it fits\n in the reduced-height collapsed bar -->\n <c4p-truncated-text\n class=\"${blockClass}__content__title\"\n id=\"${blockClass}__header-title__truncatedText\"\n value=\"${this.title}\"\n lines=\"${tearsheetSignal.get().fullyCollapsed ? 1 : 2}\"\n ></c4p-truncated-text>\n\n <!-- Title End -->\n ${this._hasTitleEnd\n ? html`\n <span class=\"${blockClass}__title-end\">\n <slot\n name=\"title-end\"\n @slotchange=\"${this._handleSlotChange}\"\n ></slot>\n </span>\n `\n : html`<slot\n name=\"title-end\"\n @slotchange=\"${this._handleSlotChange}\"\n ></slot>`}\n </h2>\n </div>\n\n <!-- Description -->\n <div class=\"${blockClass}__header-description\">\n <slot name=\"description\"></slot>\n </div>\n\n <!-- Extra children -->\n <div class=\"${blockClass}__header-content--extra\">\n <slot></slot>\n </div>\n </div>\n `;\n\n // DOM order drives tab order:\n // Desktop/Wide: header-actions → decorator → close-button → header-content\n // Mobile/Narrow: decorator → close-button → header-content → header-actions\n //\n // On mobile the decorator and close button are position:absolute (top-right corner),\n // so they are visually first. Placing them first in DOM order aligns tab order with\n // visual order: AI label → close button → content → header-actions.\n return this._isMobileOrNarrow\n ? html`${decoratorTemplate} ${closeButtonTemplate}\n ${headerContentTemplate} ${headerActionsTemplate}`\n : html`${headerActionsTemplate} ${decoratorTemplate}\n ${closeButtonTemplate} ${headerContentTemplate}`;\n }\n\n static styles = styles;\n}\nexport default CDSTearsheetHeaderContent;\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA2BA,MAAM,aAAa;;;;;;;;;;;AAYnB,IAAA,4BAAA,MACM,kCAAkC,cACtC,kBAAkB,WAAW,CAC9B,CAAC;;;cAEO;eAMS;kBAKW,GAAG,WAAW,UAAU,KAAK,QAAQ,CAAC,SAAS,GAAG,CAAC,OAAO,GAAG,EAAE;wBAmBjE;sBAGF;uBAGC;qBAGF;2BAGM;sBAEL,eAAe,YAAY,GAAG,MAAM;wBAClC,IAAI,qBAC3B,MACA,KAAK,cACL,MACD;;;;;CAjCD,IAAI,UAAkB;AACpB,SAAO,KAAK;;CAkCd,IAAY,kBAA2B;AAErC,SADkB,KAAK,QAAQ,wBACf,EAAE,aAAa,UAAU,KAAK;;;;;;;;;CAUhD,oBAAwC;EAItC,MAAM,mBAAmB,KAAK,cAC5B,4BACD;EACD,MAAM,kBAAkB,mBACpB,iBAAiB,QACf,qDACD,GACC,mBACA,iBAAiB,cACf,qDACD,GACH;EAGJ,MAAM,WAAW,KAAK,YAAY,cAChC,IAAI,WAAW,gDAChB;EAKD,MAAM,gBAAgB,KAAK,cAA2B,uBAAqB;EAC3E,MAAM,UAAU,gBACZ,cAAc,QAAQ,eAA2B,GAC/C,gBACA,cAAc,cAA2B,eAA2B,GACtE;AAEJ,SAAO,KAAK,oBACP,WAAW,YAAY,mBAAmB,OAC1C,mBAAmB,YAAY,WAAW;;CAGjD,aAAuB,oBAA0C;AAC/D,OAAK,aAAa;AAClB,OAAK,oBACH,KAAK,gBAAgB,WAAW,KAAK;EAKvC,MAAM,WAAW,gBAAgB,KAAK,CAAC;AACvC,MAAI,UAAU;AACZ,+BAA4B,MAAM,SAAS;AAC3C,+BAA4B,KAAK,YAAY,SAAS;;;CAI1D,QAAkB,oBAA0C;EAC1D,MAAM,2BAA2B,KAAK;AACtC,OAAK,oBACH,KAAK,gBAAgB,WAAW,KAAK;AAEvC,MAAI,KAAK,sBAAsB,yBAC7B,MAAK,eAAe;AAGtB,OAAK,sBAAsB;AAC3B,OAAK,qBAAqB;AAC1B,OAAK,mBAAmB;;;;;;;;;;;;CAa1B,oBAAkC;EAChC,MAAM,EAAE,mBAAmB,gBAAgB,KAAK;EAGhD,MAAM,gBAAgB,KAAK,YAAY,cACrC,IAAI,WAAW,kBAChB;AACD,MAAI,cACF,eACG,iBACC,mBAAmB,WAAW,2BAC/B,CACA,SAAS,OAAO;AACf,MAAG,gBAAgB,SAAS,eAAe;IAC3C;EAIN,MAAM,gBAAgB,KAAK,YAAY,cACrC,IAAI,WAAW,kBAChB;AACD,MAAI,eAAe;GACjB,MAAM,cAAc,kBAAkB,KAAK;AAC3C,iBAAc,gBAAgB,SAAS,YAAY;;;CAIvD,cAAsB;AACpB,MAAI,KAAK,iBAAiB;GACxB,MAAM,gBAAgB,KAAK,gBAAgB,kBAAkB;AAC7D,QAAK,iBAAiB,cAAc,SAAS;;AAE/C,MAAI,KAAK,eAAe;GACtB,MAAM,gBAAgB,KAAK,cAAc,kBAAkB;AAC3D,QAAK,eAAe,cAAc,SAAS;;;CAI/C,oBAA4B;AAC1B,OAAK,aAAa;;CAGpB,uBAA+B,GAAU;AACvC,OAAK,cAAc;EACnB,MAAM,aAAc,EAAE,OAA2B,kBAAkB;AACnE,OAAK,gBAAgB,WAAW,SAAS;AACzC,MAAI,KAAK,eAAe;AACtB,QAAK,MAAM,QAAQ,WACjB,KAAI,KAAK,QAAQ,aAAa,KAAK,gBAA4B;AAC7D,SAAK,cAAc;AACnB;;GAIJ,MAAM,EAAE,mBAAmB,gBAAgB,KAAK;AAChD,cAAW,GAAG,aAAa,QAAQ,iBAAiB,OAAO,KAAK;GAGhE,MAAM,OAAO,KAAK,QAChB,uBACD;AACD,OAAI,MAAM;AACR,SAAK,aAAa,KAAK,cAAc,aAAa,aAAa,GAAG;AAClE,SAAK,gBAAgB,KAAK,cAAc,cAAc,WAAW;;SAE9D;GACL,MAAM,OAAO,KAAK,QAChB,uBACD;AACD,OAAI,MAAM;AACR,SAAK,gBAAgB,YAAY;AACjC,SAAK,gBAAgB,WAAW;;;AAIpC,OAAK,qBAAqB;;CAG5B,uBAA+B;EAC7B,MAAM,EAAE,mBAAmB,gBAAgB,KAAK;EAChD,MAAM,WAAW,KAAK,gBAAgB,iBAAiB,EAAE,SAAS,MAAM,CAAC;AACzE,MAAI,UAAU,OACZ,UAAS,GAAG,aAAa,QAAQ,iBAAiB,OAAO,KAAK;;CAIlE,sBAA8B;EAC5B,MAAM,EAAE,MAAM,SAAS,gBAAgB,KAAK;AAC5C,MAAI,CAAC,KACH;EAOF,MAAM,UADJ,KAAK,cAAc,uBAAqB,EAAE,eAAe,KAC7B,MAAM,OAAO,IAAI;AAC/C,WAAS,gBAAgB,MAAM,YAC7B,oCACA,GAAG,OAAO,IACX;;CAGH,SAAS;EACP,MAAM,EAAE,gBAAgB,iBAAiB,sBAAsB,YAC7D,gBAAgB,KAAK;EAEvB,MAAM,oBAAoB,IAAI;;iBAEjB,WAAW;gBACZ,KAAK,gBAAgB,kBAAkB,KAAA,EAAU;sBAC3C,KAAK,gBAAgB,cAAc,KAAA,EAAU;;;;wBAI3C,KAAK,uBAAuB;;;;EAKhD,MAAM,sBAAsB,CAAC,kBACzB,IAAI;;qBAES,WAAW,iBAAA,MAA8B;;;6BAG1B;;sBAEd,iBAAiB,OAAO,KAAK;;4BAEvB,wBAAwB,QAAQ;8BAC9B;AACd,cAAW;AACX,QAAK,cACH,IAAI,YACF,6CACA;IAAE,SAAS;IAAM,UAAU;IAAM,CAClC,CACF;IACD;;gBAEA,WAAW,SAAS;GACpB,MAAM;GACN,OAAO;GACR,CAAC,CAAC;;mBAEE,wBAAwB,QAAQ;;;;YAK3C,IAAI;EAER,MAAM,wBAAwB,IAAI;oBAClB,WAAW;;;;EAK3B,MAAM,wBAAwB,IAAI;oBAClB,WAAW;;sBAET,WAAW;;;;sBAIX,WAAW;uBACV,WAAW,sBAAsB,KAAK,SAAS;;cAExD,KAAK,iBACH,IAAI;iCACa,WAAW;;;qCAGP,KAAK,kBAAkB;;;oBAI5C,IAAI;;iCAEa,KAAK,kBAAkB;0BAC9B;;;;;uBAKH,WAAW;oBACd,WAAW;uBACR,KAAK,MAAM;uBACX,gBAAgB,KAAK,CAAC,iBAAiB,IAAI,EAAE;;;;cAItD,KAAK,eACH,IAAI;iCACa,WAAW;;;qCAGP,KAAK,kBAAkB;;;oBAI5C,IAAI;;iCAEa,KAAK,kBAAkB;0BAC9B;;;;;sBAKJ,WAAW;;;;;sBAKX,WAAW;;;;;AAa7B,SAAO,KAAK,oBACR,IAAI,GAAG,kBAAkB,GAAG,oBAAoB;UAC9C,sBAAsB,GAAG,0BAC3B,IAAI,GAAG,sBAAsB,GAAG,kBAAkB;UAChD,oBAAoB,GAAG;;;gBAGfA;;;YAvXf,SAAS,EAAE,SAAS,MAAM,CAAC,CAAA,EAAA,0BAAA,WAAA,QAAA,KAAA,EAAA;YAM3B,SAAS,EAAE,SAAS,MAAM,CAAC,CAAA,EAAA,0BAAA,WAAA,SAAA,KAAA,EAAA;YAe3B,MAAM,6BAA2B,CAAA,EAAA,0BAAA,WAAA,mBAAA,KAAA,EAAA;YAGjC,MAAM,2BAAyB,CAAA,EAAA,0BAAA,WAAA,iBAAA,KAAA,EAAA;YAG/B,MAAM,2BAAyB,CAAA,EAAA,0BAAA,WAAA,kBAAA,KAAA,EAAA;YAG/B,OAAO,CAAA,EAAA,0BAAA,WAAA,kBAAA,KAAA,EAAA;YAGP,OAAO,CAAA,EAAA,0BAAA,WAAA,gBAAA,KAAA,EAAA;YAGP,OAAO,CAAA,EAAA,0BAAA,WAAA,iBAAA,KAAA,EAAA;YAGP,OAAO,CAAA,EAAA,0BAAA,WAAA,eAAA,KAAA,EAAA;YAGP,OAAO,CAAA,EAAA,0BAAA,WAAA,qBAAA,KAAA,EAAA;wCA9CTC,cAAc,+BAAqC,CAAA,EAAA,0BAAA;AA6XpD,IAAA,mCAAe"}
@@ -7,7 +7,7 @@
7
7
 
8
8
  import { css } from "lit";
9
9
  //#region src/components/tearsheet-preview/tearsheet-header-content.scss?lit
10
- var tearsheet_header_content_default = css(["@keyframes cds--hide-feedback{0%{opacity:1;visibility:inherit}to{opacity:0;visibility:hidden}}@keyframes cds--show-feedback{0%{opacity:0;visibility:hidden}to{opacity:1;visibility:inherit}}@keyframes cds--skeleton{0%{opacity:.3;transform:scaleX(0);transform-origin:left}20%{opacity:1;transform:scaleX(1);transform-origin:left}28%{transform:scaleX(1);transform-origin:right}51%{transform:scaleX(0);transform-origin:right}58%{transform:scaleX(0);transform-origin:right}82%{transform:scaleX(1);transform-origin:right}83%{transform:scaleX(1);transform-origin:left}96%{transform:scaleX(0);transform-origin:left}to{opacity:.3;transform:scaleX(0);transform-origin:left}}.cds--layout--size-xs{--cds-layout-size-height-context:var(--cds-layout-size-height-xs,1.5rem);--cds-layout-size-height:var(--cds-layout-size-height-context)}.cds--layout-constraint--size__default-xs{--cds-layout-size-height:var(--cds-layout-size-height-context,var(--cds-layout-size-height-xs,1.5rem))}.cds--layout-constraint--size__min-xs{--cds-layout-size-height-min:var(--cds-layout-size-height-xs,1.5rem)}.cds--layout-constraint--size__max-xs{--cds-layout-size-height-max:var(--cds-layout-size-height-xs,1.5rem)}.cds--layout--size-sm{--cds-layout-size-height-context:var(--cds-layout-size-height-sm,2rem);--cds-layout-size-height:var(--cds-layout-size-height-context)}.cds--layout-constraint--size__default-sm{--cds-layout-size-height:var(--cds-layout-size-height-context,var(--cds-layout-size-height-sm,2rem))}.cds--layout-constraint--size__min-sm{--cds-layout-size-height-min:var(--cds-layout-size-height-sm,2rem)}.cds--layout-constraint--size__max-sm{--cds-layout-size-height-max:var(--cds-layout-size-height-sm,2rem)}.cds--layout--size-md{--cds-layout-size-height-context:var(--cds-layout-size-height-md,2.5rem);--cds-layout-size-height:var(--cds-layout-size-height-context)}.cds--layout-constraint--size__default-md{--cds-layout-size-height:var(--cds-layout-size-height-context,var(--cds-layout-size-height-md,2.5rem))}.cds--layout-constraint--size__min-md{--cds-layout-size-height-min:var(--cds-layout-size-height-md,2.5rem)}.cds--layout-constraint--size__max-md{--cds-layout-size-height-max:var(--cds-layout-size-height-md,2.5rem)}.cds--layout--size-lg{--cds-layout-size-height-context:var(--cds-layout-size-height-lg,3rem);--cds-layout-size-height:var(--cds-layout-size-height-context)}.cds--layout-constraint--size__default-lg{--cds-layout-size-height:var(--cds-layout-size-height-context,var(--cds-layout-size-height-lg,3rem))}.cds--layout-constraint--size__min-lg{--cds-layout-size-height-min:var(--cds-layout-size-height-lg,3rem)}.cds--layout-constraint--size__max-lg{--cds-layout-size-height-max:var(--cds-layout-size-height-lg,3rem)}.cds--layout--size-xl{--cds-layout-size-height-context:var(--cds-layout-size-height-xl,4rem);--cds-layout-size-height:var(--cds-layout-size-height-context)}.cds--layout-constraint--size__default-xl{--cds-layout-size-height:var(--cds-layout-size-height-context,var(--cds-layout-size-height-xl,4rem))}.cds--layout-constraint--size__min-xl{--cds-layout-size-height-min:var(--cds-layout-size-height-xl,4rem)}.cds--layout-constraint--size__max-xl{--cds-layout-size-height-max:var(--cds-layout-size-height-xl,4rem)}.cds--layout--size-2xl{--cds-layout-size-height-context:var(--cds-layout-size-height-2xl,5rem);--cds-layout-size-height:var(--cds-layout-size-height-context)}.cds--layout-constraint--size__default-2xl{--cds-layout-size-height:var(--cds-layout-size-height-context,var(--cds-layout-size-height-2xl,5rem))}.cds--layout-constraint--size__min-2xl{--cds-layout-size-height-min:var(--cds-layout-size-height-2xl,5rem)}.cds--layout-constraint--size__max-2xl{--cds-layout-size-height-max:var(--cds-layout-size-height-2xl,5rem)}.cds--layout--density-condensed{--cds-layout-density-padding-inline-context:var(--cds-layout-density-padding-inline-condensed,0.5rem);--cds-layout-density-padding-inline:var(--cds-layout-density-padding-inline-context)}.cds--layout-constraint--density__default-condensed{--cds-layout-density-padding-inline:var(--cds-layout-density-padding-inline-context,var(--cds-layout-density-padding-inline-condensed,0.5rem))}.cds--layout-constraint--density__min-condensed{--cds-layout-density-padding-inline-min:var(--cds-layout-density-padding-inline-condensed,0.5rem)}.cds--layout-constraint--density__max-condensed{--cds-layout-density-padding-inline-max:var(--cds-layout-density-padding-inline-condensed,0.5rem)}.cds--layout--density-normal{--cds-layout-density-padding-inline-context:var(--cds-layout-density-padding-inline-normal,1rem);--cds-layout-density-padding-inline:var(--cds-layout-density-padding-inline-context)}.cds--layout-constraint--density__default-normal{--cds-layout-density-padding-inline:var(--cds-layout-density-padding-inline-context,var(--cds-layout-density-padding-inline-normal,1rem))}.cds--layout-constraint--density__min-normal{--cds-layout-density-padding-inline-min:var(--cds-layout-density-padding-inline-normal,1rem)}.cds--layout-constraint--density__max-normal{--cds-layout-density-padding-inline-max:var(--cds-layout-density-padding-inline-normal,1rem)}:root{--cds-layout-size-height-xs:1.5rem;--cds-layout-size-height-sm:2rem;--cds-layout-size-height-md:2.5rem;--cds-layout-size-height-lg:3rem;--cds-layout-size-height-xl:4rem;--cds-layout-size-height-2xl:5rem;--cds-layout-size-height-min:0px;--cds-layout-size-height-max:999999999px;--cds-layout-density-padding-inline-condensed:0.5rem;--cds-layout-density-padding-inline-normal:1rem;--cds-layout-density-padding-inline-min:0px;--cds-layout-density-padding-inline-max:999999999px}.cds--assistive-text,.cds--visually-hidden{block-size:1px;border:0;margin:-1px;overflow:hidden;padding:0;position:absolute;clip:rect(0,0,0,0);inline-size:1px;visibility:inherit;white-space:nowrap}.c4p--tearsheet__next.c4p--tearsheet__next:not(.c4p--tearsheet__next--keep-mounted){animation:c4p--tearsheet__next--presence-tearsheet__enter .24s cubic-bezier(0,0,.3,1);opacity:1}.c4p--tearsheet__next.c4p--tearsheet__next:not(.c4p--tearsheet__next--keep-mounted).c4p--tearsheet__next.c4p--tearsheet__next .c4p--tearsheet__next__container{animation:c4p--tearsheet__next--presence-tearsheet--container__enter .24s cubic-bezier(0,0,.3,1);transform:translateZ(0)}@media screen and (prefers-reduced-motion:reduce){.c4p--tearsheet__next.c4p--tearsheet__next:not(.c4p--tearsheet__next--keep-mounted).c4p--tearsheet__next.c4p--tearsheet__next .c4p--tearsheet__next__container{animation:none}}.c4p--tearsheet__next.c4p--tearsheet__next:not(.c4p--tearsheet__next--keep-mounted).c4p--tearsheet__next--stacked.is-visible .c4p--tearsheet__next__container{transform:scaleX(var(--scale-factor))}.c4p--tearsheet__next.c4p--tearsheet__next:not(.c4p--tearsheet__next--keep-mounted)[data-tearsheet-exiting]{animation:c4p--tearsheet__next--presence-tearsheet__exit .24s cubic-bezier(.4,.14,1,1) forwards}.c4p--tearsheet__next.c4p--tearsheet__next:not(.c4p--tearsheet__next--keep-mounted)[data-tearsheet-exiting].c4p--tearsheet__next.c4p--tearsheet__next .c4p--tearsheet__next__container{animation:c4p--tearsheet__next--presence-tearsheet--container__exit .24s cubic-bezier(0,0,.3,1) forwards}@media screen and (prefers-reduced-motion:reduce){.c4p--tearsheet__next.c4p--tearsheet__next:not(.c4p--tearsheet__next--keep-mounted)[data-tearsheet-exiting].c4p--tearsheet__next.c4p--tearsheet__next .c4p--tearsheet__next__container{animation:none}}.c4p--tearsheet__next.c4p--tearsheet__next--keep-mounted:not(.is-visible).c4p--tearsheet__next.c4p--tearsheet__next .c4p--tearsheet__next__container{transform:translate3d(0,min(95vh,500px),0)}@keyframes c4p--tearsheet__next--presence-tearsheet__enter{0%{opacity:0;transition:none}}@keyframes c4p--tearsheet__next--presence-tearsheet__exit{to{opacity:0}}@keyframes c4p--tearsheet__next--presence-tearsheet--container__enter{0%{transform:translate3d(0,min(95vh,500px),0);transition:none}}@keyframes c4p--tearsheet__next--presence-tearsheet--container__exit{to{transform:translate3d(0,min(95vh,500px),0)}}.c4p--tearsheet__next .c4p--tearsheet__next__container{align-self:flex-end;block-size:100%;border:1px solid var(--cds-border-subtle-01,#c6c6c6);inset-block-start:auto;max-block-size:calc(100% - var(--tearsheet-vertical-gap, calc(5rem + .5rem)));max-inline-size:var(--tearsheet-max-inline-size,1312px)}@media (max-width:41.98rem){.c4p--tearsheet__next:not(.c4p--tearsheet__next--stack-activated.is-visible) .c4p--tearsheet__next__container{max-block-size:none}}.c4p--tearsheet__next:not(.is-visible).c4p--tearsheet__next.c4p--tearsheet__next .c4p--tearsheet__next__container{transform:translate3d(0,min(95vh,500px),0)}.c4p--tearsheet__next.c4p--tearsheet__next.c4p--tearsheet__next--has-ai-label .c4p--tearsheet__next__container{background:linear-gradient(to top,var(--cds-layer),var(--cds-layer)) padding-box,linear-gradient(to bottom,var(--cds-ai-border-start,#78a9ff),var(--cds-ai-border-end,#d0e2ff)) border-box,linear-gradient(to top,var(--cds-layer),var(--cds-layer)) border-box;border:1px solid transparent;border-block-end:0;box-shadow:0 4px 10px 2px var(--cds-ai-drop-shadow,rgba(15,98,254,.1))}.c4p--tearsheet__next.c4p--tearsheet__next.c4p--tearsheet__next--has-ai-label .c4p--tearsheet__next__main-content{background:linear-gradient(to top,var(--cds-background,var(--cds-ai-popover-background,#fff)) 0,var(--cds-ai-aura-start,rgba(69,137,255,.1)) 0,15%,var(--cds-ai-aura-end,hsla(0,0%,100%,0)) 50%) padding-box,linear-gradient(to top,var(--cds-background,var(--cds-ai-popover-background,#fff)),var(--cds-background,var(--cds-ai-popover-background,#fff))) padding-box,linear-gradient(to bottom,var(--cds-ai-border-start,rgba(166,200,255,.64)),var(--cds-ai-border-end,#78a9ff)) border-box,linear-gradient(to top,var(--cds-background,var(--cds-ai-popover-background,#fff)),var(--cds-background,var(--cds-ai-popover-background,#fff))) border-box;box-shadow:inset 0 -80px 70px -65px var(--cds-ai-inner-shadow,rgba(69,137,255,.1));position:relative}.c4p--tearsheet__next.c4p--tearsheet__next.c4p--tearsheet__next .c4p--tearsheet__next__container{transition:transform .24s cubic-bezier(0,0,.3,1),max-block-size .24s cubic-bezier(0,0,.3,1)}@media screen and (prefers-reduced-motion:reduce){.c4p--tearsheet__next.c4p--tearsheet__next.c4p--tearsheet__next .c4p--tearsheet__next__container{transition:none}}.c4p--tearsheet__next .c4p--tearsheet__next__header{align-content:space-between;border-block-end:1px solid var(--cds-border-subtle-01,#c6c6c6);display:flex;flex-wrap:wrap;margin-block:0;max-block-size:50vh;padding-block-end:0;padding-block-start:1.5rem;padding-inline:2rem}.c4p--tearsheet__next .c4p--tearsheet__next__header>*{flex-basis:100%}.c4p--tearsheet__next .c4p--tearsheet__next__header>:not(.c4p--tearsheet__next__navigation-bar,.c4p--tearsheet__next__header-content-wrapper,.cds--modal-close-button,.c4p--tearsheet__next__close-button){margin-block-end:1.5rem}@media (max-width:41.98rem){.c4p--tearsheet__next .c4p--tearsheet__next__header{padding-inline:1rem}}.c4p--tearsheet__next .cds--modal-container--sm .cds--modal-header{padding-inline-end:2rem}.c4p--tearsheet__next .c4p--tearsheet__next__header-content-wrapper{display:grid;flex-basis:unset;gap:1rem;grid-template-columns:minmax(auto,40rem) minmax(var(--tearsheet-header-title-grid-width,0),1fr);inline-size:calc(100% - var(--tearsheet-header-action-offset))}@media (max-width:41.98rem){.c4p--tearsheet__next .c4p--tearsheet__next__header-content-wrapper{display:flex;flex-direction:column}}@media (min-width:42rem){.c4p--tearsheet__next:not(.c4p--tearsheet__next--narrow) .c4p--tearsheet__next__header-content-wrapper .c4p--tearsheet__next__header-actions{order:2}.c4p--tearsheet__next:not(.c4p--tearsheet__next--narrow) .c4p--tearsheet__next__header-content-wrapper .c4p--tearsheet__next__header-content{order:1}}.c4p--tearsheet__next .c4p--tearsheet__next__header>:not(.c4p--tearsheet__next__navigation-bar,.c4p--tearsheet__next__header-content-wrapper,.cds--modal-close-button,.c4p--tearsheet__next__close-button,.c4p--tearsheet__next__decorator,.excludeFromCollapse){max-block-size:50vh;opacity:1;overflow:hidden;transition:max-block-size .24s cubic-bezier(0,0,.3,1),opacity .24s cubic-bezier(0,0,.3,1),margin .24s cubic-bezier(0,0,.3,1),padding .24s cubic-bezier(0,0,.3,1)}.c4p--tearsheet__next .c4p--tearsheet__next__header .c4p--tearsheet__next__header-actions,.c4p--tearsheet__next .c4p--tearsheet__next__header .c4p--tearsheet__next__header-content-wrapper .c4p--tearsheet__next__header-content :not(.c4p--tearsheet__next__content__title-wrapper,.c4p--tearsheet__next__header-label){opacity:1;transition:all .24s cubic-bezier(0,0,.3,1),opacity .24s cubic-bezier(0,0,.3,1)}.c4p--tearsheet__next .cds--modal-close{transition:all .24s ease}.c4p--tearsheet__next .c4p--tearsheet__next__header-collapsed{padding-block-start:0;transition:padding .24s cubic-bezier(0,0,.3,1)}.c4p--tearsheet__next .c4p--tearsheet__next__header-collapsed .c4p--tearsheet__next__header-actions>:not(.c4p--tearsheet__next__content__header-actions),.c4p--tearsheet__next .c4p--tearsheet__next__header-collapsed .c4p--tearsheet__next__header-content-wrapper .c4p--tearsheet__next__header-content>:not(.c4p--tearsheet__next__content__title-wrapper) *,.c4p--tearsheet__next .c4p--tearsheet__next__header-collapsed .c4p--tearsheet__next__header-content>:not(.c4p--tearsheet__next__content__title-wrapper),.c4p--tearsheet__next .c4p--tearsheet__next__header-collapsed>:not(.c4p--tearsheet__next__navigation-bar,.c4p--tearsheet__next__header-content-wrapper,.cds--modal-close-button,.c4p--tearsheet__next__close-button,.c4p--tearsheet__next__decorator,.excludeFromCollapse),.c4p--tearsheet__next .c4p--tearsheet__next__header-collapsed>:not(.c4p--tearsheet__next__navigation-bar,.c4p--tearsheet__next__header-content-wrapper,.cds--modal-close-button,.c4p--tearsheet__next__close-button,.c4p--tearsheet__next__decorator,.excludeFromCollapse) *{margin:0;max-block-size:0;opacity:0;overflow:hidden;padding:0;pointer-events:none;transition:all .24s cubic-bezier(0,0,.3,1);visibility:hidden}.c4p--tearsheet__next .c4p--tearsheet__next__header-collapsed .c4p--tearsheet__next__header-title{align-items:center;font-size:var(--cds-label-02-font-size,.875rem);font-weight:var(--cds-label-02-font-weight,400);gap:.5rem;letter-spacing:var(--cds-label-02-letter-spacing,.16px);line-height:var(--cds-label-02-line-height,1.28572);margin-block-start:.25rem;transition:all .24s cubic-bezier(0,0,.3,1)}.c4p--tearsheet__next .c4p--tearsheet__next__header-collapsed .c4p--tearsheet__next__header-title>span{align-items:center;block-size:1.5rem;display:flex}.c4p--tearsheet__next .c4p--tearsheet__next__header-collapsed .c4p--tearsheet__next__header-title .c4p--tearsheet__next__title-end svg,.c4p--tearsheet__next .c4p--tearsheet__next__header-collapsed .c4p--tearsheet__next__header-title .c4p--tearsheet__next__title-start svg{inline-size:1rem}.c4p--tearsheet__next .c4p--tearsheet__next__header-collapsed .c4p--tearsheet__next__header-content{align-self:center;margin-block-end:0}.c4p--tearsheet__next .c4p--tearsheet__next__header-collapsed .cds--modal-close{block-size:2.5rem;inline-size:2.5rem;transition:all .24s ease}.c4p--tearsheet__next .c4p--tearsheet__next__header-collapsed .c4p--tearsheet__next__decorator{inset-block-start:.5rem}.c4p--tearsheet__next .c4p--tearsheet__next__header-collapsed .c4p--tearsheet__next__header-title{block-size:2.5rem}.c4p--tearsheet__next .c4p--tearsheet__next__header-collapsed .c4p--tearsheet__next__content__header-actions{block-size:1.5rem;margin-block-start:.5rem;transition:all .24s ease}@media (max-width:41.98rem){.c4p--tearsheet__next .c4p--tearsheet__next__header-collapsed .c4p--tearsheet__next__header-actions{display:none}}.c4p--tearsheet__next .c4p--tearsheet__next__header-collapsed .c4p--tearsheet__next__content__title-wrapper,.c4p--tearsheet__next .c4p--tearsheet__next__header-collapsed .c4p--tearsheet__next__header-actions,.c4p--tearsheet__next .c4p--tearsheet__next__header-collapsed .c4p--tearsheet__next__header-content,.c4p--tearsheet__next .c4p--tearsheet__next__header-collapsed .c4p--tearsheet__next__header-content-wrapper,.c4p--tearsheet__next .c4p--tearsheet__next__header-collapsed .c4p--tearsheet__next__header-title{margin-block:0;transition:margin-block .24s ease}.c4p--tearsheet__next .c4p--tearsheet__next__header-collapsed .c4p--tearsheet__next__header-content-wrapper{min-block-size:2.5rem}.c4p--tearsheet__next .c4p--tearsheet__next__header-collapsed .c4p--tearsheet__next__navigation-bar:before{background:var(--cds-border-subtle-01,#c6c6c6);block-size:1px;content:\"\";inline-size:calc(100% + 5rem);inset-block-start:0;inset-inline-start:-2rem;pointer-events:none;position:absolute;z-index:1}.c4p--tearsheet__next.c4p--tearsheet__next--stack-activated.is-visible{--overlay-color:var(--cds-overlay,rgba(0,0,0,.6));--overlay-alpha:0.5;background-color:initial;z-index:calc(9000 - var(--stack-depth, 0))}.c4p--tearsheet__next.c4p--tearsheet__next--stack-activated.is-visible:before{background:var(--overlay-color);content:\"\";display:block;inset:0;opacity:calc(var(--overlay-alpha) - var(--stack-depth)*.1);position:absolute;transition:background-color .24s cubic-bezier(.4,.14,1,1),opacity .24s cubic-bezier(.4,.14,1,1)}@media (prefers-reduced-motion:reduce){.c4p--tearsheet__next.c4p--tearsheet__next--stack-activated.is-visible:before{transition:none}}.c4p--tearsheet__next.c4p--tearsheet__next--stack-activated.is-visible.is-visible .c4p--tearsheet__next__container{max-block-size:calc(100% - var(--tearsheet-vertical-gap, calc(5rem + .5rem + .125rem)) + var(--block-size-change));transform:scaleX(var(--scale-factor))}.c4p--tearsheet__next__header-label{color:var(--cds-text-secondary,#525252);font-size:var(--cds-label-01-font-size,.75rem);font-weight:var(--cds-label-01-font-weight,400);letter-spacing:var(--cds-label-01-letter-spacing,.32px);line-height:var(--cds-label-01-line-height,1.33333);margin-block-end:.25rem}.c4p--tearsheet__next__header-title{font-size:var(--cds-heading-04-font-size,1.75rem);font-weight:var(--cds-heading-04-font-weight,400);letter-spacing:var(--cds-heading-04-letter-spacing,0);line-height:var(--cds-heading-04-line-height,1.28572)}@media (max-width:41.98rem){.c4p--tearsheet__next__header-title{font-size:var(--cds-heading-03-font-size,1.25rem);font-weight:var(--cds-heading-03-font-weight,400);letter-spacing:var(--cds-heading-03-letter-spacing,0);line-height:var(--cds-heading-03-line-height,1.4)}}.c4p--tearsheet__next__header-title{align-items:flex-start;display:flex;gap:1rem;margin-block-end:.5rem}.c4p--tearsheet__next__header-title svg{flex-shrink:0}.c4p--tearsheet__next__header-title .c4p--tearsheet__next__title-end{margin-inline-start:1rem}.c4p--tearsheet__next__header-description{font-size:var(--cds-body-compact-01-font-size,.875rem);font-weight:var(--cds-body-compact-01-font-weight,400);letter-spacing:var(--cds-body-compact-01-letter-spacing,.16px);line-height:var(--cds-body-compact-01-line-height,1.28572)}.c4p--tearsheet__next__header--no-close-icon{display:none}.c4p--tearsheet__next__decorator{inset-block-start:.625rem;inset-inline-end:3rem;position:absolute}.c4p--tearsheet__next__navigation-bar{align-items:center;display:flex;gap:.125rem;justify-content:space-between;max-inline-size:calc(100% - .75rem);min-block-size:2.5rem;position:relative}.c4p--tearsheet__next__navigation-bar .cds--tabs{margin-inline-start:-1rem}.c4p--tearsheet__next__scroller-container{inset-block-end:0;inset-inline-end:-2.5rem;position:absolute}@media (max-width:41.98rem){.c4p--tearsheet__next__scroller-container{inset-inline-end:-1.5rem}}.c4p--tearsheet__next__scroller-container .c4p--tearsheet__next__scroller-button-icon-collapsed{transform:rotate(-180deg)}.c4p--tearsheet__next__content__header-actions{align-items:center;block-size:2rem;display:flex;flex:0 0 auto;inline-size:100%;justify-content:flex-end;margin-block-start:-14px;overflow:hidden}.c4p--tearsheet__next__content__header-actions>.c4p--tearsheet__next__header-action-item:not([data-hidden=true]){margin-inline-end:.5rem}.c4p--tearsheet__next__content__header-actions>.c4p--tearsheet__next__header-action-item:not([data-hidden=true]):nth-last-child(2){margin-inline-end:0}.c4p--tearsheet__next__content__header-actions>*{flex-shrink:0}@media (max-width:41.98rem){.c4p--tearsheet__next__content__header-actions{justify-content:flex-start;margin-inline-end:0}}.c4p--tearsheet__next__header-actions,.c4p--tearsheet__next__header-content{margin-block-end:1.5rem}@media (min-width:42rem){.c4p--tearsheet__next--wide .c4p--tearsheet__next__container{inline-size:calc(100% - 8rem)}}.c4p--tearsheet__next__body-layout{display:grid;grid-template-areas:\"influencer body\" \"influencer footer\";grid-template-columns:var(--tearsheet-influencer-width,16rem) 1fr;grid-template-rows:1fr auto;padding-block:0;padding-inline-end:0}.c4p--tearsheet__next__body-layout:not(.c4p--tearsheet__next__body-layout--has-influencer){grid-template-areas:\"body\" \"footer\";grid-template-columns:1fr}.c4p--tearsheet__next__influencer,:host(c4p-preview-tearsheet) ::slotted([slot=influencer]){border-inline-end:1px solid var(--cds-border-subtle-01,#c6c6c6);grid-area:influencer}.c4p--tearsheet__next__body,:host(c4p-preview-tearsheet) ::slotted([slot=body]){display:grid;grid-area:body;grid-template-columns:1fr var(--tearsheet-summary-content-width,16rem);overflow:hidden;position:relative}@media (max-width:41.98rem){.c4p--tearsheet__next__body,:host(c4p-preview-tearsheet) ::slotted([slot=body]){grid-template-columns:1fr 0}}.c4p--tearsheet__next__body>:only-child,:host(c4p-preview-tearsheet) ::slotted([slot=body])>:only-child{grid-column:1/-1}.c4p--tearsheet__next__body .cds--tab-content,:host(c4p-preview-tearsheet) ::slotted([slot=body]) .cds--tab-content{padding:0}.c4p--tearsheet__next__footer,:host(c4p-preview-tearsheet) ::slotted([slot=footer]){block-size:5rem;border-block-start:1px solid var(--cds-border-subtle-01,#c6c6c6);grid-area:footer;overflow:hidden}@media (max-width:41.98rem){.c4p--tearsheet__next__footer,:host(c4p-preview-tearsheet) ::slotted([slot=footer]){block-size:4rem}}@media (max-width:19.98rem){.c4p--tearsheet__next__footer.c4p--tearsheet__next__footer--three-actions,:host(c4p-preview-tearsheet) .c4p--tearsheet__next__footer--three-actions::slotted([slot=footer]){overflow-x:auto;overflow-y:hidden}.c4p--tearsheet__next__footer.c4p--tearsheet__next__footer--three-actions .c4p--action-set,:host(c4p-preview-tearsheet) .c4p--tearsheet__next__footer--three-actions::slotted([slot=footer]) .c4p--action-set{display:inline-flex;flex-shrink:0;min-inline-size:-moz-max-content;min-inline-size:max-content}}@media (max-width:41.98rem){.c4p--tearsheet__next__footer.c4p--tearsheet__next__footer--many-actions,:host(c4p-preview-tearsheet) .c4p--tearsheet__next__footer--many-actions::slotted([slot=footer]){overflow-x:auto;overflow-y:hidden}.c4p--tearsheet__next__footer.c4p--tearsheet__next__footer--many-actions .c4p--action-set,:host(c4p-preview-tearsheet) .c4p--tearsheet__next__footer--many-actions::slotted([slot=footer]) .c4p--action-set{display:inline-flex;flex-shrink:0;min-inline-size:-moz-max-content;min-inline-size:max-content}}.c4p--tearsheet__next__influencer,.c4p--tearsheet__next__main-content,.c4p--tearsheet__next__summary-content,:host ::slotted([slot=summary-content]),:host(c4p-preview-tearsheet) ::slotted([slot=influencer]){overflow:auto}.c4p--tearsheet__next__influencer:not(.c4p--tearsheet__next__flush),.c4p--tearsheet__next__main-content:not(.c4p--tearsheet__next__flush),.c4p--tearsheet__next__summary-content:not(.c4p--tearsheet__next__flush),:host :not(.c4p--tearsheet__next__flush)::slotted([slot=summary-content]),:host(c4p-preview-tearsheet) :not(.c4p--tearsheet__next__flush)::slotted([slot=influencer]){padding-inline:2rem}@media (max-width:41.98rem){.c4p--tearsheet__next__influencer:not(.c4p--tearsheet__next__flush),.c4p--tearsheet__next__main-content:not(.c4p--tearsheet__next__flush),.c4p--tearsheet__next__summary-content:not(.c4p--tearsheet__next__flush),:host :not(.c4p--tearsheet__next__flush)::slotted([slot=summary-content]),:host(c4p-preview-tearsheet) :not(.c4p--tearsheet__next__flush)::slotted([slot=influencer]){padding-inline:1rem}}.c4p--tearsheet__next__influencer:focus,.c4p--tearsheet__next__main-content:focus,.c4p--tearsheet__next__summary-content:focus,:host :focus::slotted([slot=summary-content]),:host(c4p-preview-tearsheet) :focus::slotted([slot=influencer]){outline:2px solid var(--cds-focus,#0f62fe);outline-offset:-2px}@media screen and (prefers-contrast){.c4p--tearsheet__next__influencer:focus,.c4p--tearsheet__next__main-content:focus,.c4p--tearsheet__next__summary-content:focus,:host :focus::slotted([slot=summary-content]),:host(c4p-preview-tearsheet) :focus::slotted([slot=influencer]){outline-style:dotted}}.c4p--tearsheet__next__side-panel,:host c4p-side-panel::part(dialog){block-size:100%;inline-size:100%!important;inset-block-start:0;max-inline-size:none;position:absolute;z-index:9999}.c4p--tearsheet__next__side-panel .c4p--side-panel__header,:host c4p-side-panel::part(dialog) .c4p--side-panel__header{min-block-size:0}.c4p--tearsheet__next--narrow .c4p--tearsheet__next__container{inline-size:480px;max-inline-size:480px}@media (width <= 480px){.c4p--tearsheet__next--narrow .c4p--tearsheet__next__container{inline-size:100%;max-inline-size:100%}}.c4p--tearsheet__next--narrow .c4p--tearsheet__next__header{padding-inline:1rem}.c4p--tearsheet__next--narrow .c4p--tearsheet__next__header.c4p--tearsheet__next__header-collapsed .c4p--tearsheet__next__header-actions{display:none}.c4p--tearsheet__next--narrow .c4p--tearsheet__next__header.c4p--tearsheet__next__header-collapsed .c4p--tearsheet__next__header-content{align-self:flex-start}.c4p--tearsheet__next--narrow .c4p--tearsheet__next__header-content-wrapper{display:flex;flex-direction:column}.c4p--tearsheet__next--narrow .c4p--tearsheet__next__header-title{font-size:var(--cds-heading-03-font-size,1.25rem);font-weight:var(--cds-heading-03-font-weight,400);letter-spacing:var(--cds-heading-03-letter-spacing,0);line-height:var(--cds-heading-03-line-height,1.4)}.c4p--tearsheet__next--narrow .c4p--tearsheet__next__content__header-actions{justify-content:flex-start;margin-inline-end:0}.c4p--tearsheet__next--narrow .c4p--tearsheet__next__body,:host(c4p-preview-tearsheet) .c4p--tearsheet__next--narrow ::slotted([slot=body]){grid-template-columns:1fr 0}.c4p--tearsheet__next--narrow .c4p--tearsheet__next__influencer:not(.c4p--tearsheet__next__flush),.c4p--tearsheet__next--narrow .c4p--tearsheet__next__main-content:not(.c4p--tearsheet__next__flush),.c4p--tearsheet__next--narrow .c4p--tearsheet__next__summary-content:not(.c4p--tearsheet__next__flush),:host .c4p--tearsheet__next--narrow :not(.c4p--tearsheet__next__flush)::slotted([slot=summary-content]),:host(c4p-preview-tearsheet) .c4p--tearsheet__next--narrow :not(.c4p--tearsheet__next__flush)::slotted([slot=influencer]){padding-inline:1rem}.c4p--tearsheet__next--narrow .c4p--tearsheet__next__footer,:host(c4p-preview-tearsheet) .c4p--tearsheet__next--narrow ::slotted([slot=footer]){block-size:4rem}.c4p--tearsheet__next--has-ai-label::part(dialog){background:linear-gradient(to top,var(--cds-layer),var(--cds-layer)) padding-box,linear-gradient(to bottom,var(--cds-ai-border-start,#78a9ff),var(--cds-ai-border-end,#d0e2ff)) border-box,linear-gradient(to top,var(--cds-layer),var(--cds-layer)) border-box;border:1px solid transparent!important;border-block-end:0;box-shadow:0 4px 10px 2px var(--cds-ai-drop-shadow,rgba(15,98,254,.1))}.c4p--tearsheet__next__main-content{position:relative}.c4p--tearsheet__next__main-content.c4p--tearsheet__next__flush{padding-inline:0}.c4p--tearsheet__next__main-content.c4p--tearsheet__next__main-content--no-summary{grid-column:1/-1}.c4p--tearsheet__next__main-content.c4p--tearsheet__next__main-content--has-ai-label{background:linear-gradient(to top,var(--cds-background,var(--cds-ai-popover-background,#fff)) 0,var(--cds-ai-aura-start,rgba(69,137,255,.1)) 0,15%,var(--cds-ai-aura-end,hsla(0,0%,100%,0)) 50%) padding-box,linear-gradient(to top,var(--cds-background,var(--cds-ai-popover-background,#fff)),var(--cds-background,var(--cds-ai-popover-background,#fff))) padding-box,linear-gradient(to bottom,var(--cds-ai-border-start,rgba(166,200,255,.64)),var(--cds-ai-border-end,#78a9ff)) border-box,linear-gradient(to top,var(--cds-background,var(--cds-ai-popover-background,#fff)),var(--cds-background,var(--cds-ai-popover-background,#fff))) border-box;box-shadow:inset 0 -80px 70px -65px var(--cds-ai-inner-shadow,rgba(69,137,255,.1))}:host ::slotted([slot=summary-content]:focus){outline:2px solid var(--cds-focus,#0f62fe);outline-offset:-2px}@media screen and (prefers-contrast){:host ::slotted([slot=summary-content]:focus){outline-style:dotted}}:host ::slotted([slot=summary-content][is-flush]){padding-inline:0}@media screen and (prefers-reduced-motion:reduce){:host(c4p-preview-tearsheet) ::part(dialog){align-self:flex-end;block-size:100%;border:1px solid var(--cds-border-subtle-01,#c6c6c6);inset-block-start:auto;max-block-size:calc(100% - var(--tearsheet-vertical-gap, calc(5rem + .5rem + .125rem)));transform:translate3d(0,min(95vh,500px),0);transition:none}}:host(c4p-preview-tearsheet) ::part(dialog){align-self:flex-end;block-size:100%;border:1px solid var(--cds-border-subtle-01,#c6c6c6);inset-block-start:auto;max-block-size:calc(100% - var(--tearsheet-vertical-gap, calc(5rem + .5rem + .125rem)));transform:translate3d(0,min(95vh,500px),0);transition:transform .24s cubic-bezier(0,0,.3,1),max-block-size .24s cubic-bezier(0,0,.3,1)}:host(c4p-preview-tearsheet) ::slotted([slot=influencer][is-flush]){padding-inline:0}:host(c4p-preview-tearsheet[open]) ::part(dialog){transform:translateZ(0);transition:transform .24s cubic-bezier(0,0,.3,1)}@media (prefers-reduced-motion:reduce){:host(c4p-preview-tearsheet[open]) ::part(dialog){transition:none}}@media (max-width:41.98rem){:host(:not(.c4p--tearsheet__next--stack-activated.is-visible)) ::part(dialog){max-block-size:none}}:host(c4p-preview-tearsheet.c4p--tearsheet__next--stack-activated.is-visible){--overlay-color:var(--cds-overlay,rgba(0,0,0,.6));--overlay-alpha:0.5}:host(c4p-preview-tearsheet.c4p--tearsheet__next--stack-activated.is-visible):before{background:var(--overlay-color);content:\"\";display:block;inset:0;opacity:calc(var(--overlay-alpha) - var(--stack-depth)*.1);pointer-events:none;position:fixed;transition:background-color .24s cubic-bezier(.4,.14,1,1),opacity .24s cubic-bezier(.4,.14,1,1);z-index:calc(9000 - var(--stack-depth, 0))}@media (prefers-reduced-motion:reduce){:host(c4p-preview-tearsheet.c4p--tearsheet__next--stack-activated.is-visible):before{transition:none}}:host(c4p-preview-tearsheet.c4p--tearsheet__next--stack-activated.is-visible) cds-modal{background-color:transparent}:host(c4p-preview-tearsheet.c4p--tearsheet__next--stack-activated.is-visible) ::part(dialog){max-block-size:calc(100% - var(--tearsheet-vertical-gap, calc(5rem + .5rem + .125rem)) + var(--block-size-change));transform:scaleX(var(--scale-factor))}:host(c4p-preview-tearsheet[variant=narrow]) .c4p--tearsheet__next__header{padding-inline:1rem}:host(c4p-preview-tearsheet[variant=narrow]) .c4p--tearsheet__next__header.c4p--tearsheet__next__header-collapsed .c4p--tearsheet__next__header-actions{display:none}:host(c4p-preview-tearsheet[variant=narrow]) .c4p--tearsheet__next__header-content-wrapper{display:flex;flex-direction:column}:host(c4p-preview-tearsheet[variant=narrow]) .c4p--tearsheet__next__header-title{font-size:var(--cds-heading-03-font-size,1.25rem);font-weight:var(--cds-heading-03-font-weight,400);letter-spacing:var(--cds-heading-03-letter-spacing,0);line-height:var(--cds-heading-03-line-height,1.4)}:host(c4p-preview-tearsheet[variant=narrow]) .c4p--tearsheet__next__content__header-actions{justify-content:flex-start;margin-inline-end:0}:host(c4p-preview-tearsheet[variant=narrow]) .c4p--tearsheet__next__body,:host(c4p-preview-tearsheet[variant=narrow]):host(c4p-preview-tearsheet) ::slotted([slot=body]){grid-template-columns:1fr 0}:host(c4p-preview-tearsheet[variant=narrow]) ::slotted([slot=influencer]),:host(c4p-preview-tearsheet[variant=narrow]) ::slotted([slot=summary-content]){padding:0!important}@media (max-width:41.98rem){:host(c4p-preview-tearsheet) ::slotted([slot=influencer]),:host(c4p-preview-tearsheet) ::slotted([slot=summary-content]){padding:0!important}}:host-context(c4p-preview-tearsheet[variant=narrow]) ::slotted([slot=summary-content]){padding:0}:host ::slotted([slot=footer]){padding-block:0}:host-context(c4p-preview-tearsheet[variant=narrow]){display:flex;flex-direction:column}:host-context(c4p-preview-tearsheet[variant=narrow]) .c4p--tearsheet__next__header-title{font-size:var(--cds-heading-03-font-size,1.25rem);font-weight:var(--cds-heading-03-font-weight,400);letter-spacing:var(--cds-heading-03-letter-spacing,0);line-height:var(--cds-heading-03-line-height,1.4)}:host-context(c4p-preview-tearsheet[variant=narrow]) .c4p--tearsheet__next__header-actions{justify-content:flex-start;margin-inline-end:0}:host-context(c4p-preview-tearsheet[variant=narrow]):host-context(c4p-tearsheet-header[collapsed]) .c4p--tearsheet__next__header-actions{display:none}:host-context(c4p-preview-tearsheet[variant=narrow]):host-context(c4p-tearsheet-header[collapsed]) .c4p--tearsheet__next__header-content{align-self:flex-start}:host-context(c4p-preview-tearsheet[variant=narrow]) .c4p--tearsheet__next__title-start{align-items:center}:host-context(c4p-preview-tearsheet[variant=narrow]) .c4p--tearsheet__next__title-start ::slotted(*){block-size:1.5rem;inline-size:1.5rem}:host{display:grid;flex-basis:unset;gap:1rem;grid-template-columns:minmax(auto,40rem) minmax(var(--tearsheet-header-title-grid-width,0),1fr);inline-size:calc(100% - var(--tearsheet-header-action-offset))}@media (max-width:41.98rem){:host{display:flex;flex-direction:column}:host .c4p--tearsheet__next__header-actions{justify-content:flex-start;margin-inline-end:0}}.c4p--tearsheet__next__header-actions{display:flex;justify-content:flex-end;margin-block-start:-14px;order:2}@media (max-width:41.98rem){.c4p--tearsheet__next__header-actions{order:0}}.c4p--tearsheet__next__header-content{order:1}@media (max-width:41.98rem){.c4p--tearsheet__next__header-content{order:0}}:host .c4p--tearsheet__next__header-actions,:host .c4p--tearsheet__next__header-content :not(.c4p--tearsheet__next__content__title-wrapper,.c4p--tearsheet__next__header-label){opacity:1;transition:all .24s cubic-bezier(0,0,.3,1),opacity .24s cubic-bezier(0,0,.3,1)}:host-context(c4p-tearsheet-header[collapsed]) .c4p--tearsheet__next__header-actions>:not(.c4p--tearsheet__next__content__header-actions){margin:0;max-block-size:0;opacity:0;overflow:hidden;padding:0;pointer-events:none;transition:all .24s cubic-bezier(0,0,.3,1)}:host-context(c4p-tearsheet-header[collapsed]) .c4p--tearsheet__next__header-content>:not(.c4p--tearsheet__next__content__title-wrapper){margin:0;max-block-size:0;opacity:0;overflow:hidden;padding:0;pointer-events:none;transition:all .24s cubic-bezier(0,0,.3,1)}:host-context(c4p-tearsheet-header[collapsed]) .c4p--tearsheet__next__header-content>:not(.c4p--tearsheet__next__content__title-wrapper) *{margin:0;max-block-size:0;opacity:0;overflow:hidden;padding:0;pointer-events:none;transition:all .24s cubic-bezier(0,0,.3,1)}:host-context(c4p-tearsheet-header[collapsed]) .c4p--tearsheet__next__header-title{align-items:center;font-size:var(--cds-label-02-font-size,.875rem);font-weight:var(--cds-label-02-font-weight,400);letter-spacing:var(--cds-label-02-letter-spacing,.16px);line-height:var(--cds-label-02-line-height,1.28572);margin-block-start:.25rem;transition:all .24s cubic-bezier(0,0,.3,1)}:host-context(c4p-tearsheet-header[collapsed]) .c4p--tearsheet__next__header-title>span{align-items:center;block-size:1.5rem;display:flex}:host-context(c4p-tearsheet-header[collapsed]) .c4p--tearsheet__next__header-content{align-self:center;margin-block-end:0}@media (max-width:41.98rem){:host-context(c4p-tearsheet-header[collapsed]) .c4p--tearsheet__next__header-actions{display:none}}:host-context(c4p-tearsheet-header[collapsed]) .c4p--tearsheet__next__content__title-wrapper,:host-context(c4p-tearsheet-header[collapsed]) .c4p--tearsheet__next__header-actions,:host-context(c4p-tearsheet-header[collapsed]) .c4p--tearsheet__next__header-content,:host-context(c4p-tearsheet-header[collapsed]) .c4p--tearsheet__next__header-title{margin-block:0;transition:margin-block .24s ease}:host-context(c4p-tearsheet-header[collapsed]) .c4p--tearsheet__next__header-actions{margin-block-start:-.125rem}:host-context(c4p-tearsheet-header[collapsed]) .c4p--tearsheet__next__title-start{align-items:center;display:inline-flex}:host-context(c4p-tearsheet-header[collapsed]) .c4p--tearsheet__next__title-start ::slotted(*){block-size:1rem;inline-size:1rem}@media screen and (prefers-reduced-motion:reduce){.c4p--tearsheet__next__title-start ::slotted(*){transition:none}}.c4p--tearsheet__next__title-start ::slotted(*){transition:all .24s cubic-bezier(0,0,.3,1)}:host-context(c4p-preview-tearsheet:not([open])) .c4p--tearsheet__next__header-actions,:host-context(c4p-preview-tearsheet:not([open])) .c4p--tearsheet__next__header-content,:host-context(c4p-preview-tearsheet:not([open])) .c4p--tearsheet__next__header-content *{opacity:0;transition:opacity .1s ease-out}"]);
10
+ var tearsheet_header_content_default = css(["@keyframes cds--hide-feedback{0%{opacity:1;visibility:inherit}to{opacity:0;visibility:hidden}}@keyframes cds--show-feedback{0%{opacity:0;visibility:hidden}to{opacity:1;visibility:inherit}}@keyframes cds--skeleton{0%{opacity:.3;transform:scaleX(0);transform-origin:left}20%{opacity:1;transform:scaleX(1);transform-origin:left}28%{transform:scaleX(1);transform-origin:right}51%{transform:scaleX(0);transform-origin:right}58%{transform:scaleX(0);transform-origin:right}82%{transform:scaleX(1);transform-origin:right}83%{transform:scaleX(1);transform-origin:left}96%{transform:scaleX(0);transform-origin:left}to{opacity:.3;transform:scaleX(0);transform-origin:left}}.cds--layout--size-xs{--cds-layout-size-height-context:var(--cds-layout-size-height-xs,1.5rem);--cds-layout-size-height:var(--cds-layout-size-height-context)}.cds--layout-constraint--size__default-xs{--cds-layout-size-height:var(--cds-layout-size-height-context,var(--cds-layout-size-height-xs,1.5rem))}.cds--layout-constraint--size__min-xs{--cds-layout-size-height-min:var(--cds-layout-size-height-xs,1.5rem)}.cds--layout-constraint--size__max-xs{--cds-layout-size-height-max:var(--cds-layout-size-height-xs,1.5rem)}.cds--layout--size-sm{--cds-layout-size-height-context:var(--cds-layout-size-height-sm,2rem);--cds-layout-size-height:var(--cds-layout-size-height-context)}.cds--layout-constraint--size__default-sm{--cds-layout-size-height:var(--cds-layout-size-height-context,var(--cds-layout-size-height-sm,2rem))}.cds--layout-constraint--size__min-sm{--cds-layout-size-height-min:var(--cds-layout-size-height-sm,2rem)}.cds--layout-constraint--size__max-sm{--cds-layout-size-height-max:var(--cds-layout-size-height-sm,2rem)}.cds--layout--size-md{--cds-layout-size-height-context:var(--cds-layout-size-height-md,2.5rem);--cds-layout-size-height:var(--cds-layout-size-height-context)}.cds--layout-constraint--size__default-md{--cds-layout-size-height:var(--cds-layout-size-height-context,var(--cds-layout-size-height-md,2.5rem))}.cds--layout-constraint--size__min-md{--cds-layout-size-height-min:var(--cds-layout-size-height-md,2.5rem)}.cds--layout-constraint--size__max-md{--cds-layout-size-height-max:var(--cds-layout-size-height-md,2.5rem)}.cds--layout--size-lg{--cds-layout-size-height-context:var(--cds-layout-size-height-lg,3rem);--cds-layout-size-height:var(--cds-layout-size-height-context)}.cds--layout-constraint--size__default-lg{--cds-layout-size-height:var(--cds-layout-size-height-context,var(--cds-layout-size-height-lg,3rem))}.cds--layout-constraint--size__min-lg{--cds-layout-size-height-min:var(--cds-layout-size-height-lg,3rem)}.cds--layout-constraint--size__max-lg{--cds-layout-size-height-max:var(--cds-layout-size-height-lg,3rem)}.cds--layout--size-xl{--cds-layout-size-height-context:var(--cds-layout-size-height-xl,4rem);--cds-layout-size-height:var(--cds-layout-size-height-context)}.cds--layout-constraint--size__default-xl{--cds-layout-size-height:var(--cds-layout-size-height-context,var(--cds-layout-size-height-xl,4rem))}.cds--layout-constraint--size__min-xl{--cds-layout-size-height-min:var(--cds-layout-size-height-xl,4rem)}.cds--layout-constraint--size__max-xl{--cds-layout-size-height-max:var(--cds-layout-size-height-xl,4rem)}.cds--layout--size-2xl{--cds-layout-size-height-context:var(--cds-layout-size-height-2xl,5rem);--cds-layout-size-height:var(--cds-layout-size-height-context)}.cds--layout-constraint--size__default-2xl{--cds-layout-size-height:var(--cds-layout-size-height-context,var(--cds-layout-size-height-2xl,5rem))}.cds--layout-constraint--size__min-2xl{--cds-layout-size-height-min:var(--cds-layout-size-height-2xl,5rem)}.cds--layout-constraint--size__max-2xl{--cds-layout-size-height-max:var(--cds-layout-size-height-2xl,5rem)}.cds--layout--density-condensed{--cds-layout-density-padding-inline-context:var(--cds-layout-density-padding-inline-condensed,0.5rem);--cds-layout-density-padding-inline:var(--cds-layout-density-padding-inline-context)}.cds--layout-constraint--density__default-condensed{--cds-layout-density-padding-inline:var(--cds-layout-density-padding-inline-context,var(--cds-layout-density-padding-inline-condensed,0.5rem))}.cds--layout-constraint--density__min-condensed{--cds-layout-density-padding-inline-min:var(--cds-layout-density-padding-inline-condensed,0.5rem)}.cds--layout-constraint--density__max-condensed{--cds-layout-density-padding-inline-max:var(--cds-layout-density-padding-inline-condensed,0.5rem)}.cds--layout--density-normal{--cds-layout-density-padding-inline-context:var(--cds-layout-density-padding-inline-normal,1rem);--cds-layout-density-padding-inline:var(--cds-layout-density-padding-inline-context)}.cds--layout-constraint--density__default-normal{--cds-layout-density-padding-inline:var(--cds-layout-density-padding-inline-context,var(--cds-layout-density-padding-inline-normal,1rem))}.cds--layout-constraint--density__min-normal{--cds-layout-density-padding-inline-min:var(--cds-layout-density-padding-inline-normal,1rem)}.cds--layout-constraint--density__max-normal{--cds-layout-density-padding-inline-max:var(--cds-layout-density-padding-inline-normal,1rem)}:root{--cds-layout-size-height-xs:1.5rem;--cds-layout-size-height-sm:2rem;--cds-layout-size-height-md:2.5rem;--cds-layout-size-height-lg:3rem;--cds-layout-size-height-xl:4rem;--cds-layout-size-height-2xl:5rem;--cds-layout-size-height-min:0px;--cds-layout-size-height-max:999999999px;--cds-layout-density-padding-inline-condensed:0.5rem;--cds-layout-density-padding-inline-normal:1rem;--cds-layout-density-padding-inline-min:0px;--cds-layout-density-padding-inline-max:999999999px}.cds--assistive-text,.cds--visually-hidden{block-size:1px;border:0;margin:-1px;overflow:hidden;padding:0;position:absolute;clip:rect(0,0,0,0);inline-size:1px;visibility:inherit;white-space:nowrap}.c4p--tearsheet__next.c4p--tearsheet__next:not(.c4p--tearsheet__next--keep-mounted){animation:c4p--tearsheet__next--presence-tearsheet__enter .24s cubic-bezier(0,0,.3,1);opacity:1}.c4p--tearsheet__next.c4p--tearsheet__next:not(.c4p--tearsheet__next--keep-mounted).c4p--tearsheet__next.c4p--tearsheet__next .c4p--tearsheet__next__container{animation:c4p--tearsheet__next--presence-tearsheet--container__enter .24s cubic-bezier(0,0,.3,1);transform:translateZ(0)}@media screen and (prefers-reduced-motion:reduce){.c4p--tearsheet__next.c4p--tearsheet__next:not(.c4p--tearsheet__next--keep-mounted).c4p--tearsheet__next.c4p--tearsheet__next .c4p--tearsheet__next__container{animation:none}}.c4p--tearsheet__next.c4p--tearsheet__next:not(.c4p--tearsheet__next--keep-mounted).c4p--tearsheet__next--stacked.is-visible .c4p--tearsheet__next__container{transform:scaleX(var(--scale-factor))}.c4p--tearsheet__next.c4p--tearsheet__next:not(.c4p--tearsheet__next--keep-mounted)[data-tearsheet-exiting]{animation:c4p--tearsheet__next--presence-tearsheet__exit .24s cubic-bezier(.4,.14,1,1) forwards}.c4p--tearsheet__next.c4p--tearsheet__next:not(.c4p--tearsheet__next--keep-mounted)[data-tearsheet-exiting].c4p--tearsheet__next.c4p--tearsheet__next .c4p--tearsheet__next__container{animation:c4p--tearsheet__next--presence-tearsheet--container__exit .24s cubic-bezier(0,0,.3,1) forwards}@media screen and (prefers-reduced-motion:reduce){.c4p--tearsheet__next.c4p--tearsheet__next:not(.c4p--tearsheet__next--keep-mounted)[data-tearsheet-exiting].c4p--tearsheet__next.c4p--tearsheet__next .c4p--tearsheet__next__container{animation:none}}.c4p--tearsheet__next.c4p--tearsheet__next--keep-mounted:not(.is-visible).c4p--tearsheet__next.c4p--tearsheet__next .c4p--tearsheet__next__container{transform:translate3d(0,min(95vh,500px),0)}@keyframes c4p--tearsheet__next--presence-tearsheet__enter{0%{opacity:0;transition:none}}@keyframes c4p--tearsheet__next--presence-tearsheet__exit{to{opacity:0}}@keyframes c4p--tearsheet__next--presence-tearsheet--container__enter{0%{transform:translate3d(0,min(95vh,500px),0);transition:none}}@keyframes c4p--tearsheet__next--presence-tearsheet--container__exit{to{transform:translate3d(0,min(95vh,500px),0)}}.c4p--tearsheet__next .c4p--tearsheet__next__container{align-self:flex-end;block-size:100%;border:1px solid var(--cds-border-subtle-01,#c6c6c6);inset-block-start:auto;max-block-size:calc(100% - var(--tearsheet-vertical-gap, calc(5rem + .5rem)));max-inline-size:var(--tearsheet-max-inline-size,1312px)}@media (max-width:41.98rem){.c4p--tearsheet__next:not(.c4p--tearsheet__next--stack-activated.is-visible) .c4p--tearsheet__next__container{max-block-size:none}}.c4p--tearsheet__next:not(.is-visible).c4p--tearsheet__next.c4p--tearsheet__next .c4p--tearsheet__next__container{transform:translate3d(0,min(95vh,500px),0)}.c4p--tearsheet__next.c4p--tearsheet__next.c4p--tearsheet__next--has-ai-label .c4p--tearsheet__next__container{background:linear-gradient(to top,var(--cds-layer),var(--cds-layer)) padding-box,linear-gradient(to bottom,var(--cds-ai-border-start,#78a9ff),var(--cds-ai-border-end,#d0e2ff)) border-box,linear-gradient(to top,var(--cds-layer),var(--cds-layer)) border-box;border:1px solid transparent;border-block-end:0;box-shadow:0 4px 10px 2px var(--cds-ai-drop-shadow,rgba(15,98,254,.1))}.c4p--tearsheet__next.c4p--tearsheet__next.c4p--tearsheet__next--has-ai-label .c4p--tearsheet__next__main-content{background:linear-gradient(to top,var(--cds-background,var(--cds-ai-popover-background,#fff)) 0,var(--cds-ai-aura-start,rgba(69,137,255,.1)) 0,15%,var(--cds-ai-aura-end,hsla(0,0%,100%,0)) 50%) padding-box,linear-gradient(to top,var(--cds-background,var(--cds-ai-popover-background,#fff)),var(--cds-background,var(--cds-ai-popover-background,#fff))) padding-box,linear-gradient(to bottom,var(--cds-ai-border-start,rgba(166,200,255,.64)),var(--cds-ai-border-end,#78a9ff)) border-box,linear-gradient(to top,var(--cds-background,var(--cds-ai-popover-background,#fff)),var(--cds-background,var(--cds-ai-popover-background,#fff))) border-box;box-shadow:inset 0 -80px 70px -65px var(--cds-ai-inner-shadow,rgba(69,137,255,.1));position:relative}.c4p--tearsheet__next.c4p--tearsheet__next.c4p--tearsheet__next .c4p--tearsheet__next__container{transition:transform .24s cubic-bezier(0,0,.3,1),max-block-size .24s cubic-bezier(0,0,.3,1)}@media screen and (prefers-reduced-motion:reduce){.c4p--tearsheet__next.c4p--tearsheet__next.c4p--tearsheet__next .c4p--tearsheet__next__container{transition:none}}.c4p--tearsheet__next .c4p--tearsheet__next__header{align-content:space-between;border-block-end:1px solid var(--cds-border-subtle-01,#c6c6c6);display:flex;flex-wrap:wrap;margin-block:0;max-block-size:50vh;padding-block-end:0;padding-block-start:1.5rem;padding-inline:2rem}.c4p--tearsheet__next .c4p--tearsheet__next__header>*{flex-basis:100%}.c4p--tearsheet__next .c4p--tearsheet__next__header>:not(.c4p--tearsheet__next__navigation-bar,.c4p--tearsheet__next__header-content-wrapper,.cds--modal-close-button,.c4p--tearsheet__next__close-button){margin-block-end:1.5rem}@media (max-width:41.98rem){.c4p--tearsheet__next .c4p--tearsheet__next__header{padding-inline:1rem}}.c4p--tearsheet__next .cds--modal-container--sm .cds--modal-header{padding-inline-end:2rem}.c4p--tearsheet__next .c4p--tearsheet__next__header-content-wrapper{display:grid;flex-basis:unset;gap:1rem;grid-template-columns:minmax(auto,40rem) minmax(var(--tearsheet-header-title-grid-width,0),1fr);inline-size:calc(100% - var(--tearsheet-header-action-offset))}@media (max-width:41.98rem){.c4p--tearsheet__next .c4p--tearsheet__next__header-content-wrapper{display:flex;flex-direction:column}}@media (min-width:42rem){.c4p--tearsheet__next:not(.c4p--tearsheet__next--narrow) .c4p--tearsheet__next__header-content-wrapper .c4p--tearsheet__next__header-actions{order:2}.c4p--tearsheet__next:not(.c4p--tearsheet__next--narrow) .c4p--tearsheet__next__header-content-wrapper .c4p--tearsheet__next__header-content{order:1}}.c4p--tearsheet__next .c4p--tearsheet__next__header>:not(.c4p--tearsheet__next__navigation-bar,.c4p--tearsheet__next__header-content-wrapper,.cds--modal-close-button,.c4p--tearsheet__next__close-button,.c4p--tearsheet__next__decorator,.excludeFromCollapse){max-block-size:50vh;opacity:1;overflow:hidden;transition:max-block-size .24s cubic-bezier(0,0,.3,1),opacity .24s cubic-bezier(0,0,.3,1),margin .24s cubic-bezier(0,0,.3,1),padding .24s cubic-bezier(0,0,.3,1)}.c4p--tearsheet__next .c4p--tearsheet__next__header .c4p--tearsheet__next__header-actions,.c4p--tearsheet__next .c4p--tearsheet__next__header .c4p--tearsheet__next__header-content-wrapper .c4p--tearsheet__next__header-content :not(.c4p--tearsheet__next__content__title-wrapper,.c4p--tearsheet__next__header-label){opacity:1;transition:all .24s cubic-bezier(0,0,.3,1),opacity .24s cubic-bezier(0,0,.3,1)}.c4p--tearsheet__next .cds--modal-close{transition:all .24s ease}.c4p--tearsheet__next .c4p--tearsheet__next__header-collapsed{padding-block-start:0;transition:padding .24s cubic-bezier(0,0,.3,1)}.c4p--tearsheet__next .c4p--tearsheet__next__header-collapsed .c4p--tearsheet__next__header-actions>:not(.c4p--tearsheet__next__content__header-actions),.c4p--tearsheet__next .c4p--tearsheet__next__header-collapsed .c4p--tearsheet__next__header-content-wrapper .c4p--tearsheet__next__header-content>:not(.c4p--tearsheet__next__content__title-wrapper) *,.c4p--tearsheet__next .c4p--tearsheet__next__header-collapsed .c4p--tearsheet__next__header-content>:not(.c4p--tearsheet__next__content__title-wrapper),.c4p--tearsheet__next .c4p--tearsheet__next__header-collapsed>:not(.c4p--tearsheet__next__navigation-bar,.c4p--tearsheet__next__header-content-wrapper,.cds--modal-close-button,.c4p--tearsheet__next__close-button,.c4p--tearsheet__next__decorator,.excludeFromCollapse),.c4p--tearsheet__next .c4p--tearsheet__next__header-collapsed>:not(.c4p--tearsheet__next__navigation-bar,.c4p--tearsheet__next__header-content-wrapper,.cds--modal-close-button,.c4p--tearsheet__next__close-button,.c4p--tearsheet__next__decorator,.excludeFromCollapse) *{margin:0;max-block-size:0;opacity:0;overflow:hidden;padding:0;pointer-events:none;transition:all .24s cubic-bezier(0,0,.3,1);visibility:hidden}.c4p--tearsheet__next .c4p--tearsheet__next__header-collapsed .c4p--tearsheet__next__header-title{align-items:center;font-size:var(--cds-label-02-font-size,.875rem);font-weight:var(--cds-label-02-font-weight,400);gap:.5rem;letter-spacing:var(--cds-label-02-letter-spacing,.16px);line-height:var(--cds-label-02-line-height,1.28572);margin-block-start:.25rem;transition:all .24s cubic-bezier(0,0,.3,1)}.c4p--tearsheet__next .c4p--tearsheet__next__header-collapsed .c4p--tearsheet__next__header-title>span{align-items:center;block-size:1.5rem;display:flex}.c4p--tearsheet__next .c4p--tearsheet__next__header-collapsed .c4p--tearsheet__next__header-title .c4p--tearsheet__next__title-end svg,.c4p--tearsheet__next .c4p--tearsheet__next__header-collapsed .c4p--tearsheet__next__header-title .c4p--tearsheet__next__title-start svg{inline-size:1rem}.c4p--tearsheet__next .c4p--tearsheet__next__header-collapsed .c4p--tearsheet__next__header-content{align-self:center;margin-block-end:0}.c4p--tearsheet__next .c4p--tearsheet__next__header-collapsed .cds--modal-close{block-size:2.5rem;inline-size:2.5rem;transition:all .24s ease}.c4p--tearsheet__next .c4p--tearsheet__next__header-collapsed .c4p--tearsheet__next__decorator{inset-block-start:.5rem}.c4p--tearsheet__next .c4p--tearsheet__next__header-collapsed .c4p--tearsheet__next__header-title{block-size:2.5rem}.c4p--tearsheet__next .c4p--tearsheet__next__header-collapsed .c4p--tearsheet__next__content__header-actions{block-size:1.5rem;margin-block-start:.5rem;transition:all .24s ease}@media (max-width:41.98rem){.c4p--tearsheet__next .c4p--tearsheet__next__header-collapsed .c4p--tearsheet__next__header-actions{display:none}}.c4p--tearsheet__next .c4p--tearsheet__next__header-collapsed .c4p--tearsheet__next__content__title-wrapper,.c4p--tearsheet__next .c4p--tearsheet__next__header-collapsed .c4p--tearsheet__next__header-actions,.c4p--tearsheet__next .c4p--tearsheet__next__header-collapsed .c4p--tearsheet__next__header-content,.c4p--tearsheet__next .c4p--tearsheet__next__header-collapsed .c4p--tearsheet__next__header-content-wrapper,.c4p--tearsheet__next .c4p--tearsheet__next__header-collapsed .c4p--tearsheet__next__header-title{margin-block:0;transition:margin-block .24s ease}.c4p--tearsheet__next .c4p--tearsheet__next__header-collapsed .c4p--tearsheet__next__header-content-wrapper{min-block-size:2.5rem}.c4p--tearsheet__next .c4p--tearsheet__next__header-collapsed .c4p--tearsheet__next__navigation-bar:before{background:var(--cds-border-subtle-01,#c6c6c6);block-size:1px;content:\"\";inline-size:calc(100% + 5rem);inset-block-start:0;inset-inline-start:-2rem;pointer-events:none;position:absolute;z-index:1}.c4p--tearsheet__next.c4p--tearsheet__next--stack-activated.is-visible{--overlay-color:var(--cds-overlay,rgba(0,0,0,.6));--overlay-alpha:0.5;background-color:initial;z-index:calc(9000 - var(--stack-depth, 0))}.c4p--tearsheet__next.c4p--tearsheet__next--stack-activated.is-visible:before{background:var(--overlay-color);content:\"\";display:block;inset:0;opacity:calc(var(--overlay-alpha) - var(--stack-depth)*.1);position:absolute;transition:background-color .24s cubic-bezier(.4,.14,1,1),opacity .24s cubic-bezier(.4,.14,1,1)}@media (prefers-reduced-motion:reduce){.c4p--tearsheet__next.c4p--tearsheet__next--stack-activated.is-visible:before{transition:none}}.c4p--tearsheet__next.c4p--tearsheet__next--stack-activated.is-visible.is-visible .c4p--tearsheet__next__container{max-block-size:calc(100% - var(--tearsheet-vertical-gap, calc(5rem + .5rem + .125rem)) + var(--block-size-change));transform:scaleX(var(--scale-factor))}.c4p--tearsheet__next__header-label{color:var(--cds-text-secondary,#525252);font-size:var(--cds-label-01-font-size,.75rem);font-weight:var(--cds-label-01-font-weight,400);letter-spacing:var(--cds-label-01-letter-spacing,.32px);line-height:var(--cds-label-01-line-height,1.33333);margin-block-end:.25rem}.c4p--tearsheet__next__header-title{font-size:var(--cds-heading-04-font-size,1.75rem);font-weight:var(--cds-heading-04-font-weight,400);letter-spacing:var(--cds-heading-04-letter-spacing,0);line-height:var(--cds-heading-04-line-height,1.28572)}@media (max-width:41.98rem){.c4p--tearsheet__next__header-title{font-size:var(--cds-heading-03-font-size,1.25rem);font-weight:var(--cds-heading-03-font-weight,400);letter-spacing:var(--cds-heading-03-letter-spacing,0);line-height:var(--cds-heading-03-line-height,1.4)}}.c4p--tearsheet__next__header-title{align-items:flex-start;display:flex;gap:1rem;margin-block-end:.5rem}.c4p--tearsheet__next__header-title svg{flex-shrink:0}.c4p--tearsheet__next__header-title .c4p--tearsheet__next__title-end{margin-inline-start:1rem}.c4p--tearsheet__next__header-description{font-size:var(--cds-body-compact-01-font-size,.875rem);font-weight:var(--cds-body-compact-01-font-weight,400);letter-spacing:var(--cds-body-compact-01-letter-spacing,.16px);line-height:var(--cds-body-compact-01-line-height,1.28572)}.c4p--tearsheet__next__header--no-close-icon{display:none}.c4p--tearsheet__next__navigation-bar{align-items:center;display:flex;gap:.125rem;justify-content:space-between;max-inline-size:calc(100% - .75rem);min-block-size:2.5rem;position:relative}.c4p--tearsheet__next__navigation-bar .cds--tabs{margin-inline-start:-1rem}.c4p--tearsheet__next__scroller-container{inset-block-end:0;inset-inline-end:-2.5rem;position:absolute}@media (max-width:41.98rem){.c4p--tearsheet__next__scroller-container{inset-inline-end:-1.5rem}}.c4p--tearsheet__next__scroller-container .c4p--tearsheet__next__scroller-button-icon-collapsed{transform:rotate(-180deg)}.c4p--tearsheet__next__content__header-actions{align-items:center;block-size:2rem;display:flex;flex:0 0 auto;inline-size:100%;justify-content:flex-end;margin-block-start:-14px;overflow:hidden}.c4p--tearsheet__next__content__header-actions>.c4p--tearsheet__next__header-action-item:not([data-hidden=true]){margin-inline-end:.5rem}.c4p--tearsheet__next__content__header-actions>.c4p--tearsheet__next__header-action-item:not([data-hidden=true]):nth-last-child(2){margin-inline-end:0}.c4p--tearsheet__next__content__header-actions>*{flex-shrink:0}@media (max-width:41.98rem){.c4p--tearsheet__next__content__header-actions{justify-content:flex-start;margin-inline-end:0}}.c4p--tearsheet__next__header-actions,.c4p--tearsheet__next__header-content{margin-block-end:1.5rem}@media (min-width:42rem){.c4p--tearsheet__next--wide .c4p--tearsheet__next__container{inline-size:calc(100% - 8rem)}}.c4p--tearsheet__next__body-layout{display:grid;grid-template-areas:\"influencer body\" \"influencer footer\";grid-template-columns:var(--tearsheet-influencer-width,16rem) 1fr;grid-template-rows:1fr auto;padding-block:0;padding-inline-end:0}.c4p--tearsheet__next__body-layout:not(.c4p--tearsheet__next__body-layout--has-influencer){grid-template-areas:\"body\" \"footer\";grid-template-columns:1fr}.c4p--tearsheet__next__influencer,:host(c4p-preview-tearsheet) ::slotted([slot=influencer]){border-inline-end:1px solid var(--cds-border-subtle-01,#c6c6c6);grid-area:influencer}.c4p--tearsheet__next__body,:host(c4p-preview-tearsheet) ::slotted([slot=body]){display:grid;grid-area:body;grid-template-columns:1fr var(--tearsheet-summary-content-width,16rem);overflow:hidden;position:relative}@media (max-width:41.98rem){.c4p--tearsheet__next__body,:host(c4p-preview-tearsheet) ::slotted([slot=body]){grid-template-columns:1fr 0}}.c4p--tearsheet__next__body>:only-child,:host(c4p-preview-tearsheet) ::slotted([slot=body])>:only-child{grid-column:1/-1}.c4p--tearsheet__next__body .cds--tab-content,:host(c4p-preview-tearsheet) ::slotted([slot=body]) .cds--tab-content{padding:0}.c4p--tearsheet__next__footer,:host(c4p-preview-tearsheet) ::slotted([slot=footer]){block-size:5rem;border-block-start:1px solid var(--cds-border-subtle-01,#c6c6c6);grid-area:footer;overflow:hidden}@media (max-width:41.98rem){.c4p--tearsheet__next__footer,:host(c4p-preview-tearsheet) ::slotted([slot=footer]){block-size:4rem}}@media (max-width:19.98rem){.c4p--tearsheet__next__footer.c4p--tearsheet__next__footer--three-actions,:host(c4p-preview-tearsheet) .c4p--tearsheet__next__footer--three-actions::slotted([slot=footer]){overflow-x:auto;overflow-y:hidden}.c4p--tearsheet__next__footer.c4p--tearsheet__next__footer--three-actions .c4p--action-set,:host(c4p-preview-tearsheet) .c4p--tearsheet__next__footer--three-actions::slotted([slot=footer]) .c4p--action-set{display:inline-flex;flex-shrink:0;min-inline-size:-moz-max-content;min-inline-size:max-content}}@media (max-width:41.98rem){.c4p--tearsheet__next__footer.c4p--tearsheet__next__footer--many-actions,:host(c4p-preview-tearsheet) .c4p--tearsheet__next__footer--many-actions::slotted([slot=footer]){overflow-x:auto;overflow-y:hidden}.c4p--tearsheet__next__footer.c4p--tearsheet__next__footer--many-actions .c4p--action-set,:host(c4p-preview-tearsheet) .c4p--tearsheet__next__footer--many-actions::slotted([slot=footer]) .c4p--action-set{display:inline-flex;flex-shrink:0;min-inline-size:-moz-max-content;min-inline-size:max-content}}.c4p--tearsheet__next__influencer,.c4p--tearsheet__next__main-content,.c4p--tearsheet__next__summary-content,:host ::slotted([slot=summary-content]),:host(c4p-preview-tearsheet) ::slotted([slot=influencer]){overflow:auto}.c4p--tearsheet__next__influencer:not(.c4p--tearsheet__next__flush),.c4p--tearsheet__next__main-content:not(.c4p--tearsheet__next__flush),.c4p--tearsheet__next__summary-content:not(.c4p--tearsheet__next__flush),:host :not(.c4p--tearsheet__next__flush)::slotted([slot=summary-content]),:host(c4p-preview-tearsheet) :not(.c4p--tearsheet__next__flush)::slotted([slot=influencer]){padding-inline:2rem}@media (max-width:41.98rem){.c4p--tearsheet__next__influencer:not(.c4p--tearsheet__next__flush),.c4p--tearsheet__next__main-content:not(.c4p--tearsheet__next__flush),.c4p--tearsheet__next__summary-content:not(.c4p--tearsheet__next__flush),:host :not(.c4p--tearsheet__next__flush)::slotted([slot=summary-content]),:host(c4p-preview-tearsheet) :not(.c4p--tearsheet__next__flush)::slotted([slot=influencer]){padding-inline:1rem}}.c4p--tearsheet__next__influencer:focus,.c4p--tearsheet__next__main-content:focus,.c4p--tearsheet__next__summary-content:focus,:host :focus::slotted([slot=summary-content]),:host(c4p-preview-tearsheet) :focus::slotted([slot=influencer]){outline:2px solid var(--cds-focus,#0f62fe);outline-offset:-2px}@media screen and (prefers-contrast){.c4p--tearsheet__next__influencer:focus,.c4p--tearsheet__next__main-content:focus,.c4p--tearsheet__next__summary-content:focus,:host :focus::slotted([slot=summary-content]),:host(c4p-preview-tearsheet) :focus::slotted([slot=influencer]){outline-style:dotted}}.c4p--tearsheet__next__side-panel,:host c4p-side-panel::part(dialog){block-size:100%;inline-size:100%!important;inset-block-start:0;max-inline-size:none;position:absolute;z-index:9999}.c4p--tearsheet__next__side-panel .c4p--side-panel__header,:host c4p-side-panel::part(dialog) .c4p--side-panel__header{min-block-size:0}.c4p--tearsheet__next--narrow .c4p--tearsheet__next__container{inline-size:480px;max-inline-size:480px}@media (width <= 480px){.c4p--tearsheet__next--narrow .c4p--tearsheet__next__container{inline-size:100%;max-inline-size:100%}}.c4p--tearsheet__next--narrow .c4p--tearsheet__next__header{padding-inline:1rem}.c4p--tearsheet__next--narrow .c4p--tearsheet__next__header.c4p--tearsheet__next__header-collapsed .c4p--tearsheet__next__header-actions{display:none}.c4p--tearsheet__next--narrow .c4p--tearsheet__next__header.c4p--tearsheet__next__header-collapsed .c4p--tearsheet__next__header-content{align-self:flex-start}.c4p--tearsheet__next--narrow .c4p--tearsheet__next__header-content-wrapper{display:flex;flex-direction:column}.c4p--tearsheet__next--narrow .c4p--tearsheet__next__header-title{font-size:var(--cds-heading-03-font-size,1.25rem);font-weight:var(--cds-heading-03-font-weight,400);letter-spacing:var(--cds-heading-03-letter-spacing,0);line-height:var(--cds-heading-03-line-height,1.4)}.c4p--tearsheet__next--narrow .c4p--tearsheet__next__content__header-actions{justify-content:flex-start;margin-inline-end:0}.c4p--tearsheet__next--narrow .c4p--tearsheet__next__body,:host(c4p-preview-tearsheet) .c4p--tearsheet__next--narrow ::slotted([slot=body]){grid-template-columns:1fr 0}.c4p--tearsheet__next--narrow .c4p--tearsheet__next__influencer:not(.c4p--tearsheet__next__flush),.c4p--tearsheet__next--narrow .c4p--tearsheet__next__main-content:not(.c4p--tearsheet__next__flush),.c4p--tearsheet__next--narrow .c4p--tearsheet__next__summary-content:not(.c4p--tearsheet__next__flush),:host .c4p--tearsheet__next--narrow :not(.c4p--tearsheet__next__flush)::slotted([slot=summary-content]),:host(c4p-preview-tearsheet) .c4p--tearsheet__next--narrow :not(.c4p--tearsheet__next__flush)::slotted([slot=influencer]){padding-inline:1rem}.c4p--tearsheet__next--narrow .c4p--tearsheet__next__footer,:host(c4p-preview-tearsheet) .c4p--tearsheet__next--narrow ::slotted([slot=footer]){block-size:4rem}.c4p--tearsheet__next--has-ai-label::part(dialog){background:linear-gradient(to top,var(--cds-layer),var(--cds-layer)) padding-box,linear-gradient(to bottom,var(--cds-ai-border-start,#78a9ff),var(--cds-ai-border-end,#d0e2ff)) border-box,linear-gradient(to top,var(--cds-layer),var(--cds-layer)) border-box;border:1px solid transparent!important;border-block-end:0;box-shadow:0 4px 10px 2px var(--cds-ai-drop-shadow,rgba(15,98,254,.1))}.c4p--tearsheet__next__main-content{position:relative}.c4p--tearsheet__next__main-content.c4p--tearsheet__next__flush{padding-inline:0}.c4p--tearsheet__next__main-content.c4p--tearsheet__next__main-content--no-summary{grid-column:1/-1}.c4p--tearsheet__next__main-content.c4p--tearsheet__next__main-content--has-ai-label{background:linear-gradient(to top,var(--cds-background,var(--cds-ai-popover-background,#fff)) 0,var(--cds-ai-aura-start,rgba(69,137,255,.1)) 0,15%,var(--cds-ai-aura-end,hsla(0,0%,100%,0)) 50%) padding-box,linear-gradient(to top,var(--cds-background,var(--cds-ai-popover-background,#fff)),var(--cds-background,var(--cds-ai-popover-background,#fff))) padding-box,linear-gradient(to bottom,var(--cds-ai-border-start,rgba(166,200,255,.64)),var(--cds-ai-border-end,#78a9ff)) border-box,linear-gradient(to top,var(--cds-background,var(--cds-ai-popover-background,#fff)),var(--cds-background,var(--cds-ai-popover-background,#fff))) border-box;box-shadow:inset 0 -80px 70px -65px var(--cds-ai-inner-shadow,rgba(69,137,255,.1))}:host ::slotted([slot=summary-content]:focus){outline:2px solid var(--cds-focus,#0f62fe);outline-offset:-2px}@media screen and (prefers-contrast){:host ::slotted([slot=summary-content]:focus){outline-style:dotted}}:host ::slotted([slot=summary-content][is-flush]){padding-inline:0}@media screen and (prefers-reduced-motion:reduce){:host(c4p-preview-tearsheet) ::part(dialog){align-self:flex-end;block-size:100%;border:1px solid var(--cds-border-subtle-01,#c6c6c6);inset-block-start:auto;max-block-size:calc(100% - var(--tearsheet-vertical-gap, calc(5rem + .5rem + .125rem)));transform:translate3d(0,min(95vh,500px),0);transition:none}}:host(c4p-preview-tearsheet) ::part(dialog){align-self:flex-end;block-size:100%;border:1px solid var(--cds-border-subtle-01,#c6c6c6);inset-block-start:auto;max-block-size:calc(100% - var(--tearsheet-vertical-gap, calc(5rem + .5rem + .125rem)));transform:translate3d(0,min(95vh,500px),0);transition:transform .24s cubic-bezier(0,0,.3,1),max-block-size .24s cubic-bezier(0,0,.3,1)}:host(c4p-preview-tearsheet) ::slotted([slot=influencer][is-flush]){padding-inline:0}:host(c4p-preview-tearsheet[open]) ::part(dialog){transform:translateZ(0);transition:transform .24s cubic-bezier(0,0,.3,1)}@media (prefers-reduced-motion:reduce){:host(c4p-preview-tearsheet[open]) ::part(dialog){transition:none}}@media (max-width:41.98rem){:host(:not(.c4p--tearsheet__next--stack-activated.is-visible)) ::part(dialog){max-block-size:none}}:host(c4p-preview-tearsheet.c4p--tearsheet__next--stack-activated.is-visible){--overlay-color:var(--cds-overlay,rgba(0,0,0,.6));--overlay-alpha:0.5}:host(c4p-preview-tearsheet.c4p--tearsheet__next--stack-activated.is-visible):before{background:var(--overlay-color);content:\"\";display:block;inset:0;opacity:calc(var(--overlay-alpha) - var(--stack-depth)*.1);pointer-events:none;position:fixed;transition:background-color .24s cubic-bezier(.4,.14,1,1),opacity .24s cubic-bezier(.4,.14,1,1);z-index:calc(9000 - var(--stack-depth, 0))}@media (prefers-reduced-motion:reduce){:host(c4p-preview-tearsheet.c4p--tearsheet__next--stack-activated.is-visible):before{transition:none}}:host(c4p-preview-tearsheet.c4p--tearsheet__next--stack-activated.is-visible) cds-modal{background-color:transparent}:host(c4p-preview-tearsheet.c4p--tearsheet__next--stack-activated.is-visible) ::part(dialog){max-block-size:calc(100% - var(--tearsheet-vertical-gap, calc(5rem + .5rem + .125rem)) + var(--block-size-change));transform:scaleX(var(--scale-factor))}:host(c4p-preview-tearsheet[variant=narrow]) ::part(dialog){inline-size:480px;max-inline-size:480px}@media (width <= 480px){:host(c4p-preview-tearsheet[variant=narrow]) ::part(dialog){inline-size:100%;max-inline-size:100%}}:host(c4p-preview-tearsheet[variant=narrow]) .c4p--tearsheet__next__header{padding-inline:1rem}:host(c4p-preview-tearsheet[variant=narrow]) .c4p--tearsheet__next__header.c4p--tearsheet__next__header-collapsed .c4p--tearsheet__next__header-actions{display:none}:host(c4p-preview-tearsheet[variant=narrow]) .c4p--tearsheet__next__header-content-wrapper{display:flex;flex-direction:column}:host(c4p-preview-tearsheet[variant=narrow]) .c4p--tearsheet__next__header-title{font-size:var(--cds-heading-03-font-size,1.25rem);font-weight:var(--cds-heading-03-font-weight,400);letter-spacing:var(--cds-heading-03-letter-spacing,0);line-height:var(--cds-heading-03-line-height,1.4)}:host(c4p-preview-tearsheet[variant=narrow]) .c4p--tearsheet__next__content__header-actions{justify-content:flex-start;margin-inline-end:0}:host(c4p-preview-tearsheet[variant=narrow]) .c4p--tearsheet__next__body,:host(c4p-preview-tearsheet[variant=narrow]):host(c4p-preview-tearsheet) ::slotted([slot=body]){grid-template-columns:1fr 0}:host(c4p-preview-tearsheet[variant=narrow]) ::slotted([slot=influencer]),:host(c4p-preview-tearsheet[variant=narrow]) ::slotted([slot=summary-content]){padding:0!important}@media (max-width:41.98rem){:host(c4p-preview-tearsheet) ::slotted([slot=influencer]),:host(c4p-preview-tearsheet) ::slotted([slot=summary-content]){padding:0!important}}:host-context(c4p-preview-tearsheet[variant=narrow]) ::slotted([slot=summary-content]){padding:0}:host ::slotted([slot=footer]){padding-block:0}:host-context(c4p-preview-tearsheet[variant=narrow]){display:flex;flex-direction:column}:host-context(c4p-preview-tearsheet[variant=narrow]) .c4p--tearsheet__next__header-title{font-size:var(--cds-heading-03-font-size,1.25rem);font-weight:var(--cds-heading-03-font-weight,400);letter-spacing:var(--cds-heading-03-letter-spacing,0);line-height:var(--cds-heading-03-line-height,1.4)}:host-context(c4p-preview-tearsheet[variant=narrow]) .c4p--tearsheet__next__header-actions{justify-content:flex-start;margin-inline-end:0}:host-context(c4p-preview-tearsheet[variant=narrow]):host-context(c4p-tearsheet-header[collapsed]) .c4p--tearsheet__next__header-actions{display:none}:host-context(c4p-preview-tearsheet[variant=narrow]):host-context(c4p-tearsheet-header[collapsed]) .c4p--tearsheet__next__header-content{align-self:flex-start}:host-context(c4p-preview-tearsheet[variant=narrow]) .c4p--tearsheet__next__title-start{align-items:center}:host-context(c4p-preview-tearsheet[variant=narrow]) .c4p--tearsheet__next__title-start ::slotted(*){block-size:1.5rem;inline-size:1.5rem}:host{display:grid;flex-basis:unset;gap:1rem;grid-template-columns:minmax(auto,40rem) minmax(var(--tearsheet-header-title-grid-width,0),1fr);inline-size:100%}@media (max-width:41.98rem){:host{display:flex;flex-direction:column}:host .c4p--tearsheet__next__header-actions{justify-content:flex-start;margin-inline-end:0}}.c4p--tearsheet__next__decorator{inset-block-start:.625rem;inset-inline-end:3rem;position:absolute;transition:inset-block-start .24s cubic-bezier(0,0,.3,1);z-index:1}:host-context(c4p-tearsheet-header[collapsed]) .c4p--tearsheet__next__decorator{inset-block-start:.5rem}.c4p--tearsheet__next__close-button{inset-block-start:0;inset-inline-end:0;position:absolute;z-index:1}.c4p--tearsheet__next__close-button .cds--modal-close{transition:all .24s ease}.c4p--tearsheet__next__header-actions{display:flex;justify-content:flex-end;margin-block-start:-14px;order:2}@media (max-width:41.98rem){.c4p--tearsheet__next__header-actions{order:0}}.c4p--tearsheet__next__header-content{order:1}@media (max-width:41.98rem){.c4p--tearsheet__next__header-content{order:0}}:host .c4p--tearsheet__next__header-actions,:host .c4p--tearsheet__next__header-content :not(.c4p--tearsheet__next__content__title-wrapper,.c4p--tearsheet__next__header-label){opacity:1;transition:all .24s cubic-bezier(0,0,.3,1),opacity .24s cubic-bezier(0,0,.3,1)}:host-context(c4p-tearsheet-header[collapsed]) .c4p--tearsheet__next__header-actions>:not(.c4p--tearsheet__next__content__header-actions){margin:0;max-block-size:0;opacity:0;overflow:hidden;padding:0;pointer-events:none;transition:all .24s cubic-bezier(0,0,.3,1)}:host-context(c4p-tearsheet-header[collapsed]) .c4p--tearsheet__next__header-content>:not(.c4p--tearsheet__next__content__title-wrapper){margin:0;max-block-size:0;opacity:0;overflow:hidden;padding:0;pointer-events:none;transition:all .24s cubic-bezier(0,0,.3,1)}:host-context(c4p-tearsheet-header[collapsed]) .c4p--tearsheet__next__header-content>:not(.c4p--tearsheet__next__content__title-wrapper) *{margin:0;max-block-size:0;opacity:0;overflow:hidden;padding:0;pointer-events:none;transition:all .24s cubic-bezier(0,0,.3,1)}:host-context(c4p-tearsheet-header[collapsed]) .c4p--tearsheet__next__header-title{align-items:center;block-size:2.5rem;font-size:var(--cds-label-02-font-size,.875rem);font-weight:var(--cds-label-02-font-weight,400);gap:.5rem;letter-spacing:var(--cds-label-02-letter-spacing,.16px);line-height:var(--cds-label-02-line-height,1.28572);margin-block-start:.25rem;transition:all .24s cubic-bezier(0,0,.3,1)}:host-context(c4p-tearsheet-header[collapsed]) .c4p--tearsheet__next__header-title>span{align-items:center;block-size:1.5rem;display:flex}:host-context(c4p-tearsheet-header[collapsed]) .c4p--tearsheet__next__header-content{align-self:center;margin-block-end:0}:host-context(c4p-tearsheet-header[collapsed]) .c4p--tearsheet__next__content__title-wrapper,:host-context(c4p-tearsheet-header[collapsed]) .c4p--tearsheet__next__header-content,:host-context(c4p-tearsheet-header[collapsed]) .c4p--tearsheet__next__header-title{margin-block:0;transition:margin-block .24s ease}@media (max-width:41.98rem){:host-context(c4p-tearsheet-header[collapsed]) .c4p--tearsheet__next__header-actions{display:none}}@media (min-width:42rem){:host-context(c4p-tearsheet-header[collapsed]) .c4p--tearsheet__next__header-actions{align-items:center;display:flex;margin-block:0;transition:margin-block .24s ease}}:host-context(c4p-tearsheet-header[collapsed]) .c4p--tearsheet__next__title-start{align-items:center;display:inline-flex}:host-context(c4p-tearsheet-header[collapsed]) .c4p--tearsheet__next__title-start ::slotted(*){block-size:1rem;inline-size:1rem}@media screen and (prefers-reduced-motion:reduce){.c4p--tearsheet__next__title-start ::slotted(*){transition:none}}.c4p--tearsheet__next__title-start ::slotted(*){transition:all .24s cubic-bezier(0,0,.3,1)}:host-context(c4p-preview-tearsheet:not([open])) .c4p--tearsheet__next__header-actions,:host-context(c4p-preview-tearsheet:not([open])) .c4p--tearsheet__next__header-content,:host-context(c4p-preview-tearsheet:not([open])) .c4p--tearsheet__next__header-content *{opacity:0;transition:opacity .1s ease-out}"]);
11
11
  //#endregion
12
12
  export { tearsheet_header_content_default as default };
13
13
 
@@ -1 +1 @@
1
- {"version":3,"file":"tearsheet-header-content.scss.js","names":[],"sources":["../../../src/components/tearsheet-preview/tearsheet-header-content.scss?lit"],"sourcesContent":["/**\n * @license\n *\n * Copyright IBM Corp. 2026\n *\n * This source code is licensed under the Apache-2.0 license found in the\n * LICENSE file in the root directory of this source tree.\n */\n@use '@carbon/styles/scss/breakpoint' as *;\n@use '@carbon/ibm-products-styles/scss/config';\n@use '@carbon/styles/scss/motion' as *;\n@use '@carbon/styles/scss/spacing' as *;\n@use '@carbon/styles/scss/type';\n@use './tearsheet.scss' as *;\n\n$prefix: config.$pkg-prefix;\n$carbon-prefix: config.$carbon-prefix;\n$block-class__next: #{$prefix}--tearsheet__next;\n$motion-duration: $duration-moderate-02;\n// Narrow variant styles\n:host-context(#{$c4p-prefix}-preview-tearsheet[variant='narrow']) {\n display: flex;\n flex-direction: column;\n\n .#{$block-class__next}__header-title {\n @include type.type-style('heading-03');\n }\n\n .#{$block-class__next}__header-actions {\n justify-content: flex-start;\n margin-inline-end: 0;\n }\n}\n\n// Hide header actions when collapsed in narrow variant\n:host-context(#{$c4p-prefix}-preview-tearsheet[variant='narrow']) {\n &:host-context(#{$c4p-prefix}-tearsheet-header[collapsed]) {\n .#{$block-class__next}__header-actions {\n display: none;\n }\n .#{$block-class__next}__header-content {\n align-self: flex-start;\n }\n }\n .#{$block-class__next}__title-start {\n align-items: center;\n\n ::slotted(*) {\n block-size: $spacing-06;\n inline-size: $spacing-06;\n }\n }\n}\n\n:host {\n display: grid;\n flex-basis: unset;\n gap: $spacing-05;\n grid-template-columns: minmax(auto, 40rem) minmax(\n var(--tearsheet-header-title-grid-width, 0),\n 1fr\n );\n\n inline-size: calc(100% - var(--tearsheet-header-action-offset));\n\n @include breakpoint-down(md) {\n display: flex;\n flex-direction: column;\n\n .#{$block-class__next}__header-actions {\n justify-content: flex-start;\n margin-inline-end: 0;\n }\n }\n}\n.#{$block-class__next}__header-actions {\n display: flex;\n justify-content: flex-end;\n order: 2; /* Visual order: appears on the right on desktop */\n margin-block-start: -14px;\n\n @include breakpoint-down(md) {\n order: 0; /* Reset to DOM order on mobile (header-actions first) */\n }\n}\n\n.#{$block-class__next}__header-content {\n order: 1; /* Visual order: appears on the left on desktop */\n\n @include breakpoint-down(md) {\n order: 0; /* Reset to DOM order on mobile (header-content second) */\n }\n}\n\n:host {\n .#{$block-class__next}__header-actions,\n .#{$block-class__next}__header-content\n *:not(\n .#{$block-class__next}__content__title-wrapper,\n .#{$block-class__next}__header-label\n ) {\n opacity: 1;\n transition:\n all $motion-duration motion(entrance, expressive),\n opacity $motion-duration motion(entrance, expressive);\n }\n}\n\n// ──────────────────────────────────────────────────────────────\n// Collapsed Header State\n// ──────────────────────────────────────────────────────────────\n:host-context(#{$c4p-prefix}-tearsheet-header[collapsed]) {\n // Collapse header actions except the main action button\n .#{$block-class__next}__header-actions\n > *:not(.#{$block-class__next}__content__header-actions) {\n @include collapsed-element;\n }\n\n // Collapse all header content except title wrapper\n .#{$block-class__next}__header-content\n > *:not(.#{$block-class__next}__content__title-wrapper) {\n @include collapsed-element;\n }\n\n // Collapse nested elements within non-title elements\n .#{$block-class__next}__header-content\n > *:not(.#{$block-class__next}__content__title-wrapper)\n * {\n @include collapsed-element;\n }\n\n // Header title styling when collapsed\n .#{$block-class__next}__header-title {\n @include type.type-style('label-02');\n\n align-items: center;\n margin-block-start: $spacing-02;\n transition: all $motion-duration motion(entrance, expressive);\n\n > span {\n display: flex;\n align-items: center;\n block-size: $spacing-06;\n }\n }\n\n // Header content alignment\n .#{$block-class__next}__header-content {\n align-self: center;\n margin-block-end: 0;\n }\n\n // Hide header actions on small screens when collapsed\n @include breakpoint-down(md) {\n .#{$block-class__next}__header-actions {\n display: none;\n }\n }\n\n // Normalize visible elements\n .#{$block-class__next}__header-content,\n .#{$block-class__next}__content__title-wrapper,\n .#{$block-class__next}__header-actions,\n .#{$block-class__next}__header-title {\n margin-block: 0;\n transition: margin-block $motion-duration ease;\n }\n // Header actions adjustment\n .#{$block-class__next}__header-actions {\n margin-block-start: -$spacing-01;\n }\n // Style for title-start slot content (like icons)\n .#{$block-class__next}__title-start {\n display: inline-flex;\n align-items: center;\n\n ::slotted(*) {\n block-size: $spacing-05;\n inline-size: $spacing-05;\n }\n }\n}\n.#{$block-class__next}__title-start {\n @media screen and (prefers-reduced-motion: reduce) {\n ::slotted(*) {\n transition: none;\n }\n }\n\n ::slotted(*) {\n transition: all $motion-duration motion(entrance, expressive);\n }\n}\n\n// Hide header content elements immediately when tearsheet is closing\n:host-context(#{$c4p-prefix}-preview-tearsheet:not([open])) {\n .#{$block-class__next}__header-actions,\n .#{$block-class__next}__header-content,\n .#{$block-class__next}__header-content * {\n opacity: 0;\n transition: opacity 0.1s ease-out;\n }\n}\n"],"mappings":""}
1
+ {"version":3,"file":"tearsheet-header-content.scss.js","names":[],"sources":["../../../src/components/tearsheet-preview/tearsheet-header-content.scss?lit"],"sourcesContent":["/**\n * @license\n *\n * Copyright IBM Corp. 2026\n *\n * This source code is licensed under the Apache-2.0 license found in the\n * LICENSE file in the root directory of this source tree.\n */\n@use '@carbon/styles/scss/breakpoint' as *;\n@use '@carbon/ibm-products-styles/scss/config';\n@use '@carbon/styles/scss/motion' as *;\n@use '@carbon/styles/scss/spacing' as *;\n@use '@carbon/styles/scss/type';\n@use '@carbon/layout/scss/convert';\n@use './tearsheet.scss' as *;\n\n$prefix: config.$pkg-prefix;\n$carbon-prefix: config.$carbon-prefix;\n$block-class__next: #{$prefix}--tearsheet__next;\n$motion-duration: $duration-moderate-02;\n// Narrow variant styles\n:host-context(#{$c4p-prefix}-preview-tearsheet[variant='narrow']) {\n display: flex;\n flex-direction: column;\n\n .#{$block-class__next}__header-title {\n @include type.type-style('heading-03');\n }\n\n .#{$block-class__next}__header-actions {\n justify-content: flex-start;\n margin-inline-end: 0;\n }\n}\n\n// Hide header actions when collapsed in narrow variant\n:host-context(#{$c4p-prefix}-preview-tearsheet[variant='narrow']) {\n &:host-context(#{$c4p-prefix}-tearsheet-header[collapsed]) {\n .#{$block-class__next}__header-actions {\n display: none;\n }\n .#{$block-class__next}__header-content {\n align-self: flex-start;\n }\n }\n .#{$block-class__next}__title-start {\n align-items: center;\n\n ::slotted(*) {\n block-size: $spacing-06;\n inline-size: $spacing-06;\n }\n }\n}\n\n:host {\n // Grid hosts header-content (col 1) and header-actions (col 2).\n // Decorator and close button are absolutely positioned top-right,\n // placed early in DOM order for correct keyboard tab sequence.\n display: grid;\n flex-basis: unset;\n gap: $spacing-05;\n grid-template-columns: minmax(auto, 40rem) minmax(\n var(--tearsheet-header-title-grid-width, 0),\n 1fr\n );\n\n inline-size: 100%; // full width — close/decorator are abs-positioned, no offset needed\n\n @include breakpoint-down(md) {\n display: flex;\n flex-direction: column;\n\n .#{$block-class__next}__header-actions {\n justify-content: flex-start;\n margin-inline-end: 0;\n }\n }\n}\n\n// ── Decorator (AI label) ─────────────────────────────────────────\n// DOM position: 2nd (after header-actions, before close, before header-content)\n// Visual position: absolute top-right (matches React TearsheetNext)\n.#{$block-class__next}__decorator {\n position: absolute;\n z-index: 1;\n inset-block-start: convert.to-rem(10px);\n inset-inline-end: $spacing-09;\n // Transition on base state so it animates in both directions (expand + collapse)\n transition: inset-block-start $motion-duration motion(entrance, expressive);\n\n // When header is collapsed, shift slightly down — matches React\n :host-context(#{$c4p-prefix}-tearsheet-header[collapsed]) & {\n inset-block-start: $spacing-03;\n }\n}\n\n// ── Close button ─────────────────────────────────────────────────\n// DOM position: 3rd (after decorator, before header-content)\n// Visual position: absolute top-right corner — stays absolute on ALL screen sizes\n.#{$block-class__next}__close-button {\n position: absolute;\n z-index: 1;\n inset-block-start: 0;\n inset-inline-end: 0;\n\n // Animate size change (lg → md on collapse) — matches React\n .#{$carbon-prefix}--modal-close {\n transition: all $motion-duration ease;\n }\n}\n\n.#{$block-class__next}__header-actions {\n display: flex;\n justify-content: flex-end;\n order: 2; /* Visual order: appears on the right on desktop */\n margin-block-start: -14px;\n\n @include breakpoint-down(md) {\n order: 0; /* Reset to DOM order on mobile (header-actions first) */\n }\n}\n\n.#{$block-class__next}__header-content {\n order: 1; /* Visual order: appears on the left on desktop */\n\n @include breakpoint-down(md) {\n order: 0; /* Reset to DOM order on mobile (header-content second) */\n }\n}\n\n:host {\n .#{$block-class__next}__header-actions,\n .#{$block-class__next}__header-content\n *:not(\n .#{$block-class__next}__content__title-wrapper,\n .#{$block-class__next}__header-label\n ) {\n opacity: 1;\n transition:\n all $motion-duration motion(entrance, expressive),\n opacity $motion-duration motion(entrance, expressive);\n }\n}\n\n// ──────────────────────────────────────────────────────────────\n// Collapsed Header State\n// ──────────────────────────────────────────────────────────────\n:host-context(#{$c4p-prefix}-tearsheet-header[collapsed]) {\n // Collapse header actions except the main action button\n .#{$block-class__next}__header-actions\n > *:not(.#{$block-class__next}__content__header-actions) {\n @include collapsed-element;\n }\n\n // Collapse all header content except title wrapper\n .#{$block-class__next}__header-content\n > *:not(.#{$block-class__next}__content__title-wrapper) {\n @include collapsed-element;\n }\n\n // Collapse nested elements within non-title elements\n .#{$block-class__next}__header-content\n > *:not(.#{$block-class__next}__content__title-wrapper)\n * {\n @include collapsed-element;\n }\n\n // Header title styling when collapsed\n .#{$block-class__next}__header-title {\n @include type.type-style('label-02');\n\n align-items: center;\n // Fixed block-size keeps the title row at the same height as the close button\n block-size: $spacing-08;\n // Gap between title-start icon and title text when collapsed\n gap: $spacing-03;\n margin-block-start: $spacing-02;\n transition: all $motion-duration motion(entrance, expressive);\n\n > span {\n display: flex;\n align-items: center;\n block-size: $spacing-06;\n }\n }\n\n // Header content alignment\n .#{$block-class__next}__header-content {\n align-self: center;\n margin-block-end: 0;\n }\n\n // Hide header actions on small screens when collapsed\n // Normalize visible elements\n .#{$block-class__next}__header-content,\n .#{$block-class__next}__content__title-wrapper,\n .#{$block-class__next}__header-title {\n margin-block: 0;\n transition: margin-block $motion-duration ease;\n }\n\n @include breakpoint-down(md) {\n .#{$block-class__next}__header-actions {\n display: none;\n }\n }\n\n @include breakpoint(md) {\n .#{$block-class__next}__header-actions {\n display: flex;\n align-items: center;\n margin-block: 0;\n transition: margin-block $motion-duration ease;\n }\n }\n // Header actions adjustment — removed negative offset that caused misalignment\n // Style for title-start slot content (like icons)\n .#{$block-class__next}__title-start {\n display: inline-flex;\n align-items: center;\n\n ::slotted(*) {\n block-size: $spacing-05;\n inline-size: $spacing-05;\n }\n }\n}\n.#{$block-class__next}__title-start {\n @media screen and (prefers-reduced-motion: reduce) {\n ::slotted(*) {\n transition: none;\n }\n }\n\n ::slotted(*) {\n transition: all $motion-duration motion(entrance, expressive);\n }\n}\n\n// Hide header content elements immediately when tearsheet is closing\n:host-context(#{$c4p-prefix}-preview-tearsheet:not([open])) {\n .#{$block-class__next}__header-actions,\n .#{$block-class__next}__header-content,\n .#{$block-class__next}__header-content * {\n opacity: 0;\n transition: opacity 0.1s ease-out;\n }\n}\n"],"mappings":""}
@@ -24,13 +24,15 @@ declare const CDSTearsheetHeader_base: {
24
24
  } & typeof LitElement & (new (...args: any[]) => import("@lit-labs/signals").SignalWatcherApi);
25
25
  /**
26
26
  * Tearsheet Header component - Contains the header section with title, description, and actions.
27
+ * The decorator (AI label) and close button are now rendered inside c4p-tearsheet-header-content
28
+ * to achieve the correct DOM tab order: header-actions → decorator → close → header-content.
27
29
  *
28
30
  * @element c4p-tearsheet-header
29
31
  * @slot header-content - The main header content area (use c4p-tearsheet-header-content)
30
- * @slot header-navigation - Navigation tabs or breadcrumbs below the header
31
- * @slot header-actions - Action buttons in the header (e.g., settings, delete)
32
- * @slot decorator - AI label or other decorative elements
33
- * @fires c4p-tearsheet-header-close-button-clicked - Internal event to notify parent tearsheet
32
+ * @slot - Default slot for other content
33
+ * @slot navigation-bar - Navigation tabs or breadcrumbs below the header
34
+ * @fires c4p-tearsheet-header-collapse-change - Internal event; parent tearsheet re-dispatches
35
+ * this as the public `c4p-preview-tearsheet-collapse-change` event.
34
36
  */
35
37
  declare class CDSTearsheetHeader extends CDSTearsheetHeader_base {
36
38
  slot: string;
@@ -46,25 +48,19 @@ declare class CDSTearsheetHeader extends CDSTearsheetHeader_base {
46
48
  * Default header collapse/expand while scrolling the main content can be disabled by setting this
47
49
  */
48
50
  disableHeaderCollapse: boolean;
49
- _hasDecorator: boolean;
50
- _hasAILabel: boolean;
51
- private decoratorSlot;
52
- /**
53
- * Handles user-initiated close request of this tearsheet.
54
- * Dispatches an internal event to notify the parent tearsheet to close.
55
- *
56
- * @param triggeredBy The element that triggered this close request.
57
- */
58
- private _handleUserInitiatedClose;
59
51
  connectedCallback(): void;
60
52
  protected firstUpdated(): void;
61
53
  protected updated(_changedProperties: PropertyValues): void;
62
54
  private updateCollapsedAttribute;
63
- private updateHeaderOffset;
64
- private _handleDecoratorChange;
65
55
  render(): import("lit-html").TemplateResult<1>;
66
56
  static styles: any;
67
57
  static get eventCloseButtonClicked(): string;
58
+ /**
59
+ * Internal event fired when the collapse state changes.
60
+ * The parent `c4p-preview-tearsheet` intercepts this and re-dispatches it as
61
+ * the public `c4p-preview-tearsheet-collapse-change` event.
62
+ */
63
+ static get eventCollapseChange(): string;
68
64
  }
69
65
  export default CDSTearsheetHeader;
70
66
  //# sourceMappingURL=tearsheet-header.d.ts.map