@ptcwebops/ptcw-design 3.0.2 → 3.0.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (111) hide show
  1. package/dist/cjs/embedded-form.cjs.entry.js +108 -0
  2. package/dist/cjs/footer-form.cjs.entry.js +1 -1
  3. package/dist/cjs/loader.cjs.js +1 -1
  4. package/dist/cjs/max-width-container.cjs.entry.js +54 -0
  5. package/dist/cjs/ptc-button.cjs.entry.js +52 -0
  6. package/dist/cjs/ptc-data-lookup.cjs.entry.js +496 -0
  7. package/dist/cjs/{embedded-form_9.cjs.entry.js → ptc-form-checkbox_3.cjs.entry.js} +12 -804
  8. package/dist/cjs/ptc-form.cjs.entry.js +1 -1
  9. package/dist/cjs/ptc-modal-quiz.cjs.entry.js +1 -1
  10. package/dist/cjs/ptc-pricing-packaging-table.cjs.entry.js +7 -5
  11. package/dist/cjs/ptc-quote.cjs.entry.js +3 -2
  12. package/dist/cjs/ptc-spacer.cjs.entry.js +38 -0
  13. package/dist/cjs/ptc-title.cjs.entry.js +78 -0
  14. package/dist/cjs/ptc-value-led-card.cjs.entry.js +21 -0
  15. package/dist/cjs/ptc-value-led-content-highlight.cjs.entry.js +19 -0
  16. package/dist/cjs/ptc-value-led-content.cjs.entry.js +19 -0
  17. package/dist/cjs/ptc-value-led-intro.cjs.entry.js +20 -0
  18. package/dist/cjs/ptc-value-led-layout.cjs.entry.js +2 -2
  19. package/dist/cjs/ptc-value-led-speed-bump.cjs.entry.js +32 -0
  20. package/dist/cjs/ptcw-design.cjs.js +1 -1
  21. package/dist/collection/collection-manifest.json +5 -1
  22. package/dist/collection/components/organism-bundles/form/embedded-form/embedded-form.js +1 -1
  23. package/dist/collection/components/organism-bundles/form/footer-form/footer-form.js +1 -1
  24. package/dist/collection/components/organism-bundles/form/ptc-form/ptc-form.js +1 -1
  25. package/dist/collection/components/ptc-button/ptc-button.css +42 -0
  26. package/dist/collection/components/ptc-button/ptc-button.js +20 -1
  27. package/dist/collection/components/ptc-modal-quiz/ptc-modal-quiz.css +6 -1
  28. package/dist/collection/components/ptc-pricing-packaging-table/ptc-pricing-packaging-table.js +7 -5
  29. package/dist/collection/components/ptc-quote/ptc-quote.css +28 -0
  30. package/dist/collection/components/ptc-quote/ptc-quote.js +4 -3
  31. package/dist/collection/components/ptc-select/ptc-select.js +4 -4
  32. package/dist/collection/components/ptc-textfield/ptc-textfield.js +12 -16
  33. package/dist/collection/components/ptc-value-led-card/ptc-value-led-card.css +36 -0
  34. package/dist/collection/components/ptc-value-led-card/ptc-value-led-card.js +60 -0
  35. package/dist/collection/components/ptc-value-led-content/ptc-value-led-content.css +12 -0
  36. package/dist/collection/components/ptc-value-led-content/ptc-value-led-content.js +18 -0
  37. package/dist/collection/components/ptc-value-led-content-highlight/ptc-value-led-content-highlight.css +31 -0
  38. package/dist/collection/components/ptc-value-led-content-highlight/ptc-value-led-content-highlight.js +18 -0
  39. package/dist/collection/components/ptc-value-led-intro/ptc-value-led-intro.css +16 -0
  40. package/dist/collection/components/ptc-value-led-intro/ptc-value-led-intro.js +42 -0
  41. package/dist/collection/components/ptc-value-led-layout/ptc-value-led-layout.css +22 -3
  42. package/dist/collection/components/ptc-value-led-layout/ptc-value-led-layout.js +1 -1
  43. package/dist/collection/components/ptc-value-led-speed-bump/ptc-value-led-speed-bump.css +63 -0
  44. package/dist/collection/components/ptc-value-led-speed-bump/ptc-value-led-speed-bump.js +97 -0
  45. package/dist/custom-elements/index.d.ts +30 -6
  46. package/dist/custom-elements/index.js +131 -568
  47. package/dist/esm/embedded-form.entry.js +104 -0
  48. package/dist/esm/footer-form.entry.js +1 -1
  49. package/dist/esm/loader.js +1 -1
  50. package/dist/esm/max-width-container.entry.js +50 -0
  51. package/dist/esm/ptc-button.entry.js +48 -0
  52. package/dist/esm/ptc-data-lookup.entry.js +492 -0
  53. package/dist/esm/{embedded-form_9.entry.js → ptc-form-checkbox_3.entry.js} +14 -800
  54. package/dist/esm/ptc-form.entry.js +1 -1
  55. package/dist/esm/ptc-modal-quiz.entry.js +1 -1
  56. package/dist/esm/ptc-pricing-packaging-table.entry.js +7 -5
  57. package/dist/esm/ptc-quote.entry.js +3 -2
  58. package/dist/esm/ptc-spacer.entry.js +34 -0
  59. package/dist/esm/ptc-title.entry.js +74 -0
  60. package/dist/esm/ptc-value-led-card.entry.js +17 -0
  61. package/dist/esm/ptc-value-led-content-highlight.entry.js +15 -0
  62. package/dist/esm/ptc-value-led-content.entry.js +15 -0
  63. package/dist/esm/ptc-value-led-intro.entry.js +16 -0
  64. package/dist/esm/ptc-value-led-layout.entry.js +2 -2
  65. package/dist/esm/ptc-value-led-speed-bump.entry.js +28 -0
  66. package/dist/esm/ptcw-design.js +1 -1
  67. package/dist/ptcw-design/p-036234e7.entry.js +1 -0
  68. package/dist/ptcw-design/{p-ed2cc9da.entry.js → p-08ed517e.entry.js} +1 -1
  69. package/dist/ptcw-design/p-137ddeeb.entry.js +1 -0
  70. package/dist/ptcw-design/p-18dfffd3.entry.js +359 -0
  71. package/dist/ptcw-design/p-236073e1.entry.js +1 -0
  72. package/dist/ptcw-design/p-2e4af711.entry.js +1 -0
  73. package/dist/ptcw-design/p-33c054ff.entry.js +1 -0
  74. package/dist/ptcw-design/{p-f00b4b73.entry.js → p-3ca391ab.entry.js} +1 -1
  75. package/dist/ptcw-design/p-3faffecb.entry.js +1 -0
  76. package/dist/ptcw-design/p-49f06645.entry.js +1 -0
  77. package/dist/ptcw-design/p-641bd525.entry.js +1 -0
  78. package/dist/ptcw-design/p-752f779c.entry.js +1 -0
  79. package/dist/ptcw-design/p-7aa6b7e5.entry.js +1 -0
  80. package/dist/ptcw-design/p-7c079ff8.entry.js +1 -0
  81. package/dist/ptcw-design/p-92bbd407.entry.js +1 -0
  82. package/dist/ptcw-design/p-9a36f7a3.entry.js +1 -0
  83. package/dist/ptcw-design/p-d2c400e2.entry.js +1 -0
  84. package/dist/ptcw-design/p-f1c77113.entry.js +1 -0
  85. package/dist/ptcw-design/ptcw-design.css +2 -2
  86. package/dist/ptcw-design/ptcw-design.esm.js +1 -1
  87. package/dist/types/components/ptc-button/ptc-button.d.ts +4 -0
  88. package/dist/types/components/ptc-pricing-packaging-table/ptc-pricing-packaging-table.d.ts +2 -0
  89. package/dist/types/components/ptc-quote/ptc-quote.d.ts +1 -1
  90. package/dist/types/components/ptc-select/ptc-select.d.ts +1 -1
  91. package/dist/types/components/ptc-textfield/ptc-textfield.d.ts +1 -1
  92. package/dist/types/components/ptc-value-led-card/ptc-value-led-card.d.ts +5 -0
  93. package/dist/types/components/ptc-value-led-content/ptc-value-led-content.d.ts +3 -0
  94. package/dist/types/components/ptc-value-led-content-highlight/ptc-value-led-content-highlight.d.ts +3 -0
  95. package/dist/types/components/ptc-value-led-intro/ptc-value-led-intro.d.ts +4 -0
  96. package/dist/types/components/ptc-value-led-speed-bump/ptc-value-led-speed-bump.d.ts +10 -0
  97. package/dist/types/components.d.ts +91 -75
  98. package/package.json +1 -1
  99. package/readme.md +1 -1
  100. package/dist/cjs/ptc-pricing-table.cjs.entry.js +0 -536
  101. package/dist/collection/components/ptc-pricing-table/ptc-pricing-table.css +0 -278
  102. package/dist/collection/components/ptc-pricing-table/ptc-pricing-table.js +0 -680
  103. package/dist/esm/ptc-pricing-table.entry.js +0 -532
  104. package/dist/ptcw-design/p-220f86c0.entry.js +0 -1
  105. package/dist/ptcw-design/p-4a865061.entry.js +0 -1
  106. package/dist/ptcw-design/p-b0b4ebd6.entry.js +0 -359
  107. package/dist/ptcw-design/p-c20538ec.entry.js +0 -1
  108. package/dist/ptcw-design/p-f2621425.entry.js +0 -1
  109. package/dist/ptcw-design/p-f29c71fe.entry.js +0 -1
  110. package/dist/types/components/ptc-pricing-table/ptc-pricing-table.d.ts +0 -110
  111. package/dist/types/utils/eloqua.d.ts +0 -8
