@ptcwebops/ptcw-design 2.7.9 → 2.8.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/ptc-filter-dropdown_4.cjs.entry.js +70 -25
- package/dist/cjs/ptc-filter-level-theater.cjs.entry.js +2 -2
- package/dist/cjs/ptc-minimized-nav.cjs.entry.js +1 -1
- package/dist/cjs/ptc-modal-quiz.cjs.entry.js +23 -14
- package/dist/cjs/ptc-pricing-add-on-card.cjs.entry.js +1 -1
- package/dist/cjs/ptc-pricing-packaging-table.cjs.entry.js +2 -2
- package/dist/cjs/ptc-theater-video-modal.cjs.entry.js +9 -5
- package/dist/cjs/ptcw-design.cjs.js +1 -1
- package/dist/collection/components/ptc-filter-level-theater/ptc-filter-level-theater.css +17 -0
- package/dist/collection/components/ptc-filter-level-theater/ptc-filter-level-theater.js +1 -1
- package/dist/collection/components/ptc-minimized-nav/ptc-minimized-nav.css +6 -12
- package/dist/collection/components/ptc-modal-quiz/ptc-modal-quiz.css +1 -0
- package/dist/collection/components/ptc-modal-quiz/ptc-modal-quiz.js +22 -13
- package/dist/collection/components/ptc-pricing-add-on-card/ptc-pricing-add-on-card.js +1 -1
- package/dist/collection/components/ptc-pricing-packaging-table/ptc-pricing-packaging-table.js +2 -2
- package/dist/collection/components/ptc-theater-video/ptc-theater-video.js +53 -12
- package/dist/collection/components/ptc-theater-video-modal/ptc-theater-video-modal.css +29 -3
- package/dist/collection/components/ptc-theater-video-modal/ptc-theater-video-modal.js +10 -5
- package/dist/collection/components/ptc-theater-video-playlist/ptc-theater-video-playlist.js +85 -19
- package/dist/custom-elements/index.js +111 -53
- package/dist/esm/loader.js +1 -1
- package/dist/esm/ptc-filter-dropdown_4.entry.js +70 -25
- package/dist/esm/ptc-filter-level-theater.entry.js +2 -2
- package/dist/esm/ptc-minimized-nav.entry.js +1 -1
- package/dist/esm/ptc-modal-quiz.entry.js +23 -14
- package/dist/esm/ptc-pricing-add-on-card.entry.js +1 -1
- package/dist/esm/ptc-pricing-packaging-table.entry.js +2 -2
- package/dist/esm/ptc-theater-video-modal.entry.js +9 -5
- package/dist/esm/ptcw-design.js +1 -1
- package/dist/ptcw-design/p-1af5de53.entry.js +1 -0
- package/dist/ptcw-design/p-28f642a0.entry.js +1 -0
- package/dist/ptcw-design/p-2c5b80ad.entry.js +1 -0
- package/dist/ptcw-design/p-4c1bc7f2.entry.js +1 -0
- package/dist/ptcw-design/{p-b701d9be.entry.js → p-5e38a498.entry.js} +1 -1
- package/dist/ptcw-design/p-e21c0fa1.entry.js +1 -0
- package/dist/ptcw-design/p-f00b4b73.entry.js +1 -0
- package/dist/ptcw-design/ptcw-design.esm.js +1 -1
- package/dist/types/components/ptc-modal-quiz/ptc-modal-quiz.d.ts +1 -0
- package/dist/types/components/ptc-theater-video/ptc-theater-video.d.ts +10 -7
- package/dist/types/components/ptc-theater-video-modal/ptc-theater-video-modal.d.ts +1 -0
- package/dist/types/components/ptc-theater-video-playlist/ptc-theater-video-playlist.d.ts +14 -0
- package/dist/types/components.d.ts +15 -6
- package/package.json +1 -1
- package/readme.md +1 -1
- package/dist/ptcw-design/p-03d6c8f4.entry.js +0 -1
- package/dist/ptcw-design/p-405f9284.entry.js +0 -1
- package/dist/ptcw-design/p-98e44593.entry.js +0 -1
- package/dist/ptcw-design/p-c58c3218.entry.js +0 -1
- package/dist/ptcw-design/p-d6645d4e.entry.js +0 -1
- package/dist/ptcw-design/p-f363d813.entry.js +0 -1
|
@@ -5628,7 +5628,7 @@ Credits to Dave Berning
|
|
|
5628
5628
|
}
|
|
5629
5629
|
}
|
|
5630
5630
|
.modal .modal-container .v-modal-left {
|
|
5631
|
-
background-color: #
|
|
5631
|
+
background-color: #323b42;
|
|
5632
5632
|
padding: 24px;
|
|
5633
5633
|
margin: 0 -24px;
|
|
5634
5634
|
}
|
|
@@ -5681,7 +5681,7 @@ Credits to Dave Berning
|
|
|
5681
5681
|
max-height: 460px;
|
|
5682
5682
|
overflow-y: auto;
|
|
5683
5683
|
padding-right: 13px;
|
|
5684
|
-
color: #
|
|
5684
|
+
color: #fff;
|
|
5685
5685
|
}
|
|
5686
5686
|
@media only screen and (min-width: 1200px) {
|
|
5687
5687
|
.modal .modal-container .video-modal-description {
|
|
@@ -5696,10 +5696,36 @@ Credits to Dave Berning
|
|
|
5696
5696
|
border-radius: 4px;
|
|
5697
5697
|
}
|
|
5698
5698
|
.modal .modal-container .video-modal-description::-webkit-scrollbar-track {
|
|
5699
|
-
background-color: #
|
|
5699
|
+
background-color: #3e4a52;
|
|
5700
5700
|
border-radius: 4px;
|
|
5701
5701
|
}
|
|
5702
5702
|
.modal .modal-container .video-modal-description::-webkit-scrollbar-thumb {
|
|
5703
5703
|
background-color: #819099;
|
|
5704
5704
|
border-radius: 4px;
|
|
5705
|
+
}
|
|
5706
|
+
.modal.modal-only-video .modal-wrapper {
|
|
5707
|
+
width: 90vw;
|
|
5708
|
+
position: relative;
|
|
5709
|
+
}
|
|
5710
|
+
@media only screen and (min-width: 768px) {
|
|
5711
|
+
.modal.modal-only-video .modal-wrapper {
|
|
5712
|
+
width: 75vw;
|
|
5713
|
+
padding: 40px;
|
|
5714
|
+
}
|
|
5715
|
+
}
|
|
5716
|
+
.modal.modal-only-video .modal-wrapper .vm-close {
|
|
5717
|
+
position: absolute;
|
|
5718
|
+
right: 0;
|
|
5719
|
+
top: -40px;
|
|
5720
|
+
cursor: pointer;
|
|
5721
|
+
}
|
|
5722
|
+
@media only screen and (min-width: 768px) {
|
|
5723
|
+
.modal.modal-only-video .modal-wrapper .vm-close {
|
|
5724
|
+
right: 0;
|
|
5725
|
+
top: 10px;
|
|
5726
|
+
}
|
|
5727
|
+
}
|
|
5728
|
+
.modal.modal-only-video .modal-wrapper .aspect-ratio-container {
|
|
5729
|
+
width: 100%;
|
|
5730
|
+
height: 100%;
|
|
5705
5731
|
}
|
|
@@ -5,6 +5,7 @@ export class PtcTheaterVideoModal {
|
|
|
5
5
|
this.showModal = false;
|
|
6
6
|
this.currentCardIndex = 0;
|
|
7
7
|
this.filteredTagName = undefined;
|
|
8
|
+
this.modalType = undefined;
|
|
8
9
|
}
|
|
9
10
|
// @Listen('filterCliked', { target: 'document' })
|
|
10
11
|
// handleFilterClick(event: CustomEvent) {
|
|
@@ -13,9 +14,10 @@ export class PtcTheaterVideoModal {
|
|
|
13
14
|
// }
|
|
14
15
|
async updateData(data, currentModalIndex) {
|
|
15
16
|
// debugger
|
|
16
|
-
console.log(data);
|
|
17
|
-
console.log(this.filteredTagName);
|
|
17
|
+
// console.log(data);
|
|
18
|
+
// console.log(this.filteredTagName);
|
|
18
19
|
this.cards = data;
|
|
20
|
+
console.log(this.cards);
|
|
19
21
|
// this.cards = data.filter((item) => {
|
|
20
22
|
// const videoTagArr = item.vtagName.split(",").map((j) => j.trim());
|
|
21
23
|
// if (this.filteredTagName !== undefined && this.filteredTagName !== 'reset') {
|
|
@@ -24,8 +26,9 @@ export class PtcTheaterVideoModal {
|
|
|
24
26
|
// return true;
|
|
25
27
|
// }
|
|
26
28
|
// });
|
|
27
|
-
console.log(this.cards);
|
|
29
|
+
// console.log(this.cards);
|
|
28
30
|
console.log(currentModalIndex);
|
|
31
|
+
this.modalType = this.cards[this.currentCardIndex].modalType;
|
|
29
32
|
this.currentCardIndex = currentModalIndex;
|
|
30
33
|
this.showModal = true;
|
|
31
34
|
}
|
|
@@ -71,7 +74,8 @@ export class PtcTheaterVideoModal {
|
|
|
71
74
|
});
|
|
72
75
|
}
|
|
73
76
|
render() {
|
|
74
|
-
return (h(Host, null, h("slot", null), this.showModal &&
|
|
77
|
+
return (h(Host, null, h("slot", null), this.showModal &&
|
|
78
|
+
(this.modalType != 'only-video' ? (h("div", { class: "modal" }, h("div", { class: "modal-container ptc-container" }, h("div", { onClick: () => this.closeCardModal(), class: 'vm-close' }, h("svg", { xmlns: "http://www.w3.org/2000/svg", width: "18", height: "18", viewBox: "0 0 18 18", fill: "none" }, h("g", { "clip-path": "url(#clip0_214_927)" }, h("path", { d: "M18 2.8125L15.1875 0L9 6.1875L2.8125 0L0 2.8125L6.1875 9L0 15.1875L2.8125 18L9 11.8125L15.1875 18L18 15.1875L11.8125 9L18 2.8125Z", fill: "white" })), h("defs", null, h("clipPath", { id: "clip0_214_927" }, h("rect", { width: "18", height: "18", fill: "white" }))))), h("div", { class: "is-grid has-col-gap-xl has-row-gap-lg" }, h("div", { class: 'is-col is-col-7-lg' }, h("div", { class: "v-modal-left" }, h("div", { class: 'v-nav' }, h("button", { onClick: () => this.showPrevCard(), disabled: this.currentCardIndex === 0 }, "Previous Video"), h("div", { class: 'v-number' }, ' ', this.currentCardIndex + 1, " of ", this.cards.length), h("button", { onClick: () => this.showNextCard(), disabled: this.currentCardIndex === this.cards.length - 1 }, "Next Video")), h("div", { class: 'aspect-ratio-container ' }, h("div", { class: 'video-container' }, h("video-js", { id: "bcPlayer", "data-account": "1532789042001", "data-player": "HknUe20R", "data-embed": "default", "data-video-id": this.cards[this.currentCardIndex].videoId, controls: "", "data-application-id": "", class: `dpm-vj-${this.currentCardIndex} video-js vjs-fills` }))), h("div", { class: "card-description-content" }, h("ptc-title", { type: "h3", "title-size": "large", "title-color": "white", upperline: "no-upperline", "title-height": "densest", "title-margin": "margin-flush", "title-weight": "w-7", styles: ".is-standard{margin-top:14px !important}" }, this.cards[this.currentCardIndex].title), h("ptc-para", { "font-size": "medium", "font-weight": "w-4", "para-color": "white", "para-margin": "margin-3", "para-line-h": "line-height-p" }, this.cards[this.currentCardIndex].cardDescription)))), h("div", { class: 'is-col is-col-5-lg' }, h("div", { class: "video-modal-description" }, h("div", { innerHTML: this.cards[this.currentCardIndex].descriptionModal }))))))) : (h("div", { class: "modal modal-only-video" }, h("div", { class: "modal-wrapper" }, h("div", { onClick: () => this.closeCardModal(), class: 'vm-close' }, h("svg", { xmlns: "http://www.w3.org/2000/svg", width: "18", height: "18", viewBox: "0 0 18 18", fill: "none" }, h("g", { "clip-path": "url(#clip0_214_927)" }, h("path", { d: "M18 2.8125L15.1875 0L9 6.1875L2.8125 0L0 2.8125L6.1875 9L0 15.1875L2.8125 18L9 11.8125L15.1875 18L18 15.1875L11.8125 9L18 2.8125Z", fill: "white" })), h("defs", null, h("clipPath", { id: "clip0_214_927" }, h("rect", { width: "18", height: "18", fill: "white" }))))), h("div", { class: 'aspect-ratio-container ' }, h("div", { class: 'video-container' }, h("video-js", { id: "bcPlayer", "data-account": "1532789042001", "data-player": "HknUe20R", "data-embed": "default", "data-video-id": this.cards[this.currentCardIndex].videoId, controls: "", "data-application-id": "", class: `dpm-vj-${this.currentCardIndex} video-js vjs-fills` })))))))));
|
|
75
79
|
}
|
|
76
80
|
static get is() { return "ptc-theater-video-modal"; }
|
|
77
81
|
static get encapsulation() { return "scoped"; }
|
|
@@ -90,7 +94,8 @@ export class PtcTheaterVideoModal {
|
|
|
90
94
|
"cards": {},
|
|
91
95
|
"showModal": {},
|
|
92
96
|
"currentCardIndex": {},
|
|
93
|
-
"filteredTagName": {}
|
|
97
|
+
"filteredTagName": {},
|
|
98
|
+
"modalType": {}
|
|
94
99
|
};
|
|
95
100
|
}
|
|
96
101
|
static get methods() {
|
|
@@ -4,6 +4,10 @@ export class PtcTheaterVideoPlaylist {
|
|
|
4
4
|
this.cards = [];
|
|
5
5
|
this.currentCardIndex = 0;
|
|
6
6
|
this.filteredTagName = undefined;
|
|
7
|
+
this.cardElements = undefined;
|
|
8
|
+
}
|
|
9
|
+
componentWillLoad() {
|
|
10
|
+
this.cardElements = this.host.querySelectorAll('ptc-theater-video');
|
|
7
11
|
}
|
|
8
12
|
componentDidLoad() {
|
|
9
13
|
this.setupCards();
|
|
@@ -13,14 +17,21 @@ export class PtcTheaterVideoPlaylist {
|
|
|
13
17
|
const filters = event.detail;
|
|
14
18
|
this.filteredTagName = filters['selected-tag'];
|
|
15
19
|
this.sortCards(this.filteredTagName);
|
|
16
|
-
this.
|
|
20
|
+
//this.updateCardData(filters.cardNumber)
|
|
21
|
+
}
|
|
22
|
+
handleVCardClickedEvent(event) {
|
|
23
|
+
const filters = event.detail;
|
|
24
|
+
console.log(filters);
|
|
17
25
|
}
|
|
18
26
|
sortCards(filterVideo) {
|
|
19
|
-
const cardElements = this.host.querySelectorAll('ptc-theater-video');
|
|
20
|
-
cardElements.forEach((cardElement) => {
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
27
|
+
//const cardElements = this.host.querySelectorAll('ptc-theater-video');
|
|
28
|
+
this.cardElements.forEach((cardElement) => {
|
|
29
|
+
let tagNames;
|
|
30
|
+
if (cardElement.getAttribute('vtag-name')) {
|
|
31
|
+
tagNames = cardElement.getAttribute('vtag-name').split(",").map((item) => {
|
|
32
|
+
return item.trim();
|
|
33
|
+
});
|
|
34
|
+
}
|
|
24
35
|
const trimFilterVideo = filterVideo.trim();
|
|
25
36
|
if (trimFilterVideo !== "" && trimFilterVideo !== 'reset') {
|
|
26
37
|
if (tagNames.includes(trimFilterVideo)) {
|
|
@@ -39,24 +50,52 @@ export class PtcTheaterVideoPlaylist {
|
|
|
39
50
|
});
|
|
40
51
|
}
|
|
41
52
|
setupCards() {
|
|
42
|
-
|
|
43
|
-
const cardElements = this.host.querySelectorAll('ptc-theater-video');
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
cardDescription: cardElement.cardDescription,
|
|
48
|
-
descriptionModal: cardElement.querySelector('.description').innerHTML,
|
|
49
|
-
videoId: cardElement.getAttribute('video-id'),
|
|
50
|
-
vtagName: cardElement.getAttribute('vtag-name'),
|
|
51
|
-
cardNumber: cardElement.getAttribute('card-number'),
|
|
52
|
-
index: index
|
|
53
|
-
};
|
|
53
|
+
console.log('Setup called');
|
|
54
|
+
// const cardElements = this.host.querySelectorAll('ptc-theater-video');
|
|
55
|
+
// console.log(this.cardElements);
|
|
56
|
+
this.cardElements.forEach((cardElement, index) => {
|
|
57
|
+
this.cards.push(this.setCardData(cardElement, index));
|
|
54
58
|
cardElement.addEventListener('click', () => {
|
|
55
59
|
this.showCardDetails(index);
|
|
56
60
|
});
|
|
57
|
-
this.cards.push(cardData);
|
|
58
61
|
});
|
|
59
62
|
}
|
|
63
|
+
updateCardData(cardNumber) {
|
|
64
|
+
console.log('updateCard called');
|
|
65
|
+
// debugger
|
|
66
|
+
this.cards = [];
|
|
67
|
+
// const cardElements = this.host.querySelectorAll('ptc-theater-video');
|
|
68
|
+
// console.log(this.cardElements);
|
|
69
|
+
this.cardElements.forEach((cardElement, index) => {
|
|
70
|
+
const tagNames = cardElement.getAttribute('vtag-name').split(",").map((item) => {
|
|
71
|
+
return item.trim();
|
|
72
|
+
});
|
|
73
|
+
// this.cards.push(this.setCardData(cardElement, index));
|
|
74
|
+
if (this.filteredTagName !== "" && this.filteredTagName !== 'reset' && this.filteredTagName !== undefined && tagNames.includes(this.filteredTagName)) {
|
|
75
|
+
this.cards.push(this.setCardData(cardElement, index));
|
|
76
|
+
// const cardNumber = parseInt(cardElement.getAttribute('card-number'));
|
|
77
|
+
cardElement.addEventListener('click', () => {
|
|
78
|
+
this.showCardDetails(cardNumber);
|
|
79
|
+
});
|
|
80
|
+
}
|
|
81
|
+
else if (this.filteredTagName === 'reset') {
|
|
82
|
+
this.cards.push(this.setCardData(cardElement, index));
|
|
83
|
+
}
|
|
84
|
+
});
|
|
85
|
+
}
|
|
86
|
+
setCardData(cardElement, index) {
|
|
87
|
+
const cardData = {
|
|
88
|
+
title: cardElement.querySelector('.vcard-title').textContent,
|
|
89
|
+
cardDescription: cardElement.cardDescription,
|
|
90
|
+
descriptionModal: cardElement.querySelector('.description').innerHTML,
|
|
91
|
+
videoId: cardElement.getAttribute('video-id'),
|
|
92
|
+
vtagName: cardElement.getAttribute('vtag-name'),
|
|
93
|
+
cardNumber: cardElement.getAttribute('card-number'),
|
|
94
|
+
index: index,
|
|
95
|
+
modalType: cardElement.getAttribute('modal-type')
|
|
96
|
+
};
|
|
97
|
+
return cardData;
|
|
98
|
+
}
|
|
60
99
|
showCardDetails(index) {
|
|
61
100
|
this.currentCardIndex = index;
|
|
62
101
|
// this.showModal = true;
|
|
@@ -80,6 +119,27 @@ export class PtcTheaterVideoPlaylist {
|
|
|
80
119
|
"$": ["ptc-theater-video-playlist.css"]
|
|
81
120
|
};
|
|
82
121
|
}
|
|
122
|
+
static get properties() {
|
|
123
|
+
return {
|
|
124
|
+
"cardElements": {
|
|
125
|
+
"type": "any",
|
|
126
|
+
"mutable": false,
|
|
127
|
+
"complexType": {
|
|
128
|
+
"original": "any",
|
|
129
|
+
"resolved": "any",
|
|
130
|
+
"references": {}
|
|
131
|
+
},
|
|
132
|
+
"required": false,
|
|
133
|
+
"optional": false,
|
|
134
|
+
"docs": {
|
|
135
|
+
"tags": [],
|
|
136
|
+
"text": ""
|
|
137
|
+
},
|
|
138
|
+
"attribute": "card-elements",
|
|
139
|
+
"reflect": false
|
|
140
|
+
}
|
|
141
|
+
};
|
|
142
|
+
}
|
|
83
143
|
static get states() {
|
|
84
144
|
return {
|
|
85
145
|
"currentCardIndex": {},
|
|
@@ -94,6 +154,12 @@ export class PtcTheaterVideoPlaylist {
|
|
|
94
154
|
"target": "document",
|
|
95
155
|
"capture": false,
|
|
96
156
|
"passive": false
|
|
157
|
+
}, {
|
|
158
|
+
"name": "vCardClicked",
|
|
159
|
+
"method": "handleVCardClickedEvent",
|
|
160
|
+
"target": "document",
|
|
161
|
+
"capture": false,
|
|
162
|
+
"passive": false
|
|
97
163
|
}];
|
|
98
164
|
}
|
|
99
165
|
}
|