@ptcwebops/ptcw-design 4.6.8 → 4.6.9
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/dist/cjs/homepage-jumbotron.cjs.entry.js +9 -2
- package/dist/cjs/homepage-toggled-content.cjs.entry.js +1 -1
- package/dist/cjs/icon-asset_8.cjs.entry.js +1 -1
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/most-popular-news.cjs.entry.js +1 -1
- package/dist/cjs/my-component.cjs.entry.js +1 -1
- package/dist/cjs/ptc-collapse-list.cjs.entry.js +1 -1
- package/dist/cjs/ptc-form-checkbox_2.cjs.entry.js +1 -1
- package/dist/cjs/ptc-homepage-image-feature.cjs.entry.js +1 -1
- package/dist/cjs/ptc-info-tile.cjs.entry.js +1 -1
- package/dist/cjs/ptc-link.cjs.entry.js +1 -1
- package/dist/cjs/ptc-media-card.cjs.entry.js +1 -1
- package/dist/cjs/ptc-multi-select_2.cjs.entry.js +1 -1
- package/dist/cjs/ptc-pricing-packaging-table.cjs.entry.js +1 -1
- package/dist/cjs/ptc-pricing-tabs.cjs.entry.js +1 -1
- package/dist/cjs/ptcw-design.cjs.js +1 -1
- package/dist/cjs/{utils-fe61106d.js → utils-1e19654c.js} +25 -0
- package/dist/collection/components/organism-bundles/homepage-jumbotron/homepage-jumbotron.css +15 -8
- package/dist/collection/components/organism-bundles/homepage-jumbotron/homepage-jumbotron.js +14 -1
- package/dist/collection/components/ptc-info-tile/ptc-info-tile.css +38 -8
- package/dist/collection/utils/utils.js +17 -11
- package/dist/custom-elements/index.js +212 -182
- package/dist/esm/homepage-jumbotron.entry.js +9 -2
- package/dist/esm/homepage-toggled-content.entry.js +1 -1
- package/dist/esm/icon-asset_8.entry.js +1 -1
- package/dist/esm/loader.js +1 -1
- package/dist/esm/most-popular-news.entry.js +1 -1
- package/dist/esm/my-component.entry.js +1 -1
- package/dist/esm/ptc-collapse-list.entry.js +1 -1
- package/dist/esm/ptc-form-checkbox_2.entry.js +1 -1
- package/dist/esm/ptc-homepage-image-feature.entry.js +1 -1
- package/dist/esm/ptc-info-tile.entry.js +1 -1
- package/dist/esm/ptc-link.entry.js +1 -1
- package/dist/esm/ptc-media-card.entry.js +1 -1
- package/dist/esm/ptc-multi-select_2.entry.js +1 -1
- package/dist/esm/ptc-pricing-packaging-table.entry.js +1 -1
- package/dist/esm/ptc-pricing-tabs.entry.js +1 -1
- package/dist/esm/ptcw-design.js +1 -1
- package/dist/esm/{utils-4a9e39a7.js → utils-c3e38928.js} +25 -1
- package/dist/ptcw-design/{p-90d50eb8.entry.js → p-0a48b79e.entry.js} +1 -1
- package/dist/ptcw-design/p-0b7eba48.entry.js +1 -0
- package/dist/ptcw-design/{p-8938268f.entry.js → p-2927fcf2.entry.js} +1 -1
- package/dist/ptcw-design/{p-7fdadf0d.entry.js → p-2c0b813f.entry.js} +1 -1
- package/dist/ptcw-design/{p-62be464f.entry.js → p-4145c884.entry.js} +1 -1
- package/dist/ptcw-design/{p-3c560782.entry.js → p-6e93bbc6.entry.js} +1 -1
- package/dist/ptcw-design/p-76f916a8.js +1 -0
- package/dist/ptcw-design/{p-50f94166.entry.js → p-7c1508be.entry.js} +1 -1
- package/dist/ptcw-design/{p-b9bf864e.entry.js → p-81e07694.entry.js} +1 -1
- package/dist/ptcw-design/{p-74f53c15.entry.js → p-9fea5f19.entry.js} +1 -1
- package/dist/ptcw-design/p-c365ff37.entry.js +1 -0
- package/dist/ptcw-design/{p-388bab26.entry.js → p-d0f1693d.entry.js} +1 -1
- package/dist/ptcw-design/{p-e6f6c3c8.entry.js → p-d1bec2b4.entry.js} +1 -1
- package/dist/ptcw-design/{p-91efd911.entry.js → p-d7b6d68a.entry.js} +1 -1
- package/dist/ptcw-design/{p-029d283d.entry.js → p-f26024bf.entry.js} +1 -1
- package/dist/ptcw-design/ptcw-design.esm.js +1 -1
- package/dist/types/components/organism-bundles/homepage-jumbotron/homepage-jumbotron.d.ts +2 -0
- package/dist/types/utils/utils.d.ts +1 -1
- package/package.json +1 -1
- package/readme.md +1 -1
- package/dist/ptcw-design/p-5b5e8973.entry.js +0 -1
- package/dist/ptcw-design/p-b8fd8532.js +0 -1
- package/dist/ptcw-design/p-bd58f3d2.entry.js +0 -1
package/dist/collection/components/organism-bundles/homepage-jumbotron/homepage-jumbotron.css
CHANGED
|
@@ -801,6 +801,19 @@ ptc-link, ptc-square-card,
|
|
|
801
801
|
margin-right: 0px;
|
|
802
802
|
}
|
|
803
803
|
|
|
804
|
+
@media screen and (min-width: 992px) {
|
|
805
|
+
.swiper-container .swiper-wrapper {
|
|
806
|
+
justify-content: space-between;
|
|
807
|
+
}
|
|
808
|
+
|
|
809
|
+
.swiper-slide {
|
|
810
|
+
flex: 1;
|
|
811
|
+
margin-right: 24px;
|
|
812
|
+
}
|
|
813
|
+
.swiper-slide:last-of-type {
|
|
814
|
+
margin-right: 0px;
|
|
815
|
+
}
|
|
816
|
+
}
|
|
804
817
|
@media screen and (min-width: 1200px) {
|
|
805
818
|
.swiper-container {
|
|
806
819
|
max-width: 1136px;
|
|
@@ -809,10 +822,7 @@ ptc-link, ptc-square-card,
|
|
|
809
822
|
}
|
|
810
823
|
|
|
811
824
|
.swiper-slide {
|
|
812
|
-
margin-right:
|
|
813
|
-
}
|
|
814
|
-
.swiper-slide:last-of-type {
|
|
815
|
-
margin-right: 0px;
|
|
825
|
+
margin-right: 32px;
|
|
816
826
|
}
|
|
817
827
|
}
|
|
818
828
|
@media screen and (min-width: 1440px) {
|
|
@@ -823,10 +833,7 @@ ptc-link, ptc-square-card,
|
|
|
823
833
|
}
|
|
824
834
|
|
|
825
835
|
.swiper-slide {
|
|
826
|
-
margin-right:
|
|
827
|
-
}
|
|
828
|
-
.swiper-slide:last-of-type {
|
|
829
|
-
margin-right: 0px;
|
|
836
|
+
margin-right: 40px;
|
|
830
837
|
}
|
|
831
838
|
}
|
|
832
839
|
.swiper-button-next,
|
package/dist/collection/components/organism-bundles/homepage-jumbotron/homepage-jumbotron.js
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { h, Host } from '@stencil/core';
|
|
2
|
+
import { equalizeHeights } from '../../../utils/utils';
|
|
2
3
|
import Swiper from 'swiper';
|
|
3
4
|
import 'swiper/swiper-bundle.css';
|
|
4
5
|
export class HomepageJumbotron {
|
|
@@ -19,12 +20,18 @@ export class HomepageJumbotron {
|
|
|
19
20
|
this.isTransitioning = undefined;
|
|
20
21
|
this.mediaTag = "VIDEO";
|
|
21
22
|
}
|
|
23
|
+
handleWindowResize() {
|
|
24
|
+
equalizeHeights('ptc-info-tile', this.el);
|
|
25
|
+
}
|
|
22
26
|
componentWillLoad() {
|
|
23
27
|
this.updateDefaultContent();
|
|
24
28
|
}
|
|
25
29
|
componentDidLoad() {
|
|
26
30
|
this.initSlider();
|
|
27
31
|
}
|
|
32
|
+
componentDidRender() {
|
|
33
|
+
equalizeHeights('ptc-info-tile', this.el);
|
|
34
|
+
}
|
|
28
35
|
initSlider() {
|
|
29
36
|
if (this.swiperContainerRef) {
|
|
30
37
|
this.mySwiper = new Swiper(this.swiperContainerRef, {
|
|
@@ -43,7 +50,7 @@ export class HomepageJumbotron {
|
|
|
43
50
|
spaceBetween: 0,
|
|
44
51
|
},
|
|
45
52
|
1200: {
|
|
46
|
-
width:
|
|
53
|
+
//width:1080,
|
|
47
54
|
initialSlide: 1,
|
|
48
55
|
slidesPerView: 3,
|
|
49
56
|
spaceBetween: 0,
|
|
@@ -242,6 +249,12 @@ export class HomepageJumbotron {
|
|
|
242
249
|
static get elementRef() { return "el"; }
|
|
243
250
|
static get listeners() {
|
|
244
251
|
return [{
|
|
252
|
+
"name": "resize",
|
|
253
|
+
"method": "handleWindowResize",
|
|
254
|
+
"target": "window",
|
|
255
|
+
"capture": false,
|
|
256
|
+
"passive": true
|
|
257
|
+
}, {
|
|
245
258
|
"name": "itemSelected",
|
|
246
259
|
"method": "onItemSelected",
|
|
247
260
|
"target": undefined,
|
|
@@ -57,6 +57,11 @@ ptc-link, ptc-square-card,
|
|
|
57
57
|
:host {
|
|
58
58
|
display: block;
|
|
59
59
|
}
|
|
60
|
+
@media screen and (min-width: 992px) {
|
|
61
|
+
:host {
|
|
62
|
+
flex: 1;
|
|
63
|
+
}
|
|
64
|
+
}
|
|
60
65
|
|
|
61
66
|
.tile {
|
|
62
67
|
position: relative;
|
|
@@ -69,20 +74,44 @@ ptc-link, ptc-square-card,
|
|
|
69
74
|
height: 116px;
|
|
70
75
|
}
|
|
71
76
|
.tile.image {
|
|
72
|
-
width:
|
|
77
|
+
width: 299px;
|
|
73
78
|
display: flex;
|
|
74
79
|
flex-wrap: nowrap;
|
|
75
80
|
flex-direction: row;
|
|
76
|
-
align-items:
|
|
81
|
+
align-items: stretch;
|
|
77
82
|
margin: 0 auto;
|
|
78
83
|
box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
|
|
84
|
+
max-width: unset;
|
|
85
|
+
height: 100%;
|
|
86
|
+
min-height: 140px;
|
|
87
|
+
}
|
|
88
|
+
@media screen and (min-width: 992px) {
|
|
89
|
+
.tile.image {
|
|
90
|
+
width: unset;
|
|
91
|
+
min-width: 299px;
|
|
92
|
+
}
|
|
93
|
+
}
|
|
94
|
+
@media screen and (min-width: 1440px) {
|
|
95
|
+
.tile.image {
|
|
96
|
+
min-height: 116px;
|
|
97
|
+
}
|
|
98
|
+
}
|
|
99
|
+
.tile.image .tile-image {
|
|
100
|
+
flex: 0 0 120px;
|
|
101
|
+
display: flex;
|
|
102
|
+
align-items: center;
|
|
103
|
+
overflow: hidden;
|
|
79
104
|
}
|
|
80
105
|
.tile.image .tile-content {
|
|
81
106
|
border-bottom: 2px solid var(--color-white);
|
|
82
107
|
background: #FFF;
|
|
83
|
-
height:
|
|
108
|
+
height: 100%;
|
|
84
109
|
text-align: left;
|
|
85
110
|
flex: 1;
|
|
111
|
+
box-sizing: border-box;
|
|
112
|
+
display: flex;
|
|
113
|
+
flex-direction: column;
|
|
114
|
+
justify-content: center;
|
|
86
115
|
}
|
|
87
116
|
.tile.image:hover .tile-content {
|
|
88
117
|
border-bottom: 2px solid var(--Blue-6, #4795CD);
|
|
@@ -104,10 +133,6 @@ ptc-link, ptc-square-card,
|
|
|
104
133
|
background-color: var(--color-gray-01);
|
|
105
134
|
border: 1px solid var(--color-gray-07);
|
|
106
135
|
}
|
|
107
|
-
.tile img {
|
|
108
|
-
width: 120px;
|
|
109
|
-
height: 116px;
|
|
110
|
-
}
|
|
111
136
|
.tile h3 {
|
|
112
137
|
margin: 0;
|
|
113
138
|
font-size: 1.2em;
|
|
@@ -146,7 +171,11 @@ ptc-link, ptc-square-card,
|
|
|
146
171
|
|
|
147
172
|
::slotted(img[slot=tile-image]) {
|
|
148
173
|
width: 120px !important;
|
|
149
|
-
height:
|
|
174
|
+
height: 100% !important;
|
|
175
|
+
object-fit: cover;
|
|
176
|
+
display: block;
|
|
177
|
+
max-height: 100%;
|
|
178
|
+
position: absolute;
|
|
150
179
|
}
|
|
151
180
|
|
|
152
181
|
::slotted(h3[slot=tile-title]) {
|
|
@@ -165,4 +194,5 @@ ptc-link, ptc-square-card,
|
|
|
165
194
|
font-weight: var(--ptc-font-weight-bold) !important;
|
|
166
195
|
line-height: var(--ptc-line-height-p) !important;
|
|
167
196
|
text-align: left !important;
|
|
197
|
+
margin-bottom: 0px !important;
|
|
168
198
|
}
|
|
@@ -118,22 +118,28 @@ export function seoSlotReset(element) {
|
|
|
118
118
|
}
|
|
119
119
|
}
|
|
120
120
|
// for elements in the light dom
|
|
121
|
-
export function equalizeHeights(selector) {
|
|
122
|
-
|
|
123
|
-
|
|
121
|
+
export function equalizeHeights(selector, elem) {
|
|
122
|
+
let elements = elem.querySelectorAll(selector);
|
|
123
|
+
console.log('element: ' + elements[0].tagName);
|
|
124
|
+
//reset height
|
|
125
|
+
elements.forEach((element) => {
|
|
126
|
+
element.style.removeProperty('height');
|
|
127
|
+
});
|
|
124
128
|
let tallestHeight = 0;
|
|
125
|
-
//
|
|
126
|
-
elements.forEach(element => {
|
|
129
|
+
// Find the tallest element
|
|
130
|
+
elements.forEach((element) => {
|
|
127
131
|
const height = element.offsetHeight;
|
|
128
|
-
if (height > tallestHeight) {
|
|
132
|
+
if (height > tallestHeight && element.classList.contains('hydrated')) {
|
|
129
133
|
tallestHeight = height;
|
|
130
134
|
}
|
|
131
135
|
});
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
136
|
+
if (tallestHeight > 0) {
|
|
137
|
+
// Set all elements to the tallest height
|
|
138
|
+
elements.forEach((element) => {
|
|
139
|
+
element.style.height = `${tallestHeight}px`;
|
|
140
|
+
});
|
|
141
|
+
//return true;
|
|
142
|
+
}
|
|
137
143
|
}
|
|
138
144
|
//for elements in the shadow dom
|
|
139
145
|
export function equalizeHeightsWithinShadow(selector, shadowRootOrHostElement) {
|