@@ -1,532 +0,0 @@
1
- import { r as registerInstance, h, F as Fragment, H as Host, g as getElement } from './index-62587d0b.js';
2
-
3
- const ptcPricingTableCss = ":host{display:block;position:relative}:host #vertical-scroll-content-clipper{position:fixed;top:0;left:0;right:0;margin:auto;background-color:white;z-index:25;display:none}:host .last-column-tooltip .tooltip{right:-48px}:host #sticky-header-container{position:fixed;z-index:20;background-color:white;overflow-x:scroll;overflow-y:visible;-ms-overflow-style:none;scrollbar-width:none;visibility:hidden;border-top-left-radius:var(--ptc-border-radius-standard);border-top-right-radius:var(--ptc-border-radius-standard);box-shadow:var(--ptc-shadow-x-large)}:host #sticky-header-container::-webkit-scrollbar{display:none}:host #sticky-header-container th{background:var(--color-gray-10);color:white;padding:var(--ptc-element-spacing-04) var(--ptc-element-spacing-06) var(--ptc-element-spacing-04) var(--ptc-element-spacing-06);min-width:168px;max-width:180px;vertical-align:middle}:host #sticky-header-container th:not(:last-child){border-right:1px solid var(--color-gray-07)}:host #sticky-header-container th.desktop-header-first-cell{display:none}:host #sticky-header-container th.border-box-header-cell{box-sizing:border-box}:host #sticky-header-container th.table-filler-header-cell{width:99%;box-sizing:content-box}:host .scroll-buttons-container{position:absolute;top:0;right:0;display:flex;align-items:center;box-sizing:border-box}:host .scroll-buttons-container .scroll-buttons{z-index:15;position:absolute;display:inline-block;width:36px;width:fit-content;height:36px;background-color:white;box-shadow:var(--ptc-shadow-x-medium);display:flex;justify-content:center;align-items:center}:host .scroll-buttons-container .scroll-buttons icon-asset{z-index:15;display:flex;justify-content:center;align-items:center;width:36px;height:100%}:host .scroll-buttons-container .scroll-buttons.prev-button{z-index:15;left:0;border-radius:0px var(--ptc-element-spacing-01) var(--ptc-element-spacing-01) 0px}:host .scroll-buttons-container .scroll-buttons.prev-button ptc-para{z-index:15;margin-right:var(--ptc-element-spacing-04);display:none}:host .scroll-buttons-container .scroll-buttons.next-button{z-index:15;right:0;border-radius:var(--ptc-element-spacing-01) 0px 0px var(--ptc-element-spacing-01)}:host .scroll-buttons-container .scroll-buttons.next-button ptc-para{z-index:15;margin-left:var(--ptc-element-spacing-04);display:none}:host #table-container{border-radius:var(--ptc-border-radius-standard);box-shadow:var(--ptc-shadow-x-small);overflow-x:scroll;position:relative}:host #table-container #horizontal-scroll-box-shadow{display:none}:host #table-container table{border-spacing:0}:host #table-container th{background:var(--color-gray-10);color:white;padding:var(--ptc-element-spacing-04) var(--ptc-element-spacing-06) var(--ptc-element-spacing-04) var(--ptc-element-spacing-06)}:host #table-container th:not(:last-child){border-right:1px solid var(--color-gray-07)}:host #table-container th.desktop-header-first-cell{display:none}:host #table-container th.table-filler-header-cell{width:99%;display:none}:host #table-container tbody.mobile-table-body{display:contents;width:100%}:host #table-container tbody.desktop-table-body{display:none}:host #table-container tr{background-color:white;width:100%;overflow-x:scroll}:host #table-container tr:nth-child(odd){background-color:var(--color-gray-01)}:host #table-container tr:nth-child(even){background-color:white}:host #table-container tr.table-button-row{background-color:white}:host #table-container tr.table-button-row td{border-top:1px solid var(--color-gray-02)}:host #table-container tr.table-button-row td ptc-tooltip .text-ellipsis{font-size:var(--ptc-font-size-x-small)}:host #table-container td{text-align:center;min-width:168px;max-width:180px;padding:var(--ptc-element-spacing-04) var(--ptc-element-spacing-06) var(--ptc-element-spacing-04) var(--ptc-element-spacing-06)}:host #table-container td:not(:last-child){border-right:1px solid var(--color-gray-02)}:host #table-container td.table-filler-body-cell{width:99%;display:none}@media only screen and (min-width: 768px){:host .table-descriptor{width:768px;margin:auto}}@media only screen and (min-width: 992px){:host #sticky-header-container{box-shadow:none}:host #sticky-header-container th{max-width:275px}:host #sticky-header-container th.desktop-header-first-cell{display:table-cell;min-width:275px;box-sizing:content-box}:host #sticky-header-container th:first-of-type{position:-webkit-sticky;position:sticky;left:0;z-index:5}:host #sticky-header-container th.table-filler-header-cell{width:99%;display:none;max-width:fit-content;box-sizing:border-box}:host #table-container #horizontal-scroll-box-shadow{display:block;position:absolute;top:0;left:0;height:100%;width:var(--ptc-element-spacing-06);background:linear-gradient(90deg, rgba(0, 0, 0, 0.12) 0%, rgba(0, 0, 0, 0) 100%);z-index:10;visibility:hidden}:host #table-container th{max-width:275px}:host #table-container th.desktop-header-first-cell{display:table-cell;min-width:275px}:host #table-container th:first-of-type{position:-webkit-sticky;position:sticky;left:0;z-index:5}:host #table-container th.table-filler-header-cell{width:99%;display:none}:host #table-container tbody.mobile-table-body{display:none}:host #table-container tbody.desktop-table-body{display:contents;width:100%}:host #table-container tr:nth-child(odd){background-color:white}:host #table-container tr:nth-child(even){background-color:var(--color-gray-01)}:host #table-container tr.table-button-row{background-color:white}:host #table-container tr.table-button-row td{border-top:1px solid var(--color-gray-02)}:host #table-container td{max-width:275px}:host #table-container td:first-of-type{position:-webkit-sticky;position:sticky;left:0;z-index:5;background:inherit;min-width:275px}:host #table-container td:not(:first-child){text-align:center}:host #table-container td.first-column-cell.scroll-shadow{box-shadow:var(--ptc-shadow-x-large)}:host #table-container td.first-column-cell.no-shadow{box-shadow:none}:host #table-container td.table-filler-body-cell{width:99%;display:none}:host #table-container td.table-filler-button-cell{width:99%;display:none}}";
4
-
5
- const PtcPricingTable = class {
6
- constructor(hostRef) {
7
- registerInstance(this, hostRef);
8
- this.scrollTopClipperHeightOptions = {
9
- withSubNav: {
10
- desktop: "104px",
11
- mobile: "80px"
12
- },
13
- withoutSubNav: {
14
- desktop: "40px",
15
- mobile: "24px"
16
- }
17
- };
18
- this.verticalEdgePixelComparator = (edge1, edge2) => {
19
- let delta = 2;
20
- if ((edge1 == edge2) || ((edge1 >= (edge2 - delta)) && (edge1 <= (edge2 + delta)))) {
21
- return 0;
22
- }
23
- if (edge1 < (edge2 - delta)) {
24
- return -1;
25
- }
26
- if (edge1 > (edge2 + delta)) {
27
- return 1;
28
- }
29
- };
30
- this.handleHorizontalScroll = () => {
31
- var _a, _b, _c, _d, _e, _f, _g, _h;
32
- this.targetElements = this.getTargetElements();
33
- this.targetElements["sticky-header-container"].scrollLeft = (_a = this.targetElements["table-container"]) === null || _a === void 0 ? void 0 : _a.scrollLeft;
34
- // Scroll the button containers in sync with the table's scrolling
35
- if ([-1, 0].includes(this.verticalEdgePixelComparator((_b = this.targetElements["table-container"]) === null || _b === void 0 ? void 0 : _b.getBoundingClientRect().right, (_c = this.targetElements["table"]) === null || _c === void 0 ? void 0 : _c.getBoundingClientRect().right))) {
36
- this.targetElements["normal-scroll-buttons-container"].style.left = `${((_d = this.targetElements["table-container"]) === null || _d === void 0 ? void 0 : _d.scrollLeft) + this.desktopHeaderFirstCellWidth}px`;
37
- this.targetElements["sticky-scroll-buttons-container"].style.left = `${((_e = this.targetElements["table-container"]) === null || _e === void 0 ? void 0 : _e.scrollLeft) + this.desktopHeaderFirstCellWidth}px`;
38
- }
39
- // Scroll the mobile row headers along with the table in the mobile view
40
- if (this.targetElements["mobile-table-row-headers"].length > 0) {
41
- for (let i = 0; i < this.dataRows; i++) {
42
- this.targetElements["mobile-table-row-headers"][i].style.paddingLeft = `${(_f = this.targetElements["table-container"]) === null || _f === void 0 ? void 0 : _f.scrollLeft}px`;
43
- }
44
- }
45
- // Managing the visibility of the next scroll buttons in both the sticky and normal headers, depending on whether the table can scroll further to the right or not
46
- if ([0, 1].includes(this.verticalEdgePixelComparator((_g = this.targetElements["table-container"]) === null || _g === void 0 ? void 0 : _g.getBoundingClientRect().right, this.targetElements["table"].getBoundingClientRect().right))) {
47
- this.targetElements["normal-next-scroll-button"].style.visibility = 'hidden';
48
- if (this.targetElements["sticky-header-container"].style.visibility === 'visible') {
49
- this.targetElements["sticky-next-scroll-button"].style.visibility = 'hidden';
50
- }
51
- }
52
- else {
53
- this.targetElements["normal-next-scroll-button"].style.visibility = 'visible';
54
- if (this.targetElements["sticky-header-container"].style.visibility === 'visible') {
55
- this.targetElements["sticky-next-scroll-button"].style.visibility = 'visible';
56
- }
57
- }
58
- // Adjusting the visibility of the previous scroll buttons in both the sticky and normal headers, as well as the box shadow in desktop view, depending on whether the table can scroll further to the left or not
59
- if (this.targetElements["table-container"].scrollLeft === 0) {
60
- this.targetElements["horizontal-scroll-box-shadow"].style.left = '0';
61
- this.targetElements["horizontal-scroll-box-shadow"].style.visibility = 'hidden';
62
- this.targetElements["normal-previous-scroll-button"].style.visibility = 'hidden';
63
- if (this.targetElements["sticky-header-container"].style.visibility === 'visible') {
64
- this.targetElements["sticky-previous-scroll-button"].style.visibility = 'hidden';
65
- }
66
- }
67
- else {
68
- this.targetElements["horizontal-scroll-box-shadow"].style.left = `${((_h = this.targetElements["table-container"]) === null || _h === void 0 ? void 0 : _h.scrollLeft) + this.desktopHeaderFirstCellWidth}px`;
69
- this.targetElements["horizontal-scroll-box-shadow"].style.visibility = 'visible';
70
- this.targetElements["normal-previous-scroll-button"].style.visibility = 'visible';
71
- if (this.targetElements["sticky-header-container"].style.visibility === 'visible') {
72
- this.targetElements["sticky-previous-scroll-button"].style.visibility = 'visible';
73
- }
74
- }
75
- };
76
- this.handleVerticalScroll = () => {
77
- this.targetElements = this.getTargetElements();
78
- const scrollTopPosition = window.scrollY || document.documentElement.scrollTop;
79
- if (scrollTopPosition < this.lastScrollTop) {
80
- // Scrolling Up
81
- if (this.targetElements["table-container"].getBoundingClientRect().bottom > 0) {
82
- if (this.targetElements["sticky-header-container"].getBoundingClientRect().top < 0) {
83
- // Scroll the sticky header back into view along with the table
84
- this.targetElements["vertical-scroll-content-clipper"].style.display = 'block';
85
- this.targetElements["sticky-scroll-buttons-container"].style.opacity = '1';
86
- this.targetElements["sticky-header-container"].style.visibility = 'visible';
87
- this.targetElements["sticky-header-container"].style.top = `${this.targetElements["table-container"].getBoundingClientRect().bottom - this.targetElements["sticky-header-container"].getBoundingClientRect().height}px`;
88
- }
89
- else {
90
- // Make the sticky header fixed once it is entirely within the window
91
- this.targetElements["sticky-header-container"].style.top = this.scrollTopClipperHeight;
92
- }
93
- }
94
- if (this.targetElements["table-header"].getBoundingClientRect().top > this.targetElements["sticky-header-container"].getBoundingClientRect().top) {
95
- // Conceal the sticky header and reveal the normal header
96
- this.targetElements["sticky-scroll-buttons-container"].style.opacity = '0';
97
- this.targetElements["sticky-header-container"].style.visibility = 'hidden';
98
- this.targetElements["table-header"].style.visibility = 'visible';
99
- this.targetElements["vertical-scroll-content-clipper"].style.display = 'none';
100
- }
101
- }
102
- else if (scrollTopPosition > this.lastScrollTop) {
103
- // Scrolling down
104
- if (this.targetElements["sticky-header-container"].getBoundingClientRect().bottom <= 0) {
105
- // Reset and hide the sticky header when it scrolls out of the top of the window
106
- this.targetElements["sticky-header-container"].style.top = `${-this.targetElements["sticky-header-container"].getBoundingClientRect().height}px`;
107
- this.targetElements["sticky-scroll-buttons-container"].style.opacity = '0';
108
- this.targetElements["sticky-header-container"].style.visibility = 'hidden';
109
- this.targetElements["vertical-scroll-content-clipper"].style.display = 'none';
110
- }
111
- else if (this.targetElements["table-header"].getBoundingClientRect().top <= this.targetElements["sticky-header-container"].getBoundingClientRect().top) {
112
- if (this.targetElements["table-container"].getBoundingClientRect().bottom <= this.targetElements["sticky-header-container"].getBoundingClientRect().bottom) {
113
- // Scroll the sticky header out of the window along with the table
114
- this.targetElements["sticky-header-container"].style.top = `${(this.targetElements["table-container"].getBoundingClientRect().bottom - this.targetElements["sticky-header-container"].clientHeight)}px`;
115
- }
116
- else {
117
- // Conceal the normal header and reveal the sticky header
118
- this.targetElements["vertical-scroll-content-clipper"].style.display = 'block';
119
- this.targetElements["sticky-scroll-buttons-container"].style.opacity = '1';
120
- this.targetElements["sticky-header-container"].style.visibility = 'visible';
121
- this.targetElements["table-header"].style.visibility = 'hidden';
122
- this.targetElements["sticky-previous-scroll-button"].style.visibility = this.targetElements["normal-previous-scroll-button"].style.visibility;
123
- this.targetElements["sticky-next-scroll-button"].style.visibility = this.targetElements["normal-next-scroll-button"].style.visibility;
124
- if (getComputedStyle(this.targetElements["sticky-next-scroll-button"]).visibility === "visible") {
125
- this.targetElements["table-filler-sticky-header-cell"].style.boxSizing = "content-box";
126
- }
127
- }
128
- }
129
- }
130
- this.lastScrollTop = scrollTopPosition <= 0 ? 0 : scrollTopPosition;
131
- };
132
- this.handleResize = () => {
133
- this.targetElements["table-container"].scrollLeft = 0;
134
- this.handleHorizontalScroll();
135
- this.configureStickyHeader();
136
- this.configureScrollButtonsContainers();
137
- this.configureTableFillerCells();
138
- };
139
- this.pageWithSubnav = false;
140
- this.tableTitle = undefined;
141
- this.tableSubTitle = "";
142
- this.tableDescription = "";
143
- this.dataRows = undefined;
144
- this.dataCols = undefined;
145
- this.disclaimerCount = 0;
146
- this.scrollTopClipperHeight = undefined;
147
- this.desktopHeaderFirstCellWidth = 0;
148
- this.targetElements = {};
149
- this.columnHeaderLinks = [];
150
- this.lastScrollTop = undefined;
151
- this.scrollTimeInterval = 35;
152
- this.scrollAmount = 5;
153
- this.scrollLimit = 50;
154
- this.mobileHeaderRowColSpan = this.dataCols;
155
- this.showCtaButtonsRow = undefined;
156
- this.ctaButtons = [];
157
- this.disclaimers = [];
158
- }
159
- // Provides an object containing frequently accessed HTML elements for table-related operations
160
- getTargetElements() {
161
- let pricingTable = this.el.shadowRoot;
162
- let verticalScrollContentClipper = pricingTable === null || pricingTable === void 0 ? void 0 : pricingTable.querySelector('#vertical-scroll-content-clipper');
163
- let tableContainer = pricingTable === null || pricingTable === void 0 ? void 0 : pricingTable.querySelector('#table-container');
164
- let table = tableContainer === null || tableContainer === void 0 ? void 0 : tableContainer.querySelector('table');
165
- let tableHeader = tableContainer === null || tableContainer === void 0 ? void 0 : tableContainer.querySelector('table thead');
166
- let desktopHeaderFirstCell = tableContainer === null || tableContainer === void 0 ? void 0 : tableContainer.querySelector('.desktop-header-first-cell');
167
- let tableHeaderCells = tableContainer === null || tableContainer === void 0 ? void 0 : tableContainer.querySelectorAll('th');
168
- let desktopTableBody = tableContainer === null || tableContainer === void 0 ? void 0 : tableContainer.querySelector('.desktop-table-body');
169
- let mobileTableBody = tableContainer === null || tableContainer === void 0 ? void 0 : tableContainer.querySelector('.mobile-table-body');
170
- let stickyHeaderContainer = pricingTable === null || pricingTable === void 0 ? void 0 : pricingTable.querySelector('#sticky-header-container');
171
- let stickyHeaderCells = stickyHeaderContainer === null || stickyHeaderContainer === void 0 ? void 0 : stickyHeaderContainer.querySelectorAll('th');
172
- let verticalScrollBoxShadow = tableContainer === null || tableContainer === void 0 ? void 0 : tableContainer.querySelector("#vertical-scroll-box-shadow");
173
- let tableFillerStickyHeaderCell = stickyHeaderContainer === null || stickyHeaderContainer === void 0 ? void 0 : stickyHeaderContainer.querySelector('.table-filler-header-cell');
174
- let tableFillerHeaderCell = tableHeader === null || tableHeader === void 0 ? void 0 : tableHeader.querySelector('.table-filler-header-cell');
175
- let tableFillerBodyCells = table === null || table === void 0 ? void 0 : table.querySelectorAll('.table-filler-body-cell');
176
- let tableFillerButtonCell = table === null || table === void 0 ? void 0 : table.querySelector('.table-filler-button-cell');
177
- let mobileTableRowHeaders = pricingTable === null || pricingTable === void 0 ? void 0 : pricingTable.querySelectorAll('.mobile-table-row-header');
178
- let normalScrollButtonsContainer = tableContainer === null || tableContainer === void 0 ? void 0 : tableContainer.querySelector('.scroll-buttons-container');
179
- let stickyScrollButtonsContainer = stickyHeaderContainer === null || stickyHeaderContainer === void 0 ? void 0 : stickyHeaderContainer.querySelector('.scroll-buttons-container');
180
- let normalPreviousScrollButton = normalScrollButtonsContainer === null || normalScrollButtonsContainer === void 0 ? void 0 : normalScrollButtonsContainer.querySelector('.prev-button');
181
- let normalPreviousScrollButtonText = normalPreviousScrollButton === null || normalPreviousScrollButton === void 0 ? void 0 : normalPreviousScrollButton.querySelector('ptc-para');
182
- let stickyPreviousScrollButton = stickyScrollButtonsContainer === null || stickyScrollButtonsContainer === void 0 ? void 0 : stickyScrollButtonsContainer.querySelector('.prev-button');
183
- let stickyPreviousScrollButtonText = stickyPreviousScrollButton === null || stickyPreviousScrollButton === void 0 ? void 0 : stickyPreviousScrollButton.querySelector('ptc-para');
184
- let normalNextScrollButton = normalScrollButtonsContainer === null || normalScrollButtonsContainer === void 0 ? void 0 : normalScrollButtonsContainer.querySelector('.next-button');
185
- let normalNextScrollButtonText = normalNextScrollButton === null || normalNextScrollButton === void 0 ? void 0 : normalNextScrollButton.querySelector('ptc-para');
186
- let stickyNextScrollButton = stickyScrollButtonsContainer === null || stickyScrollButtonsContainer === void 0 ? void 0 : stickyScrollButtonsContainer.querySelector('.next-button');
187
- let stickyNextScrollButtonText = stickyNextScrollButton === null || stickyNextScrollButton === void 0 ? void 0 : stickyNextScrollButton.querySelector('ptc-para');
188
- let horizontalScrollBoxShadow = tableContainer === null || tableContainer === void 0 ? void 0 : tableContainer.querySelector('#horizontal-scroll-box-shadow');
189
- let targetElements = {
190
- "vertical-scroll-content-clipper": verticalScrollContentClipper,
191
- "pricing-table": pricingTable,
192
- "table-container": tableContainer,
193
- "table": table,
194
- "table-header": tableHeader,
195
- "desktop-header-first-cell": desktopHeaderFirstCell,
196
- "table-header-cells": tableHeaderCells,
197
- "desktop-table-body": desktopTableBody,
198
- "mobile-table-body": mobileTableBody,
199
- "sticky-header-container": stickyHeaderContainer,
200
- "sticky-header-cells": stickyHeaderCells,
201
- "vertical-scroll-box-shadow": verticalScrollBoxShadow,
202
- "table-filler-sticky-header-cell": tableFillerStickyHeaderCell,
203
- "table-filler-header-cell": tableFillerHeaderCell,
204
- "table-filler-body-cells": tableFillerBodyCells,
205
- "table-filler-button-cell": tableFillerButtonCell,
206
- "mobile-table-row-headers": mobileTableRowHeaders,
207
- "normal-scroll-buttons-container": normalScrollButtonsContainer,
208
- "sticky-scroll-buttons-container": stickyScrollButtonsContainer,
209
- "normal-previous-scroll-button": normalPreviousScrollButton,
210
- "normal-previous-scroll-button-text": normalPreviousScrollButtonText,
211
- "sticky-previous-scroll-button": stickyPreviousScrollButton,
212
- "sticky-previous-scroll-button-text": stickyPreviousScrollButtonText,
213
- "normal-next-scroll-button": normalNextScrollButton,
214
- "normal-next-scroll-button-text": normalNextScrollButtonText,
215
- "sticky-next-scroll-button": stickyNextScrollButton,
216
- "sticky-next-scroll-button-text": stickyNextScrollButtonText,
217
- "horizontal-scroll-box-shadow": horizontalScrollBoxShadow,
218
- };
219
- return targetElements;
220
- }
221
- // Sets up the scroll buttons container for both the sticky and normal headers
222
- configureScrollButtonsContainers() {
223
- this.targetElements = this.getTargetElements();
224
- // Defines the dimensions
225
- this.targetElements["normal-scroll-buttons-container"].style.width = `${this.targetElements["table-container"].clientWidth}px`;
226
- this.targetElements["normal-scroll-buttons-container"].style.height = `${this.targetElements["table-header"].clientHeight}px`;
227
- this.targetElements["sticky-scroll-buttons-container"].style.width = `${this.targetElements["table-container"].clientWidth}px`;
228
- this.targetElements["sticky-scroll-buttons-container"].style.height = `${this.targetElements["table-header"].clientHeight}px`;
229
- // For desktop screens, scroll buttons are positioned after the first column of the table
230
- if (this.targetElements["desktop-header-first-cell"]) {
231
- this.targetElements["normal-scroll-buttons-container"].style.width = `${this.targetElements["normal-scroll-buttons-container"].getBoundingClientRect().width - this.desktopHeaderFirstCellWidth}px`;
232
- this.targetElements["sticky-scroll-buttons-container"].style.width = `${this.targetElements["sticky-scroll-buttons-container"].getBoundingClientRect().width - this.desktopHeaderFirstCellWidth}px`;
233
- }
234
- // Controlling the visibility of the previous scroll buttons, of the sticky and normal headers, based on whether table can scroll further to the left or not
235
- if (this.targetElements["table-container"].scrollLeft === 0) {
236
- this.targetElements["normal-previous-scroll-button"].style.visibility = 'hidden';
237
- if (this.targetElements["sticky-header-container"].style.visibility === 'visible') {
238
- this.targetElements["sticky-previous-scroll-button"].style.visibility = 'hidden';
239
- }
240
- }
241
- else {
242
- this.targetElements["normal-previous-scroll-button"].style.visibility = 'visible';
243
- if (this.targetElements["sticky-header-container"].style.visibility === 'visible') {
244
- this.targetElements["sticky-previous-scroll-button"].style.visibility = 'visible';
245
- }
246
- }
247
- // Managing the visibility of the next scroll buttons in both the sticky and normal headers, depending on whether the table can be scrolled further to the right or not
248
- if (this.targetElements["table-container"].getBoundingClientRect().width >= this.targetElements["table"].getBoundingClientRect().width) {
249
- this.targetElements["normal-next-scroll-button"].style.visibility = 'hidden';
250
- if (this.targetElements["sticky-header-container"].style.visibility === 'visible') {
251
- this.targetElements["sticky-next-scroll-button"].style.visibility = 'hidden';
252
- }
253
- }
254
- else {
255
- this.targetElements["normal-next-scroll-button"].style.visibility = 'visible';
256
- if (this.targetElements["sticky-header-container"].style.visibility === 'visible') {
257
- this.targetElements["sticky-next-scroll-button"].style.visibility = 'visible';
258
- }
259
- }
260
- }
261
- // Configures the sticky header based on the dimensions of the table header
262
- configureStickyHeader() {
263
- var _a, _b, _c, _d, _e, _f;
264
- const targetElements = this.getTargetElements();
265
- // Expanding the content clipper by an additional 10px on each side to accommodate the table's box-shadow
266
- targetElements["vertical-scroll-content-clipper"].style.width = `${targetElements["table-container"].clientWidth + 20}px`;
267
- // Aligns the background color of the element with the body's background color
268
- const bodyBackgroundColor = window.getComputedStyle(document.body, null).getPropertyValue('background-color');
269
- if (bodyBackgroundColor === ("rgba(0, 0, 0, 0)" )) {
270
- targetElements["vertical-scroll-content-clipper"].style.backgroundColor = "white";
271
- }
272
- else {
273
- targetElements["vertical-scroll-content-clipper"].style.backgroundColor = bodyBackgroundColor;
274
- }
275
- // Establishing the width of the sticky header to be in line with the table's width
276
- targetElements["sticky-header-container"].style.width = `${targetElements["table-container"].clientWidth}px`;
277
- // Adjusts the table's sticky behavior, making it adhere at varying positions below the top, contingent on factors like the device type (mobile or desktop) and the presence of a subnav in the page
278
- if (this.pageWithSubnav) {
279
- if (window.innerWidth >= 1200) {
280
- this.scrollTopClipperHeight = this.scrollTopClipperHeightOptions.withSubNav.desktop;
281
- }
282
- else {
283
- this.scrollTopClipperHeight = this.scrollTopClipperHeightOptions.withSubNav.mobile;
284
- }
285
- }
286
- else {
287
- if (window.innerWidth >= 1200) {
288
- this.scrollTopClipperHeight = this.scrollTopClipperHeightOptions.withoutSubNav.desktop;
289
- }
290
- else {
291
- this.scrollTopClipperHeight = this.scrollTopClipperHeightOptions.withoutSubNav.mobile;
292
- }
293
- }
294
- targetElements["vertical-scroll-content-clipper"].style.height = this.scrollTopClipperHeight;
295
- targetElements["sticky-header-container"].style.top = this.scrollTopClipperHeight;
296
- // Align the widths of sticky header cells with those of the normal header cells
297
- for (let i = 0; i < targetElements["table-header-cells"].length; i++) {
298
- targetElements["sticky-header-cells"][i].style.width = `${targetElements["table-header-cells"][i].getBoundingClientRect().width}px`;
299
- if (targetElements["table-header-cells"][i].classList.contains('desktop-header-first-cell')) {
300
- this.desktopHeaderFirstCellWidth = targetElements["table-header-cells"][i].getBoundingClientRect().width;
301
- }
302
- }
303
- // Box-sizing
304
- if (targetElements["table"].clientWidth <= targetElements["table-container"].clientWidth) {
305
- if (targetElements["desktop-table-body"]) {
306
- for (let i = 0; i < targetElements["sticky-header-cells"].length; i++) {
307
- (_b = (_a = targetElements["sticky-header-cells"][i]) === null || _a === void 0 ? void 0 : _a.classList) === null || _b === void 0 ? void 0 : _b.add('border-box-header-cell');
308
- }
309
- }
310
- }
311
- else {
312
- for (let i = 0; i < targetElements["sticky-header-cells"].length; i++) {
313
- if ((_d = (_c = targetElements["sticky-header-cells"][i]) === null || _c === void 0 ? void 0 : _c.classList) === null || _d === void 0 ? void 0 : _d.contains('border-box-header-cell')) {
314
- (_f = (_e = targetElements["sticky-header-cells"][i]) === null || _e === void 0 ? void 0 : _e.classList) === null || _f === void 0 ? void 0 : _f.remove('border-box-header-cell');
315
- }
316
- }
317
- }
318
- }
319
- configureTableFillerCells() {
320
- var _a, _b, _c, _d;
321
- this.targetElements = this.getTargetElements();
322
- this.targetElements["table-filler-sticky-header-cell"].style.width = this.targetElements["table-filler-header-cell"].getBoundingClientRect().width;
323
- if (this.targetElements['table'].getBoundingClientRect().width < this.targetElements['table-container'].getBoundingClientRect().width) {
324
- // If the table is smaller than the container, insert fillers
325
- this.targetElements["table-filler-sticky-header-cell"].style.display = 'table-cell';
326
- this.targetElements["table-filler-header-cell"].style.display = 'table-cell';
327
- for (let i = 0; i < this.dataRows; i++) {
328
- this.targetElements["table-filler-body-cells"][i].style.display = 'table-cell';
329
- }
330
- if (this.targetElements["table-filler-button-cell"]) {
331
- this.targetElements["table-filler-button-cell"].style.display = 'table-cell';
332
- }
333
- this.mobileHeaderRowColSpan = this.dataCols + 1;
334
- }
335
- else {
336
- // If the table is equal to or larger than the container, remove fillers
337
- this.targetElements["table-filler-sticky-header-cell"].style.width = '99%';
338
- if (getComputedStyle(this.targetElements["sticky-next-scroll-button"]).visibility === 'hidden') {
339
- for (let i = 0; i < this.targetElements["sticky-header-cells"].length + 1; i++) {
340
- if ((_b = (_a = this.targetElements["sticky-header-cells"][i]) === null || _a === void 0 ? void 0 : _a.classList) === null || _b === void 0 ? void 0 : _b.contains('border-box-header-cell')) {
341
- (_d = (_c = this.targetElements["sticky-header-cells"][i]) === null || _c === void 0 ? void 0 : _c.classList) === null || _d === void 0 ? void 0 : _d.remove('border-box-header-cell');
342
- }
343
- }
344
- }
345
- }
346
- }
347
- handleStickyHeaderHorizontalScroll() {
348
- var _a;
349
- this.targetElements["table-container"].scrollLeft = (_a = this.targetElements["sticky-header-container"]) === null || _a === void 0 ? void 0 : _a.scrollLeft;
350
- }
351
- handleScrollForwardHover() {
352
- if (this.targetElements["normal-next-scroll-button"].getAttribute("data-clicked") !== "true") {
353
- document.body.style.cursor = 'pointer';
354
- this.targetElements["normal-next-scroll-button-text"].style.display = "block";
355
- this.targetElements["sticky-next-scroll-button-text"].style.display = "block";
356
- }
357
- }
358
- handleScrollForwardHoverOut() {
359
- if (this.targetElements["normal-next-scroll-button"].getAttribute("data-clicked") !== "true") {
360
- document.body.style.cursor = 'auto';
361
- this.targetElements["normal-next-scroll-button-text"].style.display = "none";
362
- this.targetElements["sticky-next-scroll-button-text"].style.display = "none";
363
- }
364
- }
365
- handleScrollForward() {
366
- this.targetElements = this.getTargetElements();
367
- // Display the "See more" text when clicked
368
- document.body.style.cursor = 'pointer';
369
- this.targetElements["normal-next-scroll-button"].setAttribute("data-clicked", "true");
370
- this.targetElements["normal-next-scroll-button-text"].style.display = "block";
371
- this.targetElements["sticky-next-scroll-button-text"].style.display = "block";
372
- let scrollAdded = 0;
373
- let intervalId = setInterval(() => {
374
- scrollAdded += this.scrollAmount;
375
- let tableContainerRight = this.targetElements["table-container"].getBoundingClientRect().right;
376
- let tableRight = this.targetElements["table"].getBoundingClientRect().right;
377
- if ((scrollAdded == this.scrollLimit) || ([0, 1].includes(this.verticalEdgePixelComparator(tableContainerRight, tableRight)))) {
378
- clearInterval(intervalId);
379
- this.targetElements["normal-next-scroll-button"].setAttribute("data-clicked", "false");
380
- // Remove the "See more" text if the mouse is not hovering over the button after scrolling
381
- if (!this.targetElements["normal-next-scroll-button"].matches(':hover') && !this.targetElements["sticky-next-scroll-button"].matches(':hover')) {
382
- document.body.style.cursor = 'auto';
383
- this.targetElements["normal-next-scroll-button-text"].style.display = "none";
384
- this.targetElements["sticky-next-scroll-button-text"].style.display = "none";
385
- }
386
- }
387
- this.targetElements["table-container"].scrollLeft += scrollAdded;
388
- }, this.scrollTimeInterval);
389
- }
390
- handleScrollBackwardHover() {
391
- document.body.style.cursor = 'pointer';
392
- if (this.targetElements["normal-previous-scroll-button"].getAttribute("data-clicked") !== "true") {
393
- this.targetElements["normal-previous-scroll-button-text"].style.display = "block";
394
- this.targetElements["sticky-previous-scroll-button-text"].style.display = "block";
395
- }
396
- }
397
- handleScrollBackwardHoverOut() {
398
- document.body.style.cursor = 'auto';
399
- if (this.targetElements["normal-previous-scroll-button"].getAttribute("data-clicked") !== "true") {
400
- this.targetElements["normal-previous-scroll-button-text"].style.display = "none";
401
- this.targetElements["sticky-previous-scroll-button-text"].style.display = "none";
402
- }
403
- }
404
- handleScrollBackward() {
405
- this.targetElements = this.getTargetElements();
406
- // Display the "See more" text when clicked
407
- document.body.style.cursor = 'pointer';
408
- this.targetElements["normal-previous-scroll-button"].setAttribute("data-clicked", "true");
409
- this.targetElements["normal-previous-scroll-button-text"].style.display = "block";
410
- this.targetElements["sticky-previous-scroll-button-text"].style.display = "block";
411
- let scrollReduced = 0;
412
- let intervalId = setInterval(() => {
413
- scrollReduced += this.scrollAmount;
414
- let tableContainerLeft = this.targetElements["table-container"].getBoundingClientRect().left;
415
- let tableLeft = this.targetElements["table"].getBoundingClientRect().left;
416
- if ((scrollReduced == this.scrollLimit) || [-1, 0].includes(this.verticalEdgePixelComparator(tableContainerLeft, tableLeft))) {
417
- clearInterval(intervalId);
418
- this.targetElements["normal-previous-scroll-button"].setAttribute("data-clicked", "false");
419
- // Remove the "See more" text if the mouse is not hovering over the button after scrolling
420
- if (!this.targetElements["normal-previous-scroll-button"].matches(':hover') && !this.targetElements["sticky-previous-scroll-button"].matches(':hover')) {
421
- document.body.style.cursor = 'auto';
422
- this.targetElements["normal-previous-scroll-button-text"].style.display = "none";
423
- this.targetElements["sticky-previous-scroll-button-text"].style.display = "none";
424
- }
425
- return;
426
- }
427
- this.targetElements["table-container"].scrollLeft -= scrollReduced;
428
- }, this.scrollTimeInterval);
429
- }
430
- componentWillLoad() {
431
- let desktopHeaderFirstCellSlot = this.el.querySelector('[slot="desktop-header-first-cell"]');
432
- let desktopHeaderFirstCellText = desktopHeaderFirstCellSlot.innerHTML;
433
- this.el.insertAdjacentHTML('afterbegin', `<span slot="normal-desktop-header-first-cell">${desktopHeaderFirstCellText}</span><span slot="sticky-desktop-header-first-cell">${desktopHeaderFirstCellText}</span>`);
434
- desktopHeaderFirstCellSlot.remove();
435
- let columnHeaders = this.el.querySelectorAll('[slot^="column-header"]');
436
- for (let i = 0; i < this.dataCols; i++) {
437
- let slotValue = columnHeaders[i].getAttribute('slot');
438
- let headerText = columnHeaders[i].innerHTML;
439
- this.el.insertAdjacentHTML('afterbegin', `<span slot="normal-${slotValue}">${headerText}</span><span slot="sticky-${slotValue}">${headerText}</span>`);
440
- columnHeaders[i].remove();
441
- }
442
- let headerLinks = this.el.querySelectorAll('[slot^="header-link"]');
443
- if (headerLinks.length > 0) {
444
- for (let i = 0; i < this.dataCols; i++) {
445
- let linkHref = headerLinks[i].getAttribute('href');
446
- let linkText = headerLinks[i].innerHTML;
447
- this.columnHeaderLinks.push({ linkHref, linkText });
448
- headerLinks[i].remove();
449
- }
450
- }
451
- let ctaButtons = this.el.querySelectorAll('[slot^="cta-button"]');
452
- this.showCtaButtonsRow = (ctaButtons.length !== 0);
453
- for (let i = 0; i < this.dataCols; i++) {
454
- this.ctaButtons.push({
455
- linkHref: ctaButtons[i].getAttribute('href'),
456
- linkText: ctaButtons[i].innerHTML
457
- });
458
- ctaButtons[i].remove();
459
- }
460
- let disclaimers = this.el.querySelectorAll('[slot^="disclaimer"]');
461
- for (let i = 0; i < this.disclaimerCount; i++) {
462
- this.disclaimers.push(disclaimers[i].innerHTML);
463
- disclaimers[i].remove();
464
- }
465
- }
466
- componentDidLoad() {
467
- this.configureTableFillerCells();
468
- this.configureStickyHeader();
469
- this.configureScrollButtonsContainers();
470
- window.addEventListener('scroll', this.handleVerticalScroll);
471
- window.addEventListener('resize', this.handleResize);
472
- }
473
- disconnectedCallback() {
474
- window.removeEventListener('scroll', this.handleVerticalScroll);
475
- window.removeEventListener('resize', this.handleResize);
476
- }
477
- render() {
478
- const getTableTitle = () => {
479
- return (this.tableTitle && h(Fragment, null, h("div", { class: "table-descriptor" }, h("ptc-title", { type: "h2", "text-align": "center", "title-size": "xx-large", upperline: "no-upperline", "title-height": "densest", "title-margin": "margin-flush", "title-weight": "w-8" }, this.tableTitle)), (this.tableSubTitle)
480
- ? h(Fragment, null, h("ptc-spacer", { breakpoint: "small", size: "x-small" }), h("ptc-spacer", { breakpoint: "x-small", size: "small" }))
481
- : (this.tableDescription)
482
- ? h(Fragment, null, h("ptc-spacer", { breakpoint: "small", size: "small" }), h("ptc-spacer", { breakpoint: "x-small", size: "medium" }))
483
- : null));
484
- };
485
- const getTableSubTitle = () => {
486
- return (this.tableSubTitle && h(Fragment, null, h("div", { class: "table-descriptor" }, h("ptc-title", { type: "h3", "text-align": "center", "title-size": "large", upperline: "no-upperline", "title-height": "densest", "title-margin": "margin-flush", "title-weight": "w-7" }, this.tableSubTitle)), h("ptc-spacer", { breakpoint: "small", size: "medium" }), h("ptc-spacer", { breakpoint: "x-small", size: "large" })));
487
- };
488
- const getTableDescription = () => {
489
- return (this.tableDescription && h(Fragment, null, h("div", { class: "table-descriptor" }, h("ptc-para", { "font-size": "small", "font-weight": "w-4", "para-align": "center", "para-line-h": "line-height-p", "para-margin": "margin-flush" }, (this.tableDescription.length <= 500) ? this.tableDescription : h("ptc-readmore", { "more-text": "See more" }, this.tableDescription)))));
490
- };
491
- const getScrollButtonsContainer = () => {
492
- return h("div", { class: "scroll-buttons-container" }, h("div", { class: "scroll-buttons prev-button", "data-clicked": "false", onClick: () => this.handleScrollBackward(), onMouseOver: () => this.handleScrollBackwardHover(), onMouseOut: () => this.handleScrollBackwardHoverOut() }, h("icon-asset", { type: "solid", size: "medium", name: "chevron-left", color: "primary-gray" }), h("ptc-para", { "font-size": "small", "font-weight": "w-6", "para-align": "justify", "para-color": "primary-grey", "para-line-h": "line-height-p", "para-margin": "margin-flush" }, "See More")), h("div", { class: "scroll-buttons next-button", "data-clicked": "false", onClick: () => this.handleScrollForward(), onMouseOver: () => this.handleScrollForwardHover(), onMouseOut: () => this.handleScrollForwardHoverOut() }, h("ptc-para", { "font-size": "small", "font-weight": "w-6", "para-align": "justify", "para-color": "primary-grey", "para-line-h": "line-height-p", "para-margin": "margin-flush" }, "See More"), h("icon-asset", { type: "solid", size: "medium", name: "chevron-right", color: "primary-gray" })));
493
- };
494
- const getTableHeader = (headerType) => {
495
- return h("thead", null, h("tr", null, h("th", { class: "desktop-header-first-cell" }, h("ptc-para", { "font-size": "medium", "font-weight": "w-7", "para-align": "left", "para-color": "white", "para-line-h": "line-height-p", "para-margin": "margin-flush" }, h("slot", { name: `${headerType}-desktop-header-first-cell` }))), ([...Array(this.dataCols).keys()]).map(col => {
496
- return h("th", null, h("ptc-para", { "font-size": "medium", "font-weight": "w-7", "para-align": "center", "para-color": "white", "para-line-h": "line-height-p", "para-margin": "margin-flush" }, h("slot", { name: `${headerType}-column-header-${col + 1}` })), (this.columnHeaderLinks.length === this.dataCols) ? h(Fragment, null, h("ptc-spacer", { breakpoint: 'small', size: "small" }), h("ptc-spacer", { breakpoint: 'x-small', size: "medium" }), h("ptc-link", { "font-size": "medium", "font-weight": "w-extrabold", href: `${this.columnHeaderLinks[col].linkHref}`, "link-area": "undefined", target: "_blank", theme: "d-green-underline" }, h("ptc-tooltip", { class: (col === (this.dataCols - 1)) ? "last-column-tooltip" : "", "text-display": "inline", "max-length": "30", "z-index": "z-2", description: this.columnHeaderLinks[col].linkText, position: "top" }))) : null);
497
- }), h("th", { class: "table-filler-header-cell" })));
498
- };
499
- const getMobileTableBody = () => {
500
- return h("tbody", { class: "mobile-table-body" }, ([...Array(this.dataRows).keys()]).map(row => {
501
- return h(Fragment, null, h("tr", null, h("td", { colSpan: this.mobileHeaderRowColSpan }, h("div", { class: "mobile-table-row-header" }, h("ptc-para", { "font-size": "small", "font-weight": "w-6", "para-align": "left", "para-color": "primary-grey", "para-line-h": "line-height-p", "para-margin": "margin-1" }, h("slot", { name: `row-header-${row + 1}` }))))), h("tr", null, ([...Array(this.dataCols).keys()]).map(col => {
502
- return h("td", null, h("slot", { name: `cell-r${row + 1}-c${col + 1}` }));
503
- }), h("td", { class: "table-filler-body-cell" })));
504
- }), (this.showCtaButtonsRow) ?
505
- h("tr", { class: "table-button-row" }, ([...Array(this.dataCols).keys()]).map(col => {
506
- return h("td", null, h("ptc-button", { type: "link", color: "ptc-tertiary", "link-href": this.ctaButtons[col].linkHref, target: "_blank" }, this.ctaButtons[col].linkText));
507
- }), (this.mobileHeaderRowColSpan > this.dataCols) ? h("td", { class: "table-filler-button-cell" }) : null) : null);
508
- };
509
- const getDesktopTableBody = () => {
510
- return h("tbody", { class: "desktop-table-body" }, ([...Array(this.dataRows).keys()]).map(row => {
511
- return h("tr", null, h("td", { class: "first-column-cell" }, h("ptc-para", { "font-size": "small", "font-weight": "w-6", "para-align": "left", "para-color": "primary-grey", "para-line-h": "line-height-p", "para-margin": "margin-1" }, h("slot", { name: `row-header-${row + 1}` }))), ([...Array(this.dataCols).keys()]).map(col => {
512
- return h("td", null, h("slot", { name: `cell-r${row + 1}-c${col + 1}` }));
513
- }), h("td", { class: "table-filler-body-cell" }));
514
- }), (this.showCtaButtonsRow) ?
515
- h("tr", { class: "table-button-row" }, h("td", null), ([...Array(this.dataCols).keys()]).map(col => {
516
- return h("td", null, h("ptc-button", { type: "link", color: "ptc-tertiary", "link-href": this.ctaButtons[col].linkHref, target: "_blank" }, h("ptc-tooltip", { class: (col === (this.dataCols - 1)) ? "last-column-tooltip" : "", "text-display": "inline", "max-length": "30", "z-index": "z-2", description: this.ctaButtons[col].linkText, position: "top" })));
517
- }), h("td", { class: "table-filler-button-cell" })) : null);
518
- };
519
- const getDisclaimers = () => {
520
- return ((this.disclaimerCount > 0) && h(Fragment, null, h("ptc-spacer", { breakpoint: "small", size: "medium" }), h("ptc-spacer", { breakpoint: "x-small", size: "large" }), this.disclaimers.map((disclaimer, ind) => {
521
- return h(Fragment, null, h("ptc-para", { "font-size": "xx-small", "font-weight": "w-6", "para-align": "center", "para-color": "primary-grey", "para-line-h": "line-height-p", "para-margin": "margin-flush" }, disclaimer), (ind != (this.disclaimerCount - 1)) ? h("ptc-spacer", { size: "xx-small" }) : null);
522
- })));
523
- };
524
- return (h(Host, null, h("div", { id: "vertical-scroll-content-clipper" }), h("div", { id: "sticky-header-container", onScroll: () => this.handleStickyHeaderHorizontalScroll() }, getScrollButtonsContainer(), getTableHeader("sticky")), h("ptc-spacer", { breakpoint: "small", size: "xxx-large" }), h("ptc-spacer", { breakpoint: "x-small", size: "xxxx-large" }), getTableTitle(), getTableSubTitle(), getTableDescription(), h("ptc-spacer", { breakpoint: "small", size: "xx-large" }), h("ptc-spacer", { breakpoint: "small", size: "xx-small" }), h("ptc-spacer", { breakpoint: "x-small", size: "xxx-large" }), h("ptc-spacer", { breakpoint: "x-small", size: "xx-small" }), h("div", { id: "table-container", onScroll: () => this.handleHorizontalScroll() }, getScrollButtonsContainer(), h("table", null, h("div", { id: "horizontal-scroll-box-shadow" }), getTableHeader("normal"), (window.innerWidth >= 992)
525
- ? getDesktopTableBody()
526
- : getMobileTableBody())), getDisclaimers(), h("ptc-spacer", { breakpoint: "small", size: "xxx-large" }), h("ptc-spacer", { breakpoint: "x-small", size: "xxxx-large" })));
527
- }
528
- get el() { return getElement(this); }
529
- };
530
- PtcPricingTable.style = ptcPricingTableCss;
531
-
532
- export { PtcPricingTable as ptc_pricing_table };
@@ -1 +0,0 @@
1
- import{r as t,h as e,H as l,g as i,F as a}from"./p-00a1336a.js";const s=class{constructor(e){t(this,e),this.verticalScrollContentClipperHeightOptions={withSubNav:{desktop:104,mobile:80},withoutSubNav:{desktop:40,mobile:24}},this.handleVerticalScroll=()=>{let t=this.el.shadowRoot.querySelector("#vertical-scroll-content-clipper"),e=this.el.shadowRoot.querySelector("#table-container"),l=this.el.shadowRoot.querySelector("#table-body"),i=this.el.shadowRoot.querySelector("#table-header-placeholder"),a=this.el.shadowRoot.querySelector("#table-header");const s=window.scrollY||document.documentElement.scrollTop;s<this.lastScrollTop?(i.getBoundingClientRect().top>=this.stickyTopAt&&(this.headerType="normal",a.style.top="0px"),"sticky"===this.headerType&&e.getBoundingClientRect().bottom>a.getBoundingClientRect().bottom&&a.getBoundingClientRect().top<this.stickyTopAt&&(a.style.top=`${Math.min(e.getBoundingClientRect().bottom-a.clientHeight,this.stickyTopAt)}px`,t.style.top=a.getBoundingClientRect().top-t.clientHeight+"px")):s>this.lastScrollTop&&(i.getBoundingClientRect().top<this.stickyTopAt&&(this.headerType="sticky",a.style.top=`${this.stickyTopAt}px`,a.style.width=`${l.getBoundingClientRect().width}px`,a.scrollLeft=l.scrollLeft),"sticky"===this.headerType&&e.getBoundingClientRect().bottom<=a.getBoundingClientRect().bottom&&(a.style.top=e.getBoundingClientRect().bottom-a.clientHeight+"px",t.style.top=a.getBoundingClientRect().top-t.clientHeight+"px")),this.lastScrollTop=s<=0?0:s},this.handleHorizontalScroll=()=>{let t=this.el.shadowRoot.querySelector("#table-header"),e=this.el.shadowRoot.querySelector("#table-body");t.scrollLeft=e.scrollLeft,this.handleScrollButtonsVisibility()},this.handleScrollButtonsVisibility=()=>{let t=this.el.shadowRoot.querySelector("#table-body"),e=this.el.shadowRoot.querySelector("#previous-scroll-button"),l=this.el.shadowRoot.querySelector("#next-scroll-button"),i=this.el.shadowRoot.querySelector("#horizontal-scroll-shadow");0===t.scrollLeft?(e.style.visibility="hidden",i.style.visibility="hidden"):(e.style.visibility="visible",i.style.visibility="visible"),l.style.visibility=[-1,0,1].includes(Math.trunc(t.scrollWidth-t.scrollLeft)-Math.trunc(t.getBoundingClientRect().width))?"hidden":"visible"},this.handleForwardScroll=()=>{let t=0,e=this.el.shadowRoot.querySelector("#table-body"),l=setInterval((()=>{t+=this.scrollAmount,(t==this.scrollLimit||[-1,0,1].includes(Math.trunc(e.scrollWidth-e.scrollLeft)-Math.trunc(e.getBoundingClientRect().width)))&&clearInterval(l),e.scrollLeft+=t}),this.scrollTimeInterval)},this.handleBackwardScroll=()=>{let t=0,e=this.el.shadowRoot.querySelector("#pricing-table"),l=this.el.shadowRoot.querySelector("#table-body"),i=setInterval((()=>{t+=this.scrollAmount,(t==this.scrollLimit||e.getBoundingClientRect().left>=l.getBoundingClientRect().right)&&clearInterval(i),l.scrollLeft-=t}),this.scrollTimeInterval)},this.setFillerCellWidth=t=>{this.el.style.setProperty("--filler-cell-width",`${t}px`)},this.expandTableCells=()=>{let t=this.el.shadowRoot.querySelector("#pricing-table"),e=this.el.shadowRoot.querySelector(".desktop-header-first-cell"),l=(t.getBoundingClientRect().width-e.getBoundingClientRect().width)/this.dataCols;this.isDesktopView?(this.el.style.setProperty("--cell-width-xxs",`${this.cellWidthXXS}px`),this.el.style.setProperty("--cell-width-md",l-this.cellLeftRightPadding+"px")):(this.el.style.setProperty("--cell-width-xxs",l-this.cellLeftRightPadding+"px"),this.el.style.setProperty("--cell-width-md",`${this.cellWidthMD}px`))},this.handleFillEmptySpace=()=>{let t=this.el.shadowRoot.querySelector("#pricing-table");this.el.shadowRoot.querySelector("#table-header-placeholder").getBoundingClientRect().right<t.getBoundingClientRect().right&&(this.hasEmptySpace=!0,this.expandTableCells())},this.resetWidthVariables=()=>{this.el.style.setProperty("--cell-width-xxs",`${this.cellWidthXXS}px`),this.el.style.setProperty("--cell-width-md",`${this.cellWidthMD}px`)},this.handleTableReset=()=>{let t=this.el.shadowRoot.querySelector("#vertical-scroll-content-clipper"),e=this.el.shadowRoot.querySelector("#table-header"),l=this.el.shadowRoot.querySelector("#table-body"),i=this.el.shadowRoot.querySelector("#next-scroll-button"),a=this.el.shadowRoot.querySelector(".desktop-header-first-cell"),s=this.el.shadowRoot.querySelector("#horizontal-scroll-shadow");this.isDesktopView=window.innerWidth>=992,this.resetWidthVariables(),this.stickyTopAt=this.pageWithSubnav?this.isDesktopView?this.verticalScrollContentClipperHeightOptions.withSubNav.desktop:this.verticalScrollContentClipperHeightOptions.withSubNav.mobile:this.isDesktopView?this.verticalScrollContentClipperHeightOptions.withoutSubNav.desktop:this.verticalScrollContentClipperHeightOptions.withoutSubNav.mobile,this.el.style.setProperty("--sticky-stop-at",`${this.stickyTopAt}px`);const r=window.getComputedStyle(document.body,null).getPropertyValue("background-color");t.style.backgroundColor="rgba(0, 0, 0, 0)"===r?"white":r,t.style.width=`${l.getBoundingClientRect().width+20}px`,t.style.transform="translateX(-10px)",e.style.width=`${l.getBoundingClientRect().width}px`,e.scrollLeft=l.scrollLeft,i.style.left=`${l.getBoundingClientRect().width}px`,s.style.left=`${a.getBoundingClientRect().width}px`,this.handleScrollButtonsVisibility(),this.handleFillEmptySpace()},this.preProcessTableDescription=()=>{let t=this.el.querySelector('[slot="table-description"]');t&&(this.tableDescription=t)},this.preProcessdesktopHeaderFirstCell=()=>{let t=this.el.querySelector('[slot="desktop-header-first-cell"]');this.el.insertAdjacentHTML("afterbegin",`<span slot="placeholder-desktop-header-first-cell">${t.innerHTML}</span>`)},this.preProcessColumnHeaders=()=>{let t=this.el.querySelectorAll('[slot^="column-header"]');for(let e=0;e<this.dataCols;e++){let l=t[e].getAttribute("slot");this.el.insertAdjacentHTML("afterbegin",`<span slot="placeholder-${l}">${t[e].innerHTML}</span>`)}},this.preProcessHeaderLinks=()=>{let t;for(let e=0;e<this.dataCols;e++)if(t=this.el.querySelector(`[slot^="header-link-${e+1}"]`),t){let e=t.getAttribute("href"),l=t.innerHTML,i=t.getAttribute("target");this.columnHeaderLinks.push({linkHref:e,linkText:l,linkTarget:i}),t.remove()}else this.columnHeaderLinks.push(null)},this.preProcessRowHeaders=()=>{let t;for(let e=0;e<this.dataRows;e++){t=this.el.querySelector(`[slot^="row-header-${e+1}"]`);let l=t.querySelectorAll(".table-row-header-p");for(let t=0;t<l.length;t++){let e=document.createElement("ptc-para");e.setAttribute("font-size","small"),e.setAttribute("font-weight","w-6"),e.setAttribute("para-align","left"),e.setAttribute("para-color","primary-grey"),e.setAttribute("para-line-h","line-height-p"),e.setAttribute("para-margin","margin-flush"),e.innerHTML=l[t].innerHTML,l[t].replaceWith(e)}let i=t.getAttribute("slot"),a=t.innerHTML;this.el.insertAdjacentHTML("afterbegin",`<div slot="desktop-${i}">${a}</div><div slot="mobile-${i}">${a}</div>`),t.remove()}},this.preProcessCtaButtons=()=>{let t;this.showCtaButtonsRow=!1;for(let e=0;e<this.dataCols;e++)if(t=this.el.querySelector(`[slot^="cta-button-${e+1}"]`),t){let e=t.getAttribute("href"),l=t.innerHTML,i=t.getAttribute("target");this.ctaButtons.push({linkHref:e,linkText:l,linkTarget:i}),t.remove(),this.showCtaButtonsRow=!0}else this.ctaButtons.push(null)},this.preProcessDisclaimers=()=>{let t=this.el.querySelectorAll('[slot^="disclaimer"]');for(let e=0;e<this.disclaimerCount;e++)this.disclaimers.push(t[e].innerHTML)},this.pageWithSubnav=!1,this.tableTitle=void 0,this.tableSubTitle="",this.dataRows=void 0,this.dataCols=void 0,this.disclaimerCount=0,this.isDesktopView=void 0,this.cellWidthXXS=180,this.cellWidthMD=225,this.cellLeftRightPadding=48,this.headerType="normal",this.lastScrollTop=void 0,this.scrollTimeInterval=25,this.scrollAmount=5,this.scrollLimit=50,this.stickyTopAt=void 0,this.columnHeaderLinks=[],this.hasEmptySpace=!1,this.showFillerCells=!1,this.showCtaButtonsRow=void 0,this.ctaButtons=[],this.disclaimers=[],this.tableDescription=void 0}componentWillLoad(){this.preProcessTableDescription(),this.preProcessdesktopHeaderFirstCell(),this.preProcessColumnHeaders(),this.preProcessHeaderLinks(),this.preProcessRowHeaders(),this.preProcessCtaButtons(),this.preProcessDisclaimers()}componentDidLoad(){this.handleTableReset(),window.addEventListener("scroll",(()=>this.handleVerticalScroll())),window.addEventListener("resize",(()=>this.handleTableReset()))}render(){return e(l,null,e("div",{id:"pricing-table"},e((()=>this.tableTitle&&e(a,null,e("div",{class:"table-descriptor"},e("ptc-title",{type:"h2","text-align":"center","title-size":"xx-large",upperline:"no-upperline","title-height":"densest","title-margin":"margin-flush","title-weight":"w-8"},this.tableTitle)),this.tableSubTitle?e(a,null,e("ptc-spacer",{breakpoint:"small",size:"x-small"}),e("ptc-spacer",{breakpoint:"x-small",size:"small"})):this.tableDescription?e(a,null,e("ptc-spacer",{breakpoint:"small",size:"small"}),e("ptc-spacer",{breakpoint:"x-small",size:"medium"})):null)),null),e((()=>this.tableSubTitle&&e(a,null,e("div",{class:"table-descriptor"},e("ptc-title",{type:"h3","text-align":"center","title-size":"large",upperline:"no-upperline","title-height":"densest","title-margin":"margin-flush","title-weight":"w-7"},this.tableSubTitle)),e("ptc-spacer",{breakpoint:"small",size:"medium"}),e("ptc-spacer",{breakpoint:"x-small",size:"large"}))),null),e((()=>this.tableDescription&&e(a,null,e("div",{class:"table-descriptor"},e("ptc-para",{"font-size":"small","font-weight":"w-4","para-align":"center","para-line-h":"line-height-p","para-margin":"margin-flush"},this.tableDescription.innerText.length<=500?e("slot",{name:"table-description"}):e("ptc-readmore",{"more-text":"More","less-text":"Less"},e("slot",{name:"table-description"})))))),null),e("ptc-spacer",{breakpoint:"small",size:"xx-large"}),e("ptc-spacer",{breakpoint:"small",size:"xx-small"}),e("ptc-spacer",{breakpoint:"x-small",size:"xxx-large"}),e("ptc-spacer",{breakpoint:"x-small",size:"xx-small"}),e("div",{id:"vertical-scroll-content-clipper",class:this.headerType}),e("div",{id:"table-container"},e("div",{id:"horizontal-scroll-shadow"}),e("div",{id:"table-body",onScroll:()=>this.handleHorizontalScroll()},e((()=>e("div",{id:"table-header",class:this.headerType,onScroll:()=>this.handleHorizontalScroll()},e("div",{class:"desktop-header-first-cell"},this.isDesktopView?e("ptc-para",{"font-size":"medium","font-weight":"w-7","para-align":"left","para-color":"white","para-line-h":"line-height-p","para-margin":"margin-flush"},e("slot",{name:"desktop-header-first-cell"})):null,e("div",{class:"scroll-button",id:"previous-scroll-button"},e("div",{onClick:()=>this.handleBackwardScroll()},e("icon-asset",{type:"solid",size:"medium",name:"chevron-left",color:"primary-gray"}),e("ptc-para",{"font-size":"small","font-weight":"w-6","para-align":"justify","para-color":"primary-grey","para-line-h":"line-height-p","para-margin":"margin-flush"},"More"))),e("div",{class:"scroll-button",id:"next-scroll-button"},e("div",{onClick:()=>this.handleForwardScroll()},e("ptc-para",{"font-size":"small","font-weight":"w-6","para-align":"justify","para-color":"primary-grey","para-line-h":"line-height-p","para-margin":"margin-flush"},"More"),e("icon-asset",{type:"solid",size:"medium",name:"chevron-right",color:"primary-gray"})))),[...Array(this.dataCols).keys()].map((t=>e("div",{class:"table-cell "+(t+1===this.dataCols?"table-last-cell":"")},e("ptc-para",{"font-size":"medium","font-weight":"w-7","para-align":"center","para-color":"white","para-line-h":"line-height-densest","para-margin":"margin-flush","para-z-index":"z-1"},e("slot",{name:`column-header-${t+1}`})),this.columnHeaderLinks.length===this.dataCols&&this.columnHeaderLinks[t]?e(a,null,e("ptc-spacer",{breakpoint:"small",size:"small"}),e("ptc-spacer",{breakpoint:"x-small",size:"medium"}),e("ptc-link",{"font-size":"medium","font-weight":"w-extrabold",href:`${this.columnHeaderLinks[t].linkHref}`,"link-area":"undefined",target:`${this.columnHeaderLinks[t].linkTarget}`,theme:"d-green-underline",styles:"a.ptc-link {line-height: var(--ptc-line-height-p);}"},this.isDesktopView?e("ptc-tooltip",{class:t===this.dataCols-1?"last-column-tooltip":"","text-display":"inline","max-length":"30","z-index":"z-2",description:this.columnHeaderLinks[t].linkText,position:"top"}):this.columnHeaderLinks[t].linkText)):null))),e("div",{class:"table-filler-cell "+(this.showFillerCells?"show":"")}))),null),e((()=>e("div",{id:"table-header-placeholder",class:this.headerType},e("div",{class:"desktop-header-first-cell"},this.isDesktopView?e("ptc-para",{"font-size":"medium","font-weight":"w-7","para-align":"left","para-color":"white","para-line-h":"line-height-p","para-margin":"margin-flush"},e("slot",{name:"placeholder-desktop-header-first-cell"})):null),[...Array(this.dataCols).keys()].map((t=>e("div",{class:"table-cell "+(t+1===this.dataCols?"table-last-cell":"")},e("ptc-para",{"font-size":"medium","font-weight":"w-7","para-align":"center","para-color":"white","para-line-h":"line-height-densest","para-margin":"margin-flush","para-z-index":"z-1"},e("slot",{name:`placeholder-column-header-${t+1}`})),this.columnHeaderLinks.length===this.dataCols&&this.columnHeaderLinks[t]?e(a,null,e("ptc-spacer",{breakpoint:"small",size:"small"}),e("ptc-spacer",{breakpoint:"x-small",size:"medium"}),e("ptc-link",{"font-size":"medium","font-weight":"w-extrabold",href:`${this.columnHeaderLinks[t].linkHref}`,"link-area":"undefined",target:`${this.columnHeaderLinks[t].linkTarget}`,theme:"d-green-underline",styles:"a.ptc-link {line-height: var(--ptc-line-height-p);}"},this.isDesktopView?e("ptc-tooltip",{class:t===this.dataCols-1?"last-column-tooltip":"","text-display":"inline","max-length":"30","z-index":"z-2",description:this.columnHeaderLinks[t].linkText,position:"top"}):this.columnHeaderLinks[t].linkText)):null))),e("div",{class:"table-filler-cell "+(this.showFillerCells?"show":"")}))),null),e((()=>[...Array(this.dataRows).keys()].map((t=>e(a,null,e("div",{class:"mobile-sticky-row-header"},e("slot",{name:`mobile-row-header-${t+1}`})),e("div",{class:"table-row "+(this.isDesktopView&&t%2!=0?"desktop-alternate-row":"")},this.isDesktopView?e("div",{class:"desktop-sticky-row-header "+(this.isDesktopView&&t%2!=0?"desktop-alternate-row":"")},e("slot",{name:`desktop-row-header-${t+1}`})):null,[...Array(this.dataCols).keys()].map((l=>e("div",{class:"table-cell "+(l+1===this.dataCols?"table-last-cell":"")},e("slot",{name:`cell-r${t+1}-c${l+1}`})))),e("div",{class:"table-filler-cell "+(this.showFillerCells?"show":"")})))))),null),e((()=>this.showCtaButtonsRow?e("div",{class:"table-cta-row"},this.isDesktopView?e("div",{class:"desktop-sticky-row-header"}):null,[...Array(this.dataCols).keys()].map((t=>e("div",{class:"table-cell "+(t+1===this.dataCols?"table-last-cell":"")},this.ctaButtons[t]?e("ptc-button",{type:"link",color:"ptc-tertiary","link-href":this.ctaButtons[t].linkHref,target:`${this.ctaButtons[t].linkTarget}`},this.isDesktopView?e("ptc-tooltip",{class:t===this.dataCols-1?"last-column-tooltip":"","text-display":"inline","max-length":"30","z-index":"z-2",description:this.ctaButtons[t].linkText,position:"top"}):this.ctaButtons[t].linkText):null))),e("div",{class:"table-filler-cell "+(this.showFillerCells?"show":"")})):null),null))),e((()=>this.disclaimerCount>0&&e(a,null,e("ptc-spacer",{breakpoint:"small",size:"medium"}),e("ptc-spacer",{breakpoint:"x-small",size:"large"}),this.disclaimers.map(((t,l)=>e(a,null,e("ptc-para",{"font-size":"xx-small","font-weight":"w-6","para-align":"center","para-color":"primary-grey","para-line-h":"line-height-p","para-margin":"margin-flush"},e("slot",{name:`disclaimer-${l+1}`})),l!=this.disclaimerCount-1?e("ptc-spacer",{size:"xx-small"}):null))))),null)))}get el(){return i(this)}};s.style=":host{display:block}:host #pricing-table{position:relative;overflow-wrap:break-word}:host #vertical-scroll-content-clipper.normal{display:none}:host #vertical-scroll-content-clipper.sticky{display:block;z-index:20;position:fixed;top:0;width:100%;height:var(--sticky-stop-at, 50px)}:host #table-container{width:100%;overflow-x:auto;border-radius:var(--ptc-border-radius-standard);box-shadow:var(--ptc-shadow-x-small);position:relative}:host #table-body{width:100%;overflow-x:scroll;position:relative}:host .scroll-button{display:flex;align-items:center;position:absolute;z-index:15;height:100%}:host .scroll-button#previous-scroll-button div{margin-right:var(--ptc-element-spacing-02);border-radius:0px var(--ptc-element-spacing-01) var(--ptc-element-spacing-01) 0px}:host .scroll-button#previous-scroll-button div ptc-para{margin-right:var(--ptc-element-spacing-04)}:host .scroll-button#next-scroll-button{transform:translateX(-100%)}:host .scroll-button#next-scroll-button div{margin-left:var(--ptc-element-spacing-02);border-radius:var(--ptc-element-spacing-01) 0px 0px var(--ptc-element-spacing-01)}:host .scroll-button#next-scroll-button div ptc-para{margin-left:var(--ptc-element-spacing-04)}:host .scroll-button div{display:inline-block;width:fit-content;height:36px;background-color:white;color:black;box-shadow:var(--ptc-shadow-x-medium);display:flex;justify-content:center;align-items:center}:host .scroll-button div icon-asset{display:flex;justify-content:center;align-items:center;width:36px;height:100%}:host .scroll-button div ptc-para{display:none;white-space:nowrap}:host .table-filler-cell{display:none;min-width:var(--filler-cell-width, 0px);max-width:var(--filler-cell-width, 0px);height:100%;box-sizing:content-box;padding:var(--ptc-element-spacing-04) var(--ptc-element-spacing-06) var(--ptc-element-spacing-04) var(--ptc-element-spacing-06);border-bottom:1px solid var(--color-gray-02)}:host .table-filler-cell.show{display:table-cell}:host #table-header{display:table-row;background:var(--color-gray-10);color:white;z-index:10}:host #table-header.normal{position:relative}:host #table-header.sticky{position:fixed;top:var(--sticky-stop-at, 50px);border-top-left-radius:var(--ptc-border-radius-standard);border-top-right-radius:var(--ptc-border-radius-standard);overflow-x:hidden;-ms-overflow-style:none;scrollbar-width:none;box-shadow:0 16px 16px -16px grey}:host #table-header.sticky::-webkit-scrollbar{display:none}:host #table-header .table-cell{min-width:var(--cell-width-xxs, 180px);max-width:var(--cell-width-xxs, 180px);box-sizing:content-box;padding:var(--ptc-element-spacing-04) var(--ptc-element-spacing-06) var(--ptc-element-spacing-04) var(--ptc-element-spacing-06);border-right:1px solid var(--color-gray-07);text-align:center;display:table-cell;vertical-align:middle}:host #table-header .table-cell.table-last-cell{border-right:none}:host #table-header .table-cell ptc-link a.ptc-link{line-height:var(--ptc-line-height-p)}:host #table-header .table-filler-cell{border-bottom:none;border-left:1px solid var(--color-gray-07)}:host #table-header-placeholder.normal{position:absolute;top:0;display:table-row;opacity:0}:host #table-header-placeholder.sticky{position:relative;display:table-row;opacity:0;overflow-x:hidden;-ms-overflow-style:none;scrollbar-width:none}:host #table-header-placeholder .table-cell{min-width:var(--cell-width-xxs, 180px);max-width:var(--cell-width-xxs, 180px);box-sizing:content-box;padding:var(--ptc-element-spacing-04) var(--ptc-element-spacing-06) var(--ptc-element-spacing-04) var(--ptc-element-spacing-06);border-right:1px solid var(--color-gray-07);text-align:center;display:table-cell;vertical-align:middle}:host #table-header-placeholder .table-cell.table-last-cell{border-right:none}:host #table-header-placeholder .table-filler-cell{border-bottom:none;border-left:1px solid var(--color-gray-07)}:host .desktop-header-first-cell{display:table-cell;position:sticky;left:0;z-index:10}:host .mobile-sticky-row-header{display:block;position:sticky;left:0;background-color:var(--color-gray-01);border-bottom:1px solid var(--color-gray-02);padding:var(--ptc-element-spacing-04) var(--ptc-element-spacing-06) var(--ptc-element-spacing-04) var(--ptc-element-spacing-06)}:host .table-row{display:table-row;background-color:white}:host .table-row .table-cell{min-width:var(--cell-width-xxs, 180px);max-width:var(--cell-width-xxs, 180px);box-sizing:content-box;padding:var(--ptc-element-spacing-04) var(--ptc-element-spacing-06) var(--ptc-element-spacing-04) var(--ptc-element-spacing-06);border-right:1px solid var(--color-gray-02);border-bottom:1px solid var(--color-gray-02);text-align:center;display:table-cell;vertical-align:middle}:host .table-row .table-cell.table-last-cell{border-right:none}:host .table-row .table-filler-cell{border-left:1px solid var(--color-gray-02)}:host .table-cta-row{display:table-row;background-color:white}:host .table-cta-row .table-cell{min-width:var(--cell-width-xxs, 180px);max-width:var(--cell-width-xxs, 180px);box-sizing:content-box;padding:var(--ptc-element-spacing-06);border-right:1px solid var(--color-gray-02);border-bottom:1px solid var(--color-gray-02);text-align:center;display:table-cell;vertical-align:middle}:host .table-cta-row .table-cell.table-last-cell{border-right:none}:host .table-cta-row .table-filler-cell{border-left:1px solid var(--color-gray-02)}@media only screen and (min-width: 768px){:host .table-descriptor{max-width:768px;margin:auto}}@media only screen and (min-width: 992px){:host .scroll-button{height:100%;top:0}:host .scroll-button div ptc-para{display:none}:host .scroll-button div:hover{cursor:pointer}:host .scroll-button div:hover ptc-para{display:block}:host .scroll-button#previous-scroll-button{right:0;transform:translateX(100%)}:host #horizontal-scroll-shadow{display:block;position:absolute;top:0;left:0;height:100%;width:var(--ptc-element-spacing-06);background:linear-gradient(90deg, rgba(0, 0, 0, 0.12) 0%, rgba(0, 0, 0, 0) 100%);z-index:1}:host #table-header.sticky{box-shadow:none}:host #table-header .table-cell{min-width:var(--cell-width-md, 225px);max-width:var(--cell-width-md, 225px)}:host #table-header .last-column-tooltip .tooltip{right:4px}:host #table-header-placeholder .table-cell{min-width:var(--cell-width-md, 225px);max-width:var(--cell-width-md, 225px)}:host #table-header-placeholder .last-column-tooltip .tooltip{right:-4px}:host .desktop-sticky-row-header{min-width:var(--desktop-row-header-cell-width-md, 275px);max-width:var(--desktop-row-header-cell-width-md, 275px);box-sizing:content-box;padding:var(--ptc-element-spacing-04) var(--ptc-element-spacing-06) var(--ptc-element-spacing-04) var(--ptc-element-spacing-06);border-right:1px solid var(--color-gray-02);border-bottom:1px solid var(--color-gray-02);display:table-cell;vertical-align:middle;position:sticky;left:0;background-color:white;z-index:5}:host .desktop-sticky-row-header.desktop-alternate-row{background-color:var(--color-gray-01)}:host .desktop-header-first-cell{min-width:var(--desktop-row-header-cell-width-md, 275px);max-width:var(--desktop-row-header-cell-width-md, 275px);box-sizing:content-box;padding:var(--ptc-element-spacing-04) var(--ptc-element-spacing-06) var(--ptc-element-spacing-04) var(--ptc-element-spacing-06);border-right:1px solid var(--color-gray-07);display:table-cell;vertical-align:middle;position:sticky;left:0;z-index:10;background:var(--color-gray-10)}:host .table-row .table-cell{min-width:var(--cell-width-md, 225px);max-width:var(--cell-width-md, 225px)}:host .table-row.desktop-alternate-row{background-color:var(--color-gray-01)}:host .mobile-sticky-row-header{display:none}:host .table-cta-row{display:table-row}:host .table-cta-row .table-cell{min-width:var(--cell-width-md, 225px);max-width:var(--cell-width-md, 225px)}:host .table-cta-row .last-column-tooltip .tooltip{right:-4px}}";export{s as ptc_pricing_packaging_table}