@salesforcedevs/dx-components 1.3.199-wires-update1 → 1.3.199-wires-update2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,10 +1,10 @@
1
1
  {
2
2
  "name": "@salesforcedevs/dx-components",
3
- "version": "1.3.199-wires-update1",
3
+ "version": "1.3.199-wires-update2",
4
4
  "description": "DX Lightning web components",
5
5
  "license": "MIT",
6
6
  "engines": {
7
- "node": "16.x"
7
+ "node": ">=16.x"
8
8
  },
9
9
  "publishConfig": {
10
10
  "access": "public"
@@ -40,5 +40,8 @@
40
40
  "@types/vimeo__player": "^2.16.2",
41
41
  "eventsourcemock": "^2.0.0",
42
42
  "luxon": "^3.1.0"
43
+ },
44
+ "volta": {
45
+ "node": "16.19.1"
43
46
  }
44
47
  }
@@ -26,9 +26,6 @@ prism.languages.gtl = prism.languages.extend(
26
26
  prism.languages.handlebars
27
27
  );
28
28
 
29
- // LWC
30
- prism.languages.lwc = prism.languages.extend("jsx");
31
-
32
29
  // Used for remove enclosing <pre> tag's (if occurs)
33
30
  const preTagRegexp: RegExp = /^<pre.*?>(.*)<\/pre>$/is;
34
31
 
@@ -83,8 +80,7 @@ export default class CodeBlock extends LightningElement {
83
80
  { label: "DataWeave", id: "dataweave" },
84
81
  { label: "AMPScript", id: "ampscript" },
85
82
  { label: "SSJS", id: "ssjs" },
86
- { label: "GTL", id: "gtl" },
87
- { label: "LWC", id: "lwc" }
83
+ { label: "GTL", id: "gtl" }
88
84
  ];
89
85
 
90
86
  connectedCallback() {
@@ -98,10 +94,9 @@ export default class CodeBlock extends LightningElement {
98
94
  set codeBlock(value: string) {
99
95
  this._codeBlockRendered = false;
100
96
  let match;
101
- this._codeBlock = (
102
- (match = preTagRegexp.exec(value.trim())) === null
103
- ? value.trim()
104
- : match[1]
97
+ this._codeBlock = ((match = preTagRegexp.exec(value.trim())) === null
98
+ ? value.trim()
99
+ : match[1]
105
100
  ).trim();
106
101
  }
107
102
 
@@ -248,8 +243,9 @@ export default class CodeBlock extends LightningElement {
248
243
  });
249
244
 
250
245
  try {
251
- const snippetContainer: HTMLElement | null =
252
- this.template.querySelector(".code-block-content");
246
+ const snippetContainer: HTMLElement | null = this.template.querySelector(
247
+ ".code-block-content"
248
+ );
253
249
  if (snippetContainer && snippetContainer.textContent) {
254
250
  await navigator.clipboard.writeText(
255
251
  snippetContainer.textContent
@@ -96,12 +96,6 @@
96
96
  );
97
97
  }
98
98
 
99
- .cta-inline {
100
- display: flex;
101
- justify-content: space-between;
102
- max-width: unset;
103
- }
104
-
105
99
  /* sections with a swoop and center alignment should not left align as it encroaches on the graphic */
106
100
  .section.align-center.graphic-top .text {
107
101
  text-align: center;
@@ -2,7 +2,7 @@
2
2
  <div class={className} style={style} part="container">
3
3
  <svg
4
4
  class="background-graphic background-graphic-top"
5
- lwc:if={topGraphic}
5
+ if:true={topGraphic}
6
6
  preserveAspectRatio="none"
7
7
  width="1438px"
8
8
  height="83px"
@@ -26,38 +26,21 @@
26
26
  </g>
27
27
  </svg>
28
28
 
29
- <div part="text" class="text" lwc:if={hasText}>
30
- <span class="label dx-text-display-8" lwc:if={label}>{label}</span>
31
- <h2 class={headingClassName} lwc:if={title}>
32
- {title}
33
- <template lwc:if={ctaBtnInline}>
34
- <dx-button
35
- class="cta"
36
- lwc:if={ctaLabel}
37
- href={ctaHref}
38
- variant={ctaBtnVariant}
39
- icon-symbol={ctaBtnSymbol}
40
- target={ctaBtnTarget}
41
- onclick={handleLabelClick}
42
- >
43
- {ctaLabel}
44
- </dx-button>
45
- </template>
46
- </h2>
47
- <span class={subtitleClassName} lwc:if={subtitle}>{subtitle}</span>
48
- <template lwc:if={ctaNotInline}>
49
- <dx-button
50
- class="cta"
51
- lwc:if={ctaLabel}
52
- href={ctaHref}
53
- variant={ctaBtnVariant}
54
- icon-symbol={ctaBtnSymbol}
55
- target={ctaBtnTarget}
56
- onclick={handleLabelClick}
57
- >
58
- {ctaLabel}
59
- </dx-button>
60
- </template>
29
+ <div part="text" class="text" if:true={hasText}>
30
+ <span class="label dx-text-display-8" if:true={label}>{label}</span>
31
+ <h2 class={headingClassName} if:true={title}>{title}</h2>
32
+ <span class={subtitleClassName} if:true={subtitle}>{subtitle}</span>
33
+ <dx-button
34
+ class="cta"
35
+ if:true={ctaLabel}
36
+ href={ctaHref}
37
+ variant={ctaBtnVariant}
38
+ icon-symbol={ctaBtnSymbol}
39
+ target={ctaBtnTarget}
40
+ onclick={handleLabelClick}
41
+ >
42
+ {ctaLabel}
43
+ </dx-button>
61
44
  </div>
62
45
  <div part="content" class="content">
63
46
  <slot></slot>
@@ -65,7 +48,7 @@
65
48
 
66
49
  <svg
67
50
  class="background-graphic background-graphic-bottom"
68
- lwc:if={bottomGraphic}
51
+ if:true={bottomGraphic}
69
52
  preserveAspectRatio="none"
70
53
  width="1438px"
71
54
  height="83px"
@@ -17,7 +17,6 @@ export default class Section extends LightningElement {
17
17
  @api ctaBtnVariant?: string;
18
18
  @api ctaBtnSymbol?: string;
19
19
  @api ctaBtnTarget?: string = "_self";
20
- @api ctaBtnInline?: boolean = false;
21
20
  @api topGraphic: boolean = false;
22
21
  @api graphicOverlap: boolean = false;
23
22
  @api bottomGraphic: boolean = false;
@@ -44,21 +43,13 @@ export default class Section extends LightningElement {
44
43
  }
45
44
 
46
45
  private get headingClassName() {
47
- return cx(
48
- "heading",
49
- `dx-text-display-${this.headingLevel}`,
50
- this.ctaBtnInline && "cta-inline"
51
- );
46
+ return cx("heading", `dx-text-display-${this.headingLevel}`);
52
47
  }
53
48
 
54
49
  private get hasText(): boolean {
55
50
  return !!(this.title || this.label || this.subtitle);
56
51
  }
57
52
 
58
- private get ctaNotInline(): boolean {
59
- return !this.ctaBtnInline;
60
- }
61
-
62
53
  private handleLabelClick(e: Event) {
63
54
  track(e.target!, "custEv_ctaLinkClick", {
64
55
  click_text: this.ctaLabel,