@posiwise/resource-module 0.0.184 → 0.0.185

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 (105) hide show
  1. package/fesm2022/{posiwise-resource-module-base-top-banner.component-DwVBOTwY.mjs → posiwise-resource-module-base-top-banner.component-BxV9TVG1.mjs} +15 -7
  2. package/fesm2022/posiwise-resource-module-base-top-banner.component-BxV9TVG1.mjs.map +1 -0
  3. package/fesm2022/posiwise-resource-module-posiwise-resource-module-DfgyQYhP.mjs +1870 -0
  4. package/fesm2022/posiwise-resource-module-posiwise-resource-module-DfgyQYhP.mjs.map +1 -0
  5. package/fesm2022/posiwise-resource-module-resource-blogs.module-DHqU4Ypf.mjs +68 -0
  6. package/fesm2022/posiwise-resource-module-resource-blogs.module-DHqU4Ypf.mjs.map +1 -0
  7. package/fesm2022/posiwise-resource-module-resource-case-studies.module-DghO167h.mjs +134 -0
  8. package/fesm2022/posiwise-resource-module-resource-case-studies.module-DghO167h.mjs.map +1 -0
  9. package/fesm2022/posiwise-resource-module-resource-events.module-DtZaPh7n.mjs +240 -0
  10. package/fesm2022/posiwise-resource-module-resource-events.module-DtZaPh7n.mjs.map +1 -0
  11. package/fesm2022/posiwise-resource-module-resource-hub.module-jxpqriFN.mjs +241 -0
  12. package/fesm2022/posiwise-resource-module-resource-hub.module-jxpqriFN.mjs.map +1 -0
  13. package/fesm2022/posiwise-resource-module-resource-integrations.module-xg0Ziiw8.mjs +294 -0
  14. package/fesm2022/posiwise-resource-module-resource-integrations.module-xg0Ziiw8.mjs.map +1 -0
  15. package/fesm2022/posiwise-resource-module-resource-post.module-DcudivrB.mjs +314 -0
  16. package/fesm2022/posiwise-resource-module-resource-post.module-DcudivrB.mjs.map +1 -0
  17. package/fesm2022/posiwise-resource-module-resource-release-notes.module-CuQLcCDR.mjs +109 -0
  18. package/fesm2022/posiwise-resource-module-resource-release-notes.module-CuQLcCDR.mjs.map +1 -0
  19. package/fesm2022/posiwise-resource-module-resource-root.module-gVu6s-NV.mjs +398 -0
  20. package/fesm2022/posiwise-resource-module-resource-root.module-gVu6s-NV.mjs.map +1 -0
  21. package/fesm2022/posiwise-resource-module-resource-videos.module-xt6vq-z-.mjs +68 -0
  22. package/fesm2022/posiwise-resource-module-resource-videos.module-xt6vq-z-.mjs.map +1 -0
  23. package/fesm2022/posiwise-resource-module-resource-white-papers.module-Bm2M2II6.mjs +69 -0
  24. package/fesm2022/posiwise-resource-module-resource-white-papers.module-Bm2M2II6.mjs.map +1 -0
  25. package/fesm2022/posiwise-resource-module.mjs +1 -1
  26. package/package.json +6 -6
  27. package/types/posiwise-resource-module.d.ts +521 -0
  28. package/fesm2022/posiwise-resource-module-base-top-banner.component-DwVBOTwY.mjs.map +0 -1
  29. package/fesm2022/posiwise-resource-module-posiwise-resource-module-CBgwfoFQ.mjs +0 -1802
  30. package/fesm2022/posiwise-resource-module-posiwise-resource-module-CBgwfoFQ.mjs.map +0 -1
  31. package/fesm2022/posiwise-resource-module-resource-blogs.module-B4QePTqE.mjs +0 -69
  32. package/fesm2022/posiwise-resource-module-resource-blogs.module-B4QePTqE.mjs.map +0 -1
  33. package/fesm2022/posiwise-resource-module-resource-case-studies.module-FVdm2xZg.mjs +0 -133
  34. package/fesm2022/posiwise-resource-module-resource-case-studies.module-FVdm2xZg.mjs.map +0 -1
  35. package/fesm2022/posiwise-resource-module-resource-events.module-D39_eKV0.mjs +0 -228
  36. package/fesm2022/posiwise-resource-module-resource-events.module-D39_eKV0.mjs.map +0 -1
  37. package/fesm2022/posiwise-resource-module-resource-hub.module-BtDEZ2Bi.mjs +0 -233
  38. package/fesm2022/posiwise-resource-module-resource-hub.module-BtDEZ2Bi.mjs.map +0 -1
  39. package/fesm2022/posiwise-resource-module-resource-integrations.module-Ccc_gL-v.mjs +0 -284
  40. package/fesm2022/posiwise-resource-module-resource-integrations.module-Ccc_gL-v.mjs.map +0 -1
  41. package/fesm2022/posiwise-resource-module-resource-post.module-DK-IjPjS.mjs +0 -294
  42. package/fesm2022/posiwise-resource-module-resource-post.module-DK-IjPjS.mjs.map +0 -1
  43. package/fesm2022/posiwise-resource-module-resource-release-notes.module-BCZ7rBO3.mjs +0 -104
  44. package/fesm2022/posiwise-resource-module-resource-release-notes.module-BCZ7rBO3.mjs.map +0 -1
  45. package/fesm2022/posiwise-resource-module-resource-root.module-XqP-FANH.mjs +0 -392
  46. package/fesm2022/posiwise-resource-module-resource-root.module-XqP-FANH.mjs.map +0 -1
  47. package/fesm2022/posiwise-resource-module-resource-videos.module-CVimxK4w.mjs +0 -69
  48. package/fesm2022/posiwise-resource-module-resource-videos.module-CVimxK4w.mjs.map +0 -1
  49. package/fesm2022/posiwise-resource-module-resource-white-papers.module-0VUIWx4N.mjs +0 -70
  50. package/fesm2022/posiwise-resource-module-resource-white-papers.module-0VUIWx4N.mjs.map +0 -1
  51. package/index.d.ts +0 -19
  52. package/lib/public/components/base/base-resource.component.d.ts +0 -43
  53. package/lib/public/components/base/base-top-banner.component.d.ts +0 -38
  54. package/lib/public/components/reslease-note-card/release-note-card.component.d.ts +0 -57
  55. package/lib/public/components/resource-blogs/resource-blog-top-banner/resource-blog-top-banner.component.d.ts +0 -12
  56. package/lib/public/components/resource-blogs/resource-blog.component.d.ts +0 -11
  57. package/lib/public/components/resource-case-studies/case-studies-cards/case-studies-cards.component.d.ts +0 -40
  58. package/lib/public/components/resource-case-studies/resource-case-studies.component.d.ts +0 -20
  59. package/lib/public/components/resource-company-card/resource-company-card.component.d.ts +0 -39
  60. package/lib/public/components/resource-contact-us/resource-contact-us.module.d.ts +0 -7
  61. package/lib/public/components/resource-edit-card/resource-edit-card.component.d.ts +0 -52
  62. package/lib/public/components/resource-edit-card-lazy/resource-edit-card-lazy.component.d.ts +0 -19
  63. package/lib/public/components/resource-integration/integration-top-banner/integration-top-banner.component.d.ts +0 -12
  64. package/lib/public/components/resource-integration/resource-integration.component.d.ts +0 -89
  65. package/lib/public/components/resource-post/related-resources/related-resources.component.d.ts +0 -46
  66. package/lib/public/components/resource-post/related-resources/resource-cards/resource-cards.component.d.ts +0 -40
  67. package/lib/public/components/resource-post/resource-post-details/resource-post-details.component.d.ts +0 -71
  68. package/lib/public/components/resource-post/resource-post.component.d.ts +0 -17
  69. package/lib/public/components/resource-release-notes/resource-release-notes-top-banner/resource-release-notes-top-banner.component.d.ts +0 -12
  70. package/lib/public/components/resource-release-notes/resource-release-notes.component.d.ts +0 -23
  71. package/lib/public/components/resource-top-banner-edit/resource-top-banner-edit.component.d.ts +0 -37
  72. package/lib/public/components/resource-vault/resource-vault.component.d.ts +0 -23
  73. package/lib/public/components/resource-videos/resource-video-cards/resource-video-cards.component.d.ts +0 -48
  74. package/lib/public/components/resource-videos/resource-videos-top-banner/resource-videos-top-banner.component.d.ts +0 -12
  75. package/lib/public/components/resource-videos/resource-videos.component.d.ts +0 -11
  76. package/lib/public/components/resource-webinars/replay-event-cards/replay-event-cards.component.d.ts +0 -33
  77. package/lib/public/components/resource-webinars/resource-webinars.component.d.ts +0 -36
  78. package/lib/public/components/resource-webinars/upcoming-event-cards/upcoming-event-cards.component.d.ts +0 -44
  79. package/lib/public/components/resources/resource-tags/resource-tags.component.d.ts +0 -31
  80. package/lib/public/components/resources/resources.component.d.ts +0 -24
  81. package/lib/public/components/resources/vault-section/vault-section.component.d.ts +0 -54
  82. package/lib/public/components/resources-hub/resources-hub.component.d.ts +0 -52
  83. package/lib/public/components/testimonial-card/testimonial-card.component.d.ts +0 -14
  84. package/lib/public/components/white-papers/white-papers-top-banner/white-papers-top-banner.component.d.ts +0 -12
  85. package/lib/public/components/white-papers/white-papers.component.d.ts +0 -11
  86. package/lib/public/modules/blogs/resource-blogs.module.d.ts +0 -10
  87. package/lib/public/modules/case-studies/resource-case-studies.module.d.ts +0 -10
  88. package/lib/public/modules/events/resource-events.module.d.ts +0 -10
  89. package/lib/public/modules/hub/resource-hub.module.d.ts +0 -9
  90. package/lib/public/modules/integrations/resource-integrations.module.d.ts +0 -10
  91. package/lib/public/modules/post/resource-post.module.d.ts +0 -11
  92. package/lib/public/modules/release-notes/resource-release-notes.module.d.ts +0 -10
  93. package/lib/public/modules/root/resource-root-shared.module.d.ts +0 -17
  94. package/lib/public/modules/root/resource-root.module.d.ts +0 -11
  95. package/lib/public/modules/videos/resource-videos.module.d.ts +0 -10
  96. package/lib/public/modules/white-papers/resource-white-papers.module.d.ts +0 -10
  97. package/lib/public/resource-public.module.d.ts +0 -7
  98. package/lib/public/resource-public.routing.module.d.ts +0 -7
  99. package/lib/public/shared/resource-cards.module.d.ts +0 -32
  100. package/lib/public/shared/resource-edit.module.d.ts +0 -22
  101. package/lib/public/shared/resource-shared.module.d.ts +0 -20
  102. package/lib/resource.module.d.ts +0 -7
  103. package/lib/resource.service.d.ts +0 -21
  104. package/lib/shared/models/resource.model.d.ts +0 -3
  105. package/lib/shared/resource-modal.interface.d.ts +0 -6
@@ -1,1802 +0,0 @@
1
- import * as i0 from '@angular/core';
2
- import { Injectable, NgModule, CUSTOM_ELEMENTS_SCHEMA, EventEmitter, ViewContainerRef, Output, Input, ViewChild, Component, ChangeDetectionStrategy } from '@angular/core';
3
- import * as i2 from '@posiwise/common-services';
4
- import { HelperService } from '@posiwise/helper-service';
5
- import * as i1 from '@angular/router';
6
- import { RouterModule } from '@angular/router';
7
- import { Trial4SharedContactUsModule } from '@posiwise/resource-contact-us';
8
- import * as i3 from '@angular/common';
9
- import { CommonModule } from '@angular/common';
10
- import * as i1$1 from '@angular/forms';
11
- import { FormsModule, ReactiveFormsModule } from '@angular/forms';
12
- import { HubSpotMeetingsSharedModule } from '@posiwise/alpha-module';
13
- import { CoreTranslocoModule } from '@posiwise/core-transloco';
14
- import * as i8 from '@posiwise/directives';
15
- import { DirectivesModule } from '@posiwise/directives';
16
- import { PipesModule } from '@posiwise/pipes';
17
- import * as i6 from '@posiwise/shared-components';
18
- import { ResourceSharedComponentsModule } from '@posiwise/shared-components';
19
- import { InputTextModule } from 'primeng/inputtext';
20
- import { InputTextarea } from 'primeng/inputtextarea';
21
- import * as i10 from '@jsverse/transloco';
22
- import { TranslocoModule } from '@jsverse/transloco';
23
- import { AppBaseComponent } from '@posiwise/app-base-component';
24
- import { Subject } from 'rxjs';
25
- import * as i5 from 'primeng/paginator';
26
- import { PaginatorModule } from 'primeng/paginator';
27
- import * as i2$1 from '@ng-bootstrap/ng-bootstrap';
28
- import * as i6$1 from '@posiwise/utils';
29
- import { DragDropModule } from '@angular/cdk/drag-drop';
30
- import { NgxCaptchaModule } from 'ngx-captcha';
31
- import { SelectModule } from 'primeng/select';
32
- import * as i7 from 'primeng/progressspinner';
33
- import * as i3$1 from '@angular/platform-browser';
34
- import * as i11 from 'ngx-quill';
35
- import { QuillModule } from 'ngx-quill';
36
- import * as i12 from 'ngx-ui-switch';
37
- import { UiSwitchModule } from 'ngx-ui-switch';
38
- import * as i7$1 from 'primeng/autocomplete';
39
- import { AutoCompleteModule } from 'primeng/autocomplete';
40
- import * as i6$2 from 'primeng/calendar';
41
- import { CalendarModule } from 'primeng/calendar';
42
- import moment from 'moment';
43
-
44
- class ResourceService {
45
- constructor(api) {
46
- this.api = api;
47
- this.resource = '/posts';
48
- this.comments = '/comments';
49
- }
50
- getPublicPosts(master_subscription_id, page, pageSize, search, tagCategoryIds, tagIds) {
51
- const params = {
52
- page,
53
- page_size: pageSize,
54
- search: search,
55
- master_subscription_id
56
- };
57
- if (tagCategoryIds) {
58
- params['tag_category_ids'] = tagCategoryIds;
59
- }
60
- if (tagIds) {
61
- params['tag_ids'] = tagIds;
62
- }
63
- return this.api.getWithParams(`${this.resource}/get_all`, {
64
- ...params
65
- });
66
- }
67
- getAdminPosts(subscriptionId, paging) {
68
- return this.api.getWithParams(`${this.resource}/admin_get_all`, {
69
- ...HelperService.getPagingParams(paging),
70
- subscription_id: subscriptionId
71
- });
72
- }
73
- addPost(post) {
74
- const formData = new FormData();
75
- // eslint-disable-next-line no-restricted-syntax
76
- for (const key in post) {
77
- if (key in post) {
78
- formData.append(key, post[key]);
79
- }
80
- }
81
- return this.api.post(this.resource, formData);
82
- }
83
- getPostBySlug(slug) {
84
- return this.api.get(`${this.resource}/${slug}`);
85
- }
86
- deletePost(id) {
87
- return this.api.delete(`${this.resource}/${id}`);
88
- }
89
- updatePost(post, id) {
90
- const formData = new FormData();
91
- // eslint-disable-next-line no-restricted-syntax
92
- for (const key in post) {
93
- if (key in post) {
94
- formData.append(key, post[key]);
95
- }
96
- }
97
- return this.api.put(`${this.resource}/${id}`, formData);
98
- }
99
- getComments() {
100
- return this.api.get(`${this.comments}/get_all`);
101
- }
102
- postComments(post) {
103
- return this.api.post(this.comments, post);
104
- }
105
- getResourceInsight(subscription_id, starting_at, ending_at) {
106
- return this.api.getWithParams(`/admin/posts_analytics?type=views&subscription_id=${subscription_id}`, { starting_at, ending_at });
107
- }
108
- getResourcePostsInsight(id) {
109
- return this.api.get(`${this.resource}/${id}/insights`);
110
- }
111
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: ResourceService, deps: [{ token: i2.MainApiHttpService }], target: i0.ɵɵFactoryTarget.Injectable }); }
112
- static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: ResourceService }); }
113
- }
114
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: ResourceService, decorators: [{
115
- type: Injectable
116
- }], ctorParameters: () => [{ type: i2.MainApiHttpService }] });
117
-
118
- // Lazy loaded routes - each route now loads its own module with only the components it needs
119
- const routes = [
120
- {
121
- path: '',
122
- pathMatch: 'full',
123
- loadChildren: () => import('./posiwise-resource-module-resource-root.module-XqP-FANH.mjs').then(m => m.ResourceRootModule)
124
- },
125
- {
126
- path: 'hub',
127
- loadChildren: () => import('./posiwise-resource-module-resource-hub.module-BtDEZ2Bi.mjs').then(m => m.ResourceHubModule)
128
- },
129
- {
130
- path: 'blogs',
131
- loadChildren: () => import('./posiwise-resource-module-resource-blogs.module-B4QePTqE.mjs').then(m => m.ResourceBlogsModule)
132
- },
133
- {
134
- path: 'videos',
135
- loadChildren: () => import('./posiwise-resource-module-resource-videos.module-CVimxK4w.mjs').then(m => m.ResourceVideosModule)
136
- },
137
- {
138
- path: 'integrations',
139
- loadChildren: () => import('./posiwise-resource-module-resource-integrations.module-Ccc_gL-v.mjs').then(m => m.ResourceIntegrationsModule)
140
- },
141
- {
142
- path: 'release-notes',
143
- loadChildren: () => import('./posiwise-resource-module-resource-release-notes.module-BCZ7rBO3.mjs').then(m => m.ResourceReleaseNotesModule)
144
- },
145
- {
146
- path: 'events',
147
- loadChildren: () => import('./posiwise-resource-module-resource-events.module-D39_eKV0.mjs').then(m => m.ResourceEventsModule)
148
- },
149
- {
150
- path: 'white-papers',
151
- loadChildren: () => import('./posiwise-resource-module-resource-white-papers.module-0VUIWx4N.mjs').then(m => m.ResourceWhitePapersModule)
152
- },
153
- {
154
- path: 'case-studies',
155
- loadChildren: () => import('./posiwise-resource-module-resource-case-studies.module-FVdm2xZg.mjs').then(m => m.ResourceCaseStudiesModule)
156
- },
157
- {
158
- path: 'view/:slug',
159
- loadChildren: () => import('./posiwise-resource-module-resource-post.module-DK-IjPjS.mjs').then(m => m.ResourcePostModule)
160
- }
161
- ];
162
- class BlogPublicRoutingModule {
163
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: BlogPublicRoutingModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
164
- static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "19.2.20", ngImport: i0, type: BlogPublicRoutingModule, imports: [i1.RouterModule], exports: [RouterModule] }); }
165
- static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: BlogPublicRoutingModule, imports: [RouterModule.forChild(routes), RouterModule] }); }
166
- }
167
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: BlogPublicRoutingModule, decorators: [{
168
- type: NgModule,
169
- args: [{
170
- imports: [RouterModule.forChild(routes)],
171
- exports: [RouterModule]
172
- }]
173
- }] });
174
-
175
- class ResourcePublicModule {
176
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: ResourcePublicModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
177
- static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "19.2.20", ngImport: i0, type: ResourcePublicModule, imports: [BlogPublicRoutingModule] }); }
178
- static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: ResourcePublicModule, providers: [ResourceService], imports: [BlogPublicRoutingModule] }); }
179
- }
180
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: ResourcePublicModule, decorators: [{
181
- type: NgModule,
182
- args: [{
183
- imports: [BlogPublicRoutingModule],
184
- providers: [ResourceService],
185
- schemas: [CUSTOM_ELEMENTS_SCHEMA]
186
- }]
187
- }] });
188
-
189
- class ResourceModule {
190
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: ResourceModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
191
- static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "19.2.20", ngImport: i0, type: ResourceModule, imports: [ResourcePublicModule] }); }
192
- static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: ResourceModule, imports: [ResourcePublicModule] }); }
193
- }
194
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: ResourceModule, decorators: [{
195
- type: NgModule,
196
- args: [{
197
- imports: [ResourcePublicModule]
198
- }]
199
- }] });
200
-
201
- class Trial4ContactUsModule {
202
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: Trial4ContactUsModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
203
- static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "19.2.20", ngImport: i0, type: Trial4ContactUsModule, imports: [Trial4SharedContactUsModule], exports: [Trial4SharedContactUsModule] }); }
204
- static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: Trial4ContactUsModule, imports: [Trial4SharedContactUsModule, Trial4SharedContactUsModule] }); }
205
- }
206
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: Trial4ContactUsModule, decorators: [{
207
- type: NgModule,
208
- args: [{
209
- imports: [Trial4SharedContactUsModule],
210
- exports: [Trial4SharedContactUsModule]
211
- }]
212
- }] });
213
-
214
- /**
215
- * Lazy-loading wrapper for ResourceEditCard
216
- */
217
- class ResourceEditCardLazyComponent {
218
- constructor() {
219
- this.canEdit = false;
220
- this.updated = new EventEmitter();
221
- this.componentRef = null;
222
- this.loading = false;
223
- }
224
- async ngOnChanges(changes) {
225
- if (this.canEdit && !this.componentRef && !this.loading) {
226
- await this.loadEditCard();
227
- }
228
- else if (!this.canEdit && this.componentRef) {
229
- this.container.clear();
230
- this.componentRef = null;
231
- }
232
- else if (this.componentRef && (changes['id'] || changes['resourceData'])) {
233
- // Update existing component inputs
234
- this.componentRef.instance.id = this.id;
235
- this.componentRef.instance.resourceData = this.resourceData;
236
- }
237
- }
238
- async loadEditCard() {
239
- if (this.componentRef || this.loading)
240
- return; // Prevent double loading
241
- this.loading = true; // Set BEFORE async operation
242
- try {
243
- // Dynamically import ResourceEditCard component (145 KB)
244
- const module = await Promise.resolve().then(function () { return resourceEditCard_component; });
245
- const ResourceEditCardComponent = module.ResourceEditCardComponent;
246
- // Ensure container exists and is clear
247
- if (!this.container)
248
- return;
249
- this.container.clear();
250
- // Create component dynamically (only once)
251
- this.componentRef = this.container.createComponent(ResourceEditCardComponent);
252
- this.componentRef.instance.id = this.id;
253
- this.componentRef.instance.resourceData = this.resourceData;
254
- this.componentRef.instance.updated.subscribe(() => this.updated.emit());
255
- this.loading = false;
256
- }
257
- catch (error) {
258
- console.error('Failed to load ResourceEditCard:', error);
259
- this.loading = false;
260
- }
261
- }
262
- ngOnDestroy() {
263
- this.componentRef?.destroy();
264
- }
265
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: ResourceEditCardLazyComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
266
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.20", type: ResourceEditCardLazyComponent, isStandalone: false, selector: "pw-resource-edit-card-lazy", inputs: { id: "id", resourceData: "resourceData", canEdit: "canEdit" }, outputs: { updated: "updated" }, viewQueries: [{ propertyName: "container", first: true, predicate: ["editCardContainer"], descendants: true, read: ViewContainerRef, static: true }], usesOnChanges: true, ngImport: i0, template: `<ng-container #editCardContainer></ng-container>`, isInline: true }); }
267
- }
268
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: ResourceEditCardLazyComponent, decorators: [{
269
- type: Component,
270
- args: [{
271
- selector: 'pw-resource-edit-card-lazy',
272
- template: `<ng-container #editCardContainer></ng-container>`,
273
- standalone: false
274
- }]
275
- }], propDecorators: { container: [{
276
- type: ViewChild,
277
- args: ['editCardContainer', { read: ViewContainerRef, static: true }]
278
- }], id: [{
279
- type: Input
280
- }], resourceData: [{
281
- type: Input
282
- }], canEdit: [{
283
- type: Input
284
- }], updated: [{
285
- type: Output
286
- }] } });
287
-
288
- class ResourceCompanyCardComponent extends AppBaseComponent {
289
- constructor(injector) {
290
- super(injector);
291
- this.getPosts = new EventEmitter();
292
- this.destroy$ = new Subject();
293
- this.canEditResourcesValue = false;
294
- this.header = '';
295
- this.data = [];
296
- this.vendor = false;
297
- this.postData = false;
298
- this.filteredData = [];
299
- this.first = 0;
300
- this.rows = 12;
301
- }
302
- ngOnChanges() {
303
- this.search();
304
- }
305
- ngOnInit() {
306
- if (this.userLoggedIn) {
307
- this.updateCanEditResourcesValue();
308
- this.localStorage.getItem$('product').subscribe(res => {
309
- const data = res ? JSON.parse(res) : null;
310
- this.subscriptionId = data?.subscriptionId;
311
- });
312
- }
313
- }
314
- search(keywords) {
315
- if (keywords) {
316
- this.filteredData = this.data.filter(x => x.title.toLowerCase().includes(keywords.toLowerCase()));
317
- if (this.filteredData.length === 0) {
318
- this.postData = true;
319
- }
320
- else {
321
- this.postData = false;
322
- }
323
- }
324
- else {
325
- this.filteredData = [...this.data];
326
- this.postData = false;
327
- }
328
- }
329
- onPageChange(event) {
330
- this.first = event.first;
331
- this.rows = event.rows;
332
- }
333
- ngOnDestroy() {
334
- this.destroy$.next();
335
- this.destroy$.complete();
336
- }
337
- updateCanEditResourcesValue() {
338
- this.canEditResourcesValue = HelperService.canEditResources(this.user, this.userLoggedIn, this.permissionService);
339
- }
340
- canEditResources() {
341
- return this.canEditResourcesValue;
342
- }
343
- /** Show no-data when there is integration count but no posts (postData is false, filteredData empty). */
344
- get showNoPostsMessage() {
345
- return (this.integrationCountDisplay > 0 &&
346
- !this.postData &&
347
- (!this.filteredData || this.filteredData.length === 0));
348
- }
349
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: ResourceCompanyCardComponent, deps: [{ token: i0.Injector }], target: i0.ɵɵFactoryTarget.Component }); }
350
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.20", type: ResourceCompanyCardComponent, isStandalone: false, selector: "pw-resource-company-card", inputs: { header: "header", data: "data", integrationCountDisplay: "integrationCountDisplay", vendor: "vendor", user: "user", userLoggedIn: "userLoggedIn" }, outputs: { getPosts: "getPosts" }, usesInheritance: true, usesOnChanges: true, ngImport: i0, template: "<div [ngClass]=\"{ 'vendors-distributor-wrapper': !vendor }\">\n <div class=\"d-flex justify-content-between align-items-center mb-3 search-container\">\n <div>\n <span class=\"int-span\">{{header}}</span>\n </div>\n <div class=\"search-wrapper position-relative\" *ngIf=\"integrationCountDisplay > 0\">\n <i class=\"fa fa-search search-icon\"></i>\n <input type=\"text\"\n\n (keyup)=\"search($event.target.value)\"\n placeholder=\"Search eg security\"\n class=\"search-input top-search-input\" id=\"input_search_eg_security_9712\" name=\"input_search_eg_security_9712\" />\n </div>\n\n </div>\n\n <div *ngIf=\"postData\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Search.NoDataMessage' | transloco\"> </pw-no-data>\n </div>\n\n <div *ngIf=\"showNoPostsMessage\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Resource.NoDataMessage' | transloco\"></pw-no-data>\n </div>\n\n <div class=\"row\" *ngIf=\"!postData && integrationCountDisplay > 0 && filteredData.length > 0\">\n <div class=\"col-md-3 mt-4\"\n *ngFor=\"let img of filteredData | slice:first:(first + rows)\">\n <div class=\"boxes d-flex align-items-center justify-content-center\">\n <ng-container *ngIf=\"img?.companyImg; else checkRectangular\">\n <img [src]=\"img.companyImg\" alt=\"Vendor Company Icon\" class=\"vendor-icon\" />\n </ng-container>\n\n <ng-template #checkRectangular>\n <ng-container *ngIf=\"img?.rectangular_picture?.url; else noImage\">\n <ng-container *ngIf=\"!img.rectangular_picture.url.includes('default-photo'); else showPostName\">\n <ng-container *ngIf=\"img?.showcase; else noLinkImage\">\n <a class=\"vendor-link\" [href]=\"img.external_url || ('/resources/view/' + img.slug)\">\n <img [src]=\"img.rectangular_picture.url\" alt=\"Vendor Rectangular Company Icon\" class=\"vendor-icon\" />\n </a>\n </ng-container>\n <ng-template #noLinkImage>\n <img [src]=\"img.rectangular_picture.url\" alt=\"Vendor Rectangular Company Icon\" class=\"vendor-icon\" />\n </ng-template>\n\n <pw-resource-edit-card-lazy\n [canEdit]=\"canEditResourcesValue\"\n [id]=\"img?.id\"\n [resourceData]=\"img\"\n (updated)=\"getPosts.emit()\">\n </pw-resource-edit-card-lazy>\n </ng-container>\n </ng-container>\n </ng-template>\n\n <ng-template #showPostName>\n <ng-container *ngIf=\"img?.showcase; else noLinkTitle\">\n <a class=\"vendor-link\" [href]=\"img.external_url || ('/resources/view/' + img.slug)\">\n <span class=\"vendor-name text-center mt-2\">{{ img?.title }}</span>\n </a>\n </ng-container>\n <ng-template #noLinkTitle>\n <span class=\"vendor-name text-center\">{{ img?.title }}</span>\n </ng-template>\n\n <pw-resource-edit-card-lazy\n [canEdit]=\"canEditResourcesValue\"\n [id]=\"img?.id\"\n [resourceData]=\"img\"\n (updated)=\"getPosts.emit()\">\n </pw-resource-edit-card-lazy>\n </ng-template>\n </div>\n </div>\n\n <div class=\"customPaginator d-flex align-items-center mt-5 justify-content-center\"\n *ngIf=\"filteredData.length > 0\"\n >\n <p-paginator\n [first]=\"first\"\n [rows]=\"rows\"\n [totalRecords]=\"filteredData.length\"\n (onPageChange)=\"onPageChange($event)\"></p-paginator>\n </div>\n </div>\n</div>\n", styles: [".top-search-input{color:#000!important;border:3px solid #d4d4d4!important;padding:5px 30px!important;border-radius:29px!important}::placeholder{color:#d4d4d4}.vendors-distributor-wrapper{margin-top:5rem!important}.vendor-icon{max-width:180px;max-height:100%;width:100%!important}.vendor-name{font-size:3rem;line-height:3rem;color:var(--text-color, black)}::ng-deep .customPaginator .p-paginator{border:none!important}::ng-deep .customPaginator .p-paginator button{border:none!important}.int-span{text-transform:uppercase;font-size:2.5rem;color:var(--first)}.boxes{width:100%;min-height:150px;display:flex;align-items:center;justify-content:center;text-align:center;padding:15px;border:1px dashed #ccc;border-radius:8px;word-break:break-word;white-space:normal;height:100%}a.vendor-link{display:inline-block;transition:transform .2s ease}a.vendor-link:hover{transform:scale(1.05);cursor:pointer}.search-wrapper{position:relative;width:300px}.search-input{width:100%;padding:10px 20px 10px 40px;border:2px solid #d4d4d4;border-radius:30px;font-size:1rem;color:#000;background-color:#fff}.search-input::placeholder{color:silver}.search-input:focus{outline:none;border-color:var(--first)}.search-icon{position:absolute;top:50%;left:14px;transform:translateY(-50%);color:#d4d4d4;font-size:1.1rem}@media (width <= 768px){.vendor-icon{width:50!important}.search-container{flex-wrap:wrap!important;gap:2rem}.int-span{font-size:1.75rem}}\n"], dependencies: [{ kind: "directive", type: i3.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i3.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i3.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i6.NoDataComponent, selector: "pw-no-data", inputs: ["message", "description", "withImage"] }, { kind: "directive", type: i8.LazyImgDirective, selector: "img" }, { kind: "component", type: ResourceEditCardLazyComponent, selector: "pw-resource-edit-card-lazy", inputs: ["id", "resourceData", "canEdit"], outputs: ["updated"] }, { kind: "component", type: i5.Paginator, selector: "p-paginator", inputs: ["pageLinkSize", "style", "styleClass", "alwaysShow", "dropdownAppendTo", "templateLeft", "templateRight", "appendTo", "dropdownScrollHeight", "currentPageReportTemplate", "showCurrentPageReport", "showFirstLastIcon", "totalRecords", "rows", "rowsPerPageOptions", "showJumpToPageDropdown", "showJumpToPageInput", "jumpToPageItemTemplate", "showPageLinks", "locale", "dropdownItemTemplate", "first"], outputs: ["onPageChange"] }, { kind: "pipe", type: i3.SlicePipe, name: "slice" }, { kind: "pipe", type: i10.TranslocoPipe, name: "transloco" }] }); }
351
- }
352
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: ResourceCompanyCardComponent, decorators: [{
353
- type: Component,
354
- args: [{ selector: 'pw-resource-company-card', standalone: false, template: "<div [ngClass]=\"{ 'vendors-distributor-wrapper': !vendor }\">\n <div class=\"d-flex justify-content-between align-items-center mb-3 search-container\">\n <div>\n <span class=\"int-span\">{{header}}</span>\n </div>\n <div class=\"search-wrapper position-relative\" *ngIf=\"integrationCountDisplay > 0\">\n <i class=\"fa fa-search search-icon\"></i>\n <input type=\"text\"\n\n (keyup)=\"search($event.target.value)\"\n placeholder=\"Search eg security\"\n class=\"search-input top-search-input\" id=\"input_search_eg_security_9712\" name=\"input_search_eg_security_9712\" />\n </div>\n\n </div>\n\n <div *ngIf=\"postData\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Search.NoDataMessage' | transloco\"> </pw-no-data>\n </div>\n\n <div *ngIf=\"showNoPostsMessage\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Resource.NoDataMessage' | transloco\"></pw-no-data>\n </div>\n\n <div class=\"row\" *ngIf=\"!postData && integrationCountDisplay > 0 && filteredData.length > 0\">\n <div class=\"col-md-3 mt-4\"\n *ngFor=\"let img of filteredData | slice:first:(first + rows)\">\n <div class=\"boxes d-flex align-items-center justify-content-center\">\n <ng-container *ngIf=\"img?.companyImg; else checkRectangular\">\n <img [src]=\"img.companyImg\" alt=\"Vendor Company Icon\" class=\"vendor-icon\" />\n </ng-container>\n\n <ng-template #checkRectangular>\n <ng-container *ngIf=\"img?.rectangular_picture?.url; else noImage\">\n <ng-container *ngIf=\"!img.rectangular_picture.url.includes('default-photo'); else showPostName\">\n <ng-container *ngIf=\"img?.showcase; else noLinkImage\">\n <a class=\"vendor-link\" [href]=\"img.external_url || ('/resources/view/' + img.slug)\">\n <img [src]=\"img.rectangular_picture.url\" alt=\"Vendor Rectangular Company Icon\" class=\"vendor-icon\" />\n </a>\n </ng-container>\n <ng-template #noLinkImage>\n <img [src]=\"img.rectangular_picture.url\" alt=\"Vendor Rectangular Company Icon\" class=\"vendor-icon\" />\n </ng-template>\n\n <pw-resource-edit-card-lazy\n [canEdit]=\"canEditResourcesValue\"\n [id]=\"img?.id\"\n [resourceData]=\"img\"\n (updated)=\"getPosts.emit()\">\n </pw-resource-edit-card-lazy>\n </ng-container>\n </ng-container>\n </ng-template>\n\n <ng-template #showPostName>\n <ng-container *ngIf=\"img?.showcase; else noLinkTitle\">\n <a class=\"vendor-link\" [href]=\"img.external_url || ('/resources/view/' + img.slug)\">\n <span class=\"vendor-name text-center mt-2\">{{ img?.title }}</span>\n </a>\n </ng-container>\n <ng-template #noLinkTitle>\n <span class=\"vendor-name text-center\">{{ img?.title }}</span>\n </ng-template>\n\n <pw-resource-edit-card-lazy\n [canEdit]=\"canEditResourcesValue\"\n [id]=\"img?.id\"\n [resourceData]=\"img\"\n (updated)=\"getPosts.emit()\">\n </pw-resource-edit-card-lazy>\n </ng-template>\n </div>\n </div>\n\n <div class=\"customPaginator d-flex align-items-center mt-5 justify-content-center\"\n *ngIf=\"filteredData.length > 0\"\n >\n <p-paginator\n [first]=\"first\"\n [rows]=\"rows\"\n [totalRecords]=\"filteredData.length\"\n (onPageChange)=\"onPageChange($event)\"></p-paginator>\n </div>\n </div>\n</div>\n", styles: [".top-search-input{color:#000!important;border:3px solid #d4d4d4!important;padding:5px 30px!important;border-radius:29px!important}::placeholder{color:#d4d4d4}.vendors-distributor-wrapper{margin-top:5rem!important}.vendor-icon{max-width:180px;max-height:100%;width:100%!important}.vendor-name{font-size:3rem;line-height:3rem;color:var(--text-color, black)}::ng-deep .customPaginator .p-paginator{border:none!important}::ng-deep .customPaginator .p-paginator button{border:none!important}.int-span{text-transform:uppercase;font-size:2.5rem;color:var(--first)}.boxes{width:100%;min-height:150px;display:flex;align-items:center;justify-content:center;text-align:center;padding:15px;border:1px dashed #ccc;border-radius:8px;word-break:break-word;white-space:normal;height:100%}a.vendor-link{display:inline-block;transition:transform .2s ease}a.vendor-link:hover{transform:scale(1.05);cursor:pointer}.search-wrapper{position:relative;width:300px}.search-input{width:100%;padding:10px 20px 10px 40px;border:2px solid #d4d4d4;border-radius:30px;font-size:1rem;color:#000;background-color:#fff}.search-input::placeholder{color:silver}.search-input:focus{outline:none;border-color:var(--first)}.search-icon{position:absolute;top:50%;left:14px;transform:translateY(-50%);color:#d4d4d4;font-size:1.1rem}@media (width <= 768px){.vendor-icon{width:50!important}.search-container{flex-wrap:wrap!important;gap:2rem}.int-span{font-size:1.75rem}}\n"] }]
355
- }], ctorParameters: () => [{ type: i0.Injector }], propDecorators: { getPosts: [{
356
- type: Output
357
- }], header: [{
358
- type: Input
359
- }], data: [{
360
- type: Input
361
- }], integrationCountDisplay: [{
362
- type: Input
363
- }], vendor: [{
364
- type: Input
365
- }], user: [{
366
- type: Input
367
- }], userLoggedIn: [{
368
- type: Input
369
- }] } });
370
-
371
- class ResourceTopBannerEditComponent extends AppBaseComponent {
372
- constructor(fb, modalService, tagService, injector) {
373
- super(injector);
374
- this.fb = fb;
375
- this.modalService = modalService;
376
- this.tagService = tagService;
377
- this.getUpdatedTag = new EventEmitter();
378
- this.image = null;
379
- this.defaultImage = 'assets/img/resource/blog.png';
380
- }
381
- ngOnInit() {
382
- if (this.userLoggedIn) {
383
- this.localStorage.getItem$('product').subscribe(res => {
384
- const data = res ? JSON.parse(res) : null;
385
- this.subscriptionId = data?.subscriptionId;
386
- });
387
- }
388
- this.form = this.fb.group({
389
- title: [this.blogPostTag?.title ?? ''],
390
- description: [this.blogPostTag?.description ?? ''],
391
- meta_title: [this.blogPostTag?.meta_title ?? ''],
392
- meta_description: [this.blogPostTag?.meta_description ?? '']
393
- });
394
- this.image = this.blogPostTag?.image?.url ?? null;
395
- }
396
- openEditModal() {
397
- this.modalService.open(this.editModal, { centered: true, size: 'lg' });
398
- }
399
- openImageModal(modalRef) {
400
- this.imageModalRef = this.modalService.open(modalRef, { centered: true });
401
- }
402
- onImageSelected(base64) {
403
- this.image = base64;
404
- this.file = HelperService.convertBase64ToFile(base64);
405
- this.imageModalRef?.close();
406
- }
407
- onClose() {
408
- this.imageModalRef?.close();
409
- }
410
- removeImage() {
411
- this.image = null;
412
- }
413
- handleImageError(event) {
414
- event.target.src = this.defaultImage;
415
- }
416
- save() {
417
- this.buttonBusy = true;
418
- const payload = {
419
- title: this.form.value.title ?? this.blogPostTag?.title,
420
- description: this.form.value.description ?? this.blogPostTag?.description,
421
- meta_title: this.form.value.meta_title ?? this.blogPostTag?.meta_title,
422
- meta_description: this.form.value.meta_description ?? this.blogPostTag?.meta_description,
423
- tag_category_id: this.blogPostTag?.tag_category_id,
424
- tag_type: this.blogPostTag?.tag_type,
425
- subscription_id: this.subscriptionId,
426
- name: this.blogPostTag?.name
427
- };
428
- if (this.file) {
429
- payload['image'] = this.file;
430
- }
431
- else if (!this.image) {
432
- payload['remove_image'] = true;
433
- }
434
- this.tagService.updateTagById(this.blogPostTag?.id, payload).subscribe(() => {
435
- this.buttonBusy = false;
436
- this.toast.success('Tag Updated');
437
- this.getUpdatedTag.emit();
438
- this.modalService.dismissAll();
439
- });
440
- }
441
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: ResourceTopBannerEditComponent, deps: [{ token: i1$1.FormBuilder }, { token: i2$1.NgbModal }, { token: i2.TagService }, { token: i0.Injector }], target: i0.ɵɵFactoryTarget.Component }); }
442
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.20", type: ResourceTopBannerEditComponent, isStandalone: false, selector: "pw-resource-top-banner-edit", inputs: { blogPostTag: "blogPostTag", user: "user", userLoggedIn: "userLoggedIn" }, outputs: { getUpdatedTag: "getUpdatedTag" }, viewQueries: [{ propertyName: "editModal", first: true, predicate: ["editModal"], descendants: true }, { propertyName: "imageCropContent", first: true, predicate: ["imageCropContent"], descendants: true }], usesInheritance: true, ngImport: i0, template: "<div class=\"edit-card\">\n <i class=\"fa fa-edit cursor-pointer text-black in-page-edit-icon mb-1 ms-3\"\n (click)=\"openEditModal()\"\n (keydown.enter)=\"openEditModal()\"\n (keydown.space)=\"openEditModal()\"\n title=\"Edit Blog Tag\"></i>\n</div>\n\n <ng-template #editModal let-modal>\n <div class=\"modal-header\">\n <h5 class=\"modal-title\">Edit Blog Post Tag</h5>\n <button type=\"button\" class=\"btn-close\" aria-label=\"Close\" (click)=\"modal.dismiss()\"></button>\n </div>\n\n <div class=\"modal-body\">\n <form [formGroup]=\"form\">\n <div class=\"row\">\n\n <div class=\"col-12\">\n <pw-input-container label=\"Title\" name=\"title\">\n <input type=\"text\" class=\"form-control\" formControlName=\"title\" id=\"input_title_1\" name=\"input_title_1\"/>\n </pw-input-container>\n </div>\n\n <div class=\"col-12\">\n <pw-input-container label=\"Description\" name=\"description\" controlId=\"resource-top-banner-description\">\n <textarea id=\"resource-top-banner-description\" name=\"description\" class=\"form-control\" rows=\"4\" formControlName=\"description\"></textarea>\n </pw-input-container>\n </div>\n\n <div class=\"col-12\">\n <pw-input-container label=\"Meta Title\" name=\"meta_title\">\n <input type=\"text\" class=\"form-control\" formControlName=\"meta_title\" placeholder=\"Meta Title for SEO\" id=\"input_meta_title_2\" name=\"input_meta_title_2\"/>\n </pw-input-container>\n </div>\n\n <div class=\"col-12\">\n <pw-input-container label=\"Meta Description\" name=\"meta_description\" controlId=\"resource-top-banner-meta_description\">\n <textarea id=\"resource-top-banner-meta_description\" name=\"meta_description\" class=\"form-control\" rows=\"3\" formControlName=\"meta_description\" placeholder=\"Meta Description for SEO\"></textarea>\n </pw-input-container>\n </div>\n\n <div class=\"col-12 my-4\">\n <span id=\"resource-top-banner-tag-image-label\" class=\"pw-label-style\">Blog Tag Image</span>\n <div class=\"text-center d-flex flex-column align-items-center col-6\">\n <img [src]=\"image || defaultImage\"\n (click)=\"openImageModal(imageCropContent)\"\n (keydown.enter)=\"openImageModal(imageCropContent)\"\n (keydown.space)=\"openImageModal(imageCropContent)\"\n class=\"image w-100\"\n alt=\"Blog\"\n (error)=\"handleImageError($event)\"\n />\n <div class=\"d-flex justify-content-between align-items-center mt-2\">\n <a class=\"d-inline-block mt-2\"\n (click)=\"openImageModal(imageCropContent)\">\n {{ image ? 'Update' : 'Add' }} Image\n </a>\n <i *ngIf=\"image\"\n class=\"fa fa-trash delete-icon text-danger ms-2 cursor-pointer\"\n title=\"Remove Image\"\n (keydown.enter)=\"removeImage()\"\n (keydown.space)=\"removeImage()\"\n (click)=\"removeImage()\"></i>\n </div>\n </div>\n </div>\n\n </div>\n </form>\n </div>\n\n <div class=\"modal-footer\">\n <button class=\"btn btn-secondary\" (click)=\"modal.dismiss()\">Cancel</button>\n <button class=\"btn btn-primary\" [buttonBusy]=\"buttonBusy\" (click)=\"save()\">Save</button>\n </div>\n </ng-template>\n\n <ng-template #imageCropContent let-modal>\n <div class=\"modal-header\">\n <h5 class=\"modal-title\">Upload Image</h5>\n <button type=\"button\" class=\"btn-close float-end\" aria-label=\"Close\" (click)=\"modal.dismiss()\"></button>\n </div>\n <div class=\"modal-body\">\n <small>You can upload a JPG, GIF, or PNG file. Avoid artwork, celebrities, or copyrighted images.</small>\n <pw-image-cropper\n #cropper\n aspectRatio=\"dynamic\"\n (imageSelectionEvent)=\"onImageSelected($event)\"\n (closeEvent)=\"onClose()\">\n </pw-image-cropper>\n </div>\n </ng-template>\n", dependencies: [{ kind: "directive", type: i3.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1$1.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i1$1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1$1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i1$1.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "component", type: i6$1.ProfileImageCropperComponent, selector: "pw-image-cropper", inputs: ["aspectRatio", "dynamicData"], outputs: ["imageSelectionEvent", "closeEvent", "fileChangeEvent"] }, { kind: "component", type: i6.InputContainerComponent, selector: "pw-input-container", inputs: ["name", "controlId", "useAriaLabelledbyOnly", "label", "labelClass", "tooltipPosition", "required", "errorMsg", "isReadOnly", "showTooltip", "tooltipText", "showTriangle", "afterLabel", "showAfterLabel", "showTriangleText", "isLeftTooltip"] }, { kind: "directive", type: i8.ButtonBusyDirective, selector: "[buttonBusy]", inputs: ["buttonBusy", "busyText"] }, { kind: "directive", type: i8.LazyImgDirective, selector: "img" }] }); }
443
- }
444
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: ResourceTopBannerEditComponent, decorators: [{
445
- type: Component,
446
- args: [{ selector: 'pw-resource-top-banner-edit', standalone: false, template: "<div class=\"edit-card\">\n <i class=\"fa fa-edit cursor-pointer text-black in-page-edit-icon mb-1 ms-3\"\n (click)=\"openEditModal()\"\n (keydown.enter)=\"openEditModal()\"\n (keydown.space)=\"openEditModal()\"\n title=\"Edit Blog Tag\"></i>\n</div>\n\n <ng-template #editModal let-modal>\n <div class=\"modal-header\">\n <h5 class=\"modal-title\">Edit Blog Post Tag</h5>\n <button type=\"button\" class=\"btn-close\" aria-label=\"Close\" (click)=\"modal.dismiss()\"></button>\n </div>\n\n <div class=\"modal-body\">\n <form [formGroup]=\"form\">\n <div class=\"row\">\n\n <div class=\"col-12\">\n <pw-input-container label=\"Title\" name=\"title\">\n <input type=\"text\" class=\"form-control\" formControlName=\"title\" id=\"input_title_1\" name=\"input_title_1\"/>\n </pw-input-container>\n </div>\n\n <div class=\"col-12\">\n <pw-input-container label=\"Description\" name=\"description\" controlId=\"resource-top-banner-description\">\n <textarea id=\"resource-top-banner-description\" name=\"description\" class=\"form-control\" rows=\"4\" formControlName=\"description\"></textarea>\n </pw-input-container>\n </div>\n\n <div class=\"col-12\">\n <pw-input-container label=\"Meta Title\" name=\"meta_title\">\n <input type=\"text\" class=\"form-control\" formControlName=\"meta_title\" placeholder=\"Meta Title for SEO\" id=\"input_meta_title_2\" name=\"input_meta_title_2\"/>\n </pw-input-container>\n </div>\n\n <div class=\"col-12\">\n <pw-input-container label=\"Meta Description\" name=\"meta_description\" controlId=\"resource-top-banner-meta_description\">\n <textarea id=\"resource-top-banner-meta_description\" name=\"meta_description\" class=\"form-control\" rows=\"3\" formControlName=\"meta_description\" placeholder=\"Meta Description for SEO\"></textarea>\n </pw-input-container>\n </div>\n\n <div class=\"col-12 my-4\">\n <span id=\"resource-top-banner-tag-image-label\" class=\"pw-label-style\">Blog Tag Image</span>\n <div class=\"text-center d-flex flex-column align-items-center col-6\">\n <img [src]=\"image || defaultImage\"\n (click)=\"openImageModal(imageCropContent)\"\n (keydown.enter)=\"openImageModal(imageCropContent)\"\n (keydown.space)=\"openImageModal(imageCropContent)\"\n class=\"image w-100\"\n alt=\"Blog\"\n (error)=\"handleImageError($event)\"\n />\n <div class=\"d-flex justify-content-between align-items-center mt-2\">\n <a class=\"d-inline-block mt-2\"\n (click)=\"openImageModal(imageCropContent)\">\n {{ image ? 'Update' : 'Add' }} Image\n </a>\n <i *ngIf=\"image\"\n class=\"fa fa-trash delete-icon text-danger ms-2 cursor-pointer\"\n title=\"Remove Image\"\n (keydown.enter)=\"removeImage()\"\n (keydown.space)=\"removeImage()\"\n (click)=\"removeImage()\"></i>\n </div>\n </div>\n </div>\n\n </div>\n </form>\n </div>\n\n <div class=\"modal-footer\">\n <button class=\"btn btn-secondary\" (click)=\"modal.dismiss()\">Cancel</button>\n <button class=\"btn btn-primary\" [buttonBusy]=\"buttonBusy\" (click)=\"save()\">Save</button>\n </div>\n </ng-template>\n\n <ng-template #imageCropContent let-modal>\n <div class=\"modal-header\">\n <h5 class=\"modal-title\">Upload Image</h5>\n <button type=\"button\" class=\"btn-close float-end\" aria-label=\"Close\" (click)=\"modal.dismiss()\"></button>\n </div>\n <div class=\"modal-body\">\n <small>You can upload a JPG, GIF, or PNG file. Avoid artwork, celebrities, or copyrighted images.</small>\n <pw-image-cropper\n #cropper\n aspectRatio=\"dynamic\"\n (imageSelectionEvent)=\"onImageSelected($event)\"\n (closeEvent)=\"onClose()\">\n </pw-image-cropper>\n </div>\n </ng-template>\n" }]
447
- }], ctorParameters: () => [{ type: i1$1.FormBuilder }, { type: i2$1.NgbModal }, { type: i2.TagService }, { type: i0.Injector }], propDecorators: { blogPostTag: [{
448
- type: Input
449
- }], user: [{
450
- type: Input
451
- }], userLoggedIn: [{
452
- type: Input
453
- }], getUpdatedTag: [{
454
- type: Output
455
- }], editModal: [{
456
- type: ViewChild,
457
- args: ['editModal']
458
- }], imageCropContent: [{
459
- type: ViewChild,
460
- args: ['imageCropContent']
461
- }] } });
462
-
463
- class ResourceNoteCardComponent extends AppBaseComponent {
464
- constructor(injector, resourceService, tagService) {
465
- super(injector);
466
- this.resourceService = resourceService;
467
- this.tagService = tagService;
468
- this.releaseHeader = false;
469
- this.isReleasePress = false;
470
- this.isResource = false;
471
- this.postSlice = false;
472
- this.canEditResourcesValue = false;
473
- this.isLoaded = false;
474
- this.masterSubscriptionId = this.appConfig.master_subscription.subscription_id;
475
- this.postTags = {};
476
- this.releasePosts = {};
477
- }
478
- ngOnInit() {
479
- if (this.userLoggedIn) {
480
- this.localStorage.getItem$('product').subscribe(res => {
481
- const data = res ? JSON.parse(res) : null;
482
- this.subscriptionId = data?.subscriptionId;
483
- });
484
- }
485
- this.getTags();
486
- }
487
- ngOnChanges(changes) {
488
- if (changes['user'] || changes['userLoggedIn']) {
489
- if (this.userLoggedIn && this.user) {
490
- this.updateCanEditResourcesValue();
491
- }
492
- }
493
- }
494
- getTags() {
495
- this.isLoaded = false;
496
- this.tagService
497
- .getAllTagCategories({ search: 'Release Notes' }, this.getEffectiveSubscriptionId())
498
- .subscribe(response => {
499
- this.tagCategory = response?.tag_categories?.[0];
500
- this.getPostTags();
501
- });
502
- }
503
- getPostTags() {
504
- this.tagService
505
- .getTagsByType('post_categories', {}, this.getEffectiveSubscriptionId())
506
- .subscribe(response => {
507
- this.postTags['product'] = this.findTag(response.tags, 'Product Release Notes', this.tagCategory?.id);
508
- this.postTags['press'] = this.findTag(response.tags, 'Press Release Notes', this.tagCategory?.id);
509
- if (this.postTags['product']?.id) {
510
- this.getProductReleasePosts(1, 100);
511
- }
512
- else {
513
- this.isLoaded = true;
514
- this.releasePosts['product'] = [];
515
- }
516
- if (this.postTags['press']?.id) {
517
- this.getPressReleasePosts(1, 100);
518
- }
519
- else {
520
- this.isLoaded = true;
521
- this.releasePosts['press'] = [];
522
- }
523
- });
524
- }
525
- findTag(tags, name, categoryId) {
526
- return tags.find(tag => tag.name === name && tag.tag_category_id === categoryId);
527
- }
528
- hasPressReleases() {
529
- return this.releasePosts['press']?.length !== 0 && this.isLoaded;
530
- }
531
- hasProductReleases() {
532
- return this.releasePosts['product']?.length !== 0 && this.isLoaded;
533
- }
534
- getProductReleasePosts(page, pageSize) {
535
- this.isLoaded = false;
536
- this.resourceService
537
- .getPublicPosts(this.getEffectiveSubscriptionId(), page, pageSize, '', '', this.postTags['product']?.id)
538
- .subscribe(response => {
539
- const sortedPosts = response.posts
540
- .filter(post => post.showcase === true)
541
- .sort((a, b) => new Date(b.published_at).getTime() - new Date(a.published_at).getTime());
542
- this.releasePosts['product'] = this.getProcessedPosts(sortedPosts);
543
- })
544
- .add(() => {
545
- this.isLoaded = true;
546
- });
547
- }
548
- getPressReleasePosts(page, pageSize) {
549
- this.isLoaded = false;
550
- this.resourceService
551
- .getPublicPosts(this.getEffectiveSubscriptionId(), page, pageSize, '', '', this.postTags['press']?.id)
552
- .subscribe(response => {
553
- const sortedPosts = response?.posts
554
- .filter(post => post.showcase === true)
555
- .sort((a, b) => new Date(b.published_at).getTime() - new Date(a.published_at).getTime());
556
- this.releasePosts['press'] = this.getProcessedPosts(sortedPosts);
557
- })
558
- .add(() => {
559
- this.isLoaded = true;
560
- });
561
- }
562
- getProcessedPosts(posts, sliceCount = 3) {
563
- const cloned = [...posts];
564
- return this.postSlice ? cloned.reverse() : cloned.slice(0, sliceCount).reverse();
565
- }
566
- toggleEditTitle() {
567
- this.isEditingTitle = true;
568
- this.editedTitle = this.postTags['product'].title;
569
- }
570
- toggleEditPressTitle() {
571
- this.isPressEditingTitle = true;
572
- this.editedTitle = this.postTags['press'].title;
573
- }
574
- saveEditedTitle(type) {
575
- HelperService.updateTagTitle(this.postTags[type], this.editedTitle, this.tagService, this.getEffectiveSubscriptionId(), this.toast).subscribe(() => {
576
- this.postTags[type].title = this.editedTitle;
577
- if (type === 'product') {
578
- this.isEditingTitle = false;
579
- }
580
- else {
581
- this.isPressEditingTitle = false;
582
- }
583
- });
584
- }
585
- /** Helper method to get effective subscription ID */
586
- getEffectiveSubscriptionId() {
587
- return HelperService.getEffectiveSubscriptionId(this.user, this.subscriptionId, this.masterSubscriptionId);
588
- }
589
- updateCanEditResourcesValue() {
590
- this.canEditResourcesValue = HelperService.canEditResources(this.user, this.userLoggedIn, this.permissionService);
591
- }
592
- canEditResources() {
593
- return this.canEditResourcesValue;
594
- }
595
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: ResourceNoteCardComponent, deps: [{ token: i0.Injector }, { token: ResourceService }, { token: i2.TagService }], target: i0.ɵɵFactoryTarget.Component }); }
596
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.20", type: ResourceNoteCardComponent, isStandalone: false, selector: "pw-resource-note-card", inputs: { releaseHeader: "releaseHeader", categoryId: "categoryId", isReleasePress: "isReleasePress", isResource: "isResource", postSlice: "postSlice", resourceTitle: "resourceTitle", tag: "tag", user: "user", userLoggedIn: "userLoggedIn" }, usesInheritance: true, usesOnChanges: true, ngImport: i0, template: "<section class=\"resource-vault-section bg-white\" *ngIf=\"hasProductReleases()\">\n <div class=\"container\">\n <div class=\"d-flex justify-content-between align-items-center flex-wrap\">\n <h2 class=\"section-heading d-flex align-items-center\" [ngClass]=\"{ 'w-50': isEditingTitle }\">\n <ng-container *ngIf=\"!isEditingTitle; else editTitleBlock\">\n <span *ngIf=\"postTags['product']?.title; else fallback\" [innerHTML]=\"postTags['product']?.title\"></span>\n <ng-template #fallback>Product Release Notes</ng-template>\n <i *ngIf=\"canEditResourcesValue\" class=\"fa fa-edit in-page-edit-icon ms-3 cursor-pointer\" (click)=\"toggleEditTitle()\" (keydown.enter)=\"toggleEditTitle()\" (keydown.space)=\"toggleEditTitle()\" title=\"Edit Title\"></i>\n </ng-container>\n\n <ng-template #editTitleBlock>\n <input [(ngModel)]=\"editedTitle\" class=\"form-control d-inline w-auto me-2\" [ngClass]=\"{ 'w-100': isEditingTitle }\" id=\"input_editedTitle_9216\" name=\"input_editedTitle_9216\" />\n <button class=\"btn btn-sm btn-primary me-1\" (click)=\"saveEditedTitle('product')\">Save</button>\n <button class=\"btn btn-sm btn-secondary\" (click)=\"isEditingTitle = false\">Cancel</button>\n </ng-template>\n </h2>\n <a class=\"view-all\" *ngIf=\"!postSlice\" routerLink=\"/resources/release-notes\">VIEW ALL ></a>\n </div>\n <div class=\"w-100 text-center mt-3\" *ngIf=\"!isLoaded\">\n <p-progressSpinner strokeWidth=\"2\"> </p-progressSpinner>\n </div>\n <div *ngIf=\"releasePosts['product']?.length === 0 && isLoaded\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Resource.NoDataMessage' | transloco\"/>\n </div>\n <div class=\"row mt-5 d-flex flex-wrap justify-content-center gap-4 video-row\" *ngIf=\"hasProductReleases()\">\n <div class=\"resource-blog-card p-4\" *ngFor=\"let post of releasePosts['product']\">\n <pw-resource-edit-card-lazy\n [canEdit]=\"canEditResourcesValue\"\n [id]=\"post.id\"\n [resourceData]=\"post\"\n (updated)=\"getProductReleasePosts(1, 100)\">\n </pw-resource-edit-card-lazy>\n <p class=\"resource-title\" [innerHTML]=\"post.title\"></p>\n <img *ngIf=\"!post.picture?.url?.includes('default-photo.jpg'); else resourceRocketBox\"\n src=\"{{ post.picture.url }}\"\n class=\"resource-image mt-auto\"\n alt=\"Product Resource Icon\" />\n\n <ng-template #resourceRocketBox>\n <img\n src=\"assets/img/resource/rocket-box.png\"\n class=\"press-release-icon mt-auto\"\n alt=\"Product Resource Default Icon\" />\n </ng-template>\n <ng-template #ctaContent>\n <span>{{ post?.cta_text && post.cta_text !== 'null' ? post.cta_text : 'Read Now' }}</span>\n <span class=\"arrow\">\u2192</span>\n </ng-template>\n <a *ngIf=\"post?.external_url; else internalLink\"\n class=\"resource-btn mt-3\"\n aria-label=\"Navigate to external url\"\n [href]=\"post.external_url\"\n target=\"_blank\"\n rel=\"noopener noreferrer\">\n <ng-container *ngTemplateOutlet=\"ctaContent\"></ng-container>\n </a>\n\n <ng-template #internalLink>\n <a class=\"resource-btn mt-3\" aria-label=\"Navigate to resource view\" [routerLink]=\"['/resources/view', post?.slug]\">\n <ng-container *ngTemplateOutlet=\"ctaContent\"></ng-container>\n </a>\n </ng-template>\n </div>\n </div>\n </div>\n</section>\n<section class=\"resource-vault-section bg-white\" *ngIf=\"isReleasePress && hasPressReleases()\">\n <div class=\"container\">\n <div class=\"d-flex justify-content-between align-items-center flex-wrap\">\n <h2 class=\"section-heading d-flex align-items-center\" [ngClass]=\"{ 'w-50': isPressEditingTitle }\">\n <ng-container *ngIf=\"!isPressEditingTitle; else editTitleBlock\">\n <span *ngIf=\"postTags['press']?.title; else fallback\" [innerHTML]=\"postTags['press']?.title\"></span>\n <ng-template #fallback>Press Release Notes</ng-template>\n <i *ngIf=\"canEditResourcesValue\" class=\"fa fa-edit in-page-edit-icon ms-3 cursor-pointer\" (click)=\"toggleEditPressTitle()\" (keydown.enter)=\"toggleEditPressTitle()\" (keydown.space)=\"toggleEditPressTitle()\" title=\"Edit Title\"></i>\n </ng-container>\n\n <ng-template #editTitleBlock>\n <input [(ngModel)]=\"editedTitle\" class=\"form-control d-inline w-auto me-2\" [ngClass]=\"{ 'w-100': isPressEditingTitle }\" id=\"input_editedTitle_1600\" name=\"input_editedTitle_1600\" />\n <button class=\"btn btn-sm btn-primary me-1\" (click)=\"saveEditedTitle('press')\">Save</button>\n <button class=\"btn btn-sm btn-secondary\" (click)=\"isPressEditingTitle = false\">Cancel</button>\n </ng-template>\n </h2>\n <a *ngIf=\"!postSlice\" class=\"view-all\" routerLink=\"/resources/release-notes\">VIEW ALL ></a>\n </div>\n <div class=\"w-100 text-center mt-3\" *ngIf=\"!isLoaded\">\n <p-progressSpinner strokeWidth=\"2\"> </p-progressSpinner>\n </div>\n <div *ngIf=\"releasePosts['press']?.length === 0 && isLoaded\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Resource.NoDataMessage' | transloco\"/>\n </div>\n <div class=\"row mt-5 d-flex flex-wrap justify-content-center gap-4 video-row\" *ngIf=\"hasPressReleases()\">\n <div class=\"resource-blog-card p-4\" *ngFor=\"let post of releasePosts['press']\">\n <pw-resource-edit-card-lazy\n [canEdit]=\"canEditResourcesValue\"\n [id]=\"post.id\"\n [resourceData]=\"post\"\n (updated)=\"getPressReleasePosts(1, 100)\">\n </pw-resource-edit-card-lazy>\n <p class=\"resource-title\" [innerHTML]=\"post.title\"></p>\n <img *ngIf=\"!post.picture?.url.includes('default-photo.jpg'); else resourceRocketBox\"\n src=\"{{ post.picture.url }}\"\n class=\"resource-image mt-auto\"\n alt=\"Press Resource Icon\" />\n\n <ng-template #resourceRocketBox>\n <img\n src=\"assets/img/resource/rocket-box.png\"\n class=\"press-release-icon mt-auto\"\n alt=\"Press Resource Default Icon\" />\n </ng-template>\n <a *ngIf=\"post?.external_url; else internalLink\"\n class=\"resource-btn mt-3\"\n aria-label=\"Navigate to external url\"\n [href]=\"post.external_url\"\n target=\"_blank\"\n rel=\"noopener noreferrer\">\n <span>{{ post?.cta_text && post.cta_text !== 'null' ? post.cta_text : 'Read Now' }}</span>\n <span class=\"arrow\">\u2192</span>\n </a>\n\n <ng-template #internalLink>\n <a class=\"resource-btn mt-3\" aria-label=\"Navigate to resource view\" [routerLink]=\"['/resources/view', post?.slug]\">\n <span>{{ post?.cta_text && post.cta_text !== 'null' ? post.cta_text : 'Read Now' }}</span>\n <span class=\"arrow\">\u2192</span>\n </a>\n </ng-template>\n </div>\n </div>\n </div>\n</section>\n\n", styles: [".bold{font-weight:700}.resource-heading{margin-bottom:2rem}.resource-note{margin-top:1rem;font-size:.85rem;color:#555}.resource-divider{border:0;height:40px;width:100%;background:linear-gradient(to bottom,#0000,#00000026);margin:0}.press-release-icon{height:auto!important;margin:0 11px 1.9rem;display:block;align-self:center;width:auto!important;aspect-ratio:0!important;object-fit:cover;margin-top:auto;margin-right:0!important}.resource-vault-section{padding:60px 0;background:#fff;padding-bottom:9rem!important;padding-top:7rem!important;box-shadow:0 4px 32px -14px #40576d4d!important}.resource-vault-section .vault-heading{font-size:3rem;font-weight:300}.resource-vault-section .explore-link{color:#000;font-weight:400;text-decoration:none;font-size:1.5rem}.resource-vault-section .resource-blog-card{display:flex;flex-direction:column;justify-content:space-between;background-color:#fff;border-radius:30px;box-shadow:0 20px 40px #00000014;padding:25px;text-align:center;width:338px;height:auto!important}.resource-vault-section .resource-blog-card h5{font-size:1.5rem;font-weight:400;margin-bottom:.5rem;color:var(--text-color, black)}.resource-vault-section .resource-blog-card p{font-size:1.5rem;color:var(--text-color, black);line-height:2rem}.resource-vault-section .resource-blog-card img{width:100%;border-radius:10px;aspect-ratio:1/1;object-fit:cover;margin-top:auto;margin-right:0!important;max-width:250px!important;align-self:center!important}.resource-vault-section .resource-blog-card iframe{height:210px;border-radius:10px;object-fit:cover;margin-right:0!important;max-width:280px!important}.resource-vault-section .resource-blog-card .resource-btn{background-color:var(--text-color, black);color:#fff;margin-top:auto;padding:10px 24px;border-radius:24px;font-size:1.5rem;font-weight:500;width:100%;max-width:240px;cursor:pointer;transition:background .3s ease;display:flex;justify-content:space-between;align-self:center;align-items:center;text-align:left;text-decoration:none;border:1px solid;box-shadow:none!important;border-color:var(--text-color, black)}.resource-vault-section .resource-blog-card .resource-btn:hover{background:#fff;color:var(--text-color, black)!important}.resource-vault-section .vault-description{text-align:left;max-width:657px;color:#182527;line-height:2.3rem!important;font-size:1.65rem}@media (width <= 1200px){.resource-vault-section .vault-heading{font-size:3.5rem}.resource-vault-section .vault-description{margin-top:1.35rem}.resource-vault-section .resource-btn{margin-left:0!important}}.video-row{gap:5.5rem!important;margin-top:3rem!important}@media (width >= 991px){section.bg-white.text-center.extra-top-padding{position:relative;overflow:hidden}section.bg-white.text-center.extra-top-padding .banner-header{margin-bottom:4rem!important}}.vault-header{text-align:left}@media (width >= 768px) and (width <= 1200px){.container{padding:0 6rem!important}}@media (width <= 768px){.video-row{gap:3rem!important}}@media (max-width: 768px){.resource-vault-section{padding-bottom:6rem!important}.resource-vault-section .container{padding-top:0rem!important;padding-bottom:0rem!important}.vault-header{text-align:center!important}.vault-heading{font-size:3rem!important}}@media (width <= 1200px){.container{padding:7rem 3rem 1rem!important}}\n"], dependencies: [{ kind: "directive", type: i3.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i3.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i3.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i3.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i1.RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "info", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "routerLink"] }, { kind: "directive", type: i1$1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: i6.NoDataComponent, selector: "pw-no-data", inputs: ["message", "description", "withImage"] }, { kind: "component", type: i7.ProgressSpinner, selector: "p-progressSpinner, p-progress-spinner, p-progressspinner", inputs: ["styleClass", "style", "strokeWidth", "fill", "animationDuration", "ariaLabel"] }, { kind: "directive", type: i8.LazyImgDirective, selector: "img" }, { kind: "component", type: ResourceEditCardLazyComponent, selector: "pw-resource-edit-card-lazy", inputs: ["id", "resourceData", "canEdit"], outputs: ["updated"] }, { kind: "pipe", type: i10.TranslocoPipe, name: "transloco" }] }); }
597
- }
598
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: ResourceNoteCardComponent, decorators: [{
599
- type: Component,
600
- args: [{ selector: 'pw-resource-note-card', standalone: false, template: "<section class=\"resource-vault-section bg-white\" *ngIf=\"hasProductReleases()\">\n <div class=\"container\">\n <div class=\"d-flex justify-content-between align-items-center flex-wrap\">\n <h2 class=\"section-heading d-flex align-items-center\" [ngClass]=\"{ 'w-50': isEditingTitle }\">\n <ng-container *ngIf=\"!isEditingTitle; else editTitleBlock\">\n <span *ngIf=\"postTags['product']?.title; else fallback\" [innerHTML]=\"postTags['product']?.title\"></span>\n <ng-template #fallback>Product Release Notes</ng-template>\n <i *ngIf=\"canEditResourcesValue\" class=\"fa fa-edit in-page-edit-icon ms-3 cursor-pointer\" (click)=\"toggleEditTitle()\" (keydown.enter)=\"toggleEditTitle()\" (keydown.space)=\"toggleEditTitle()\" title=\"Edit Title\"></i>\n </ng-container>\n\n <ng-template #editTitleBlock>\n <input [(ngModel)]=\"editedTitle\" class=\"form-control d-inline w-auto me-2\" [ngClass]=\"{ 'w-100': isEditingTitle }\" id=\"input_editedTitle_9216\" name=\"input_editedTitle_9216\" />\n <button class=\"btn btn-sm btn-primary me-1\" (click)=\"saveEditedTitle('product')\">Save</button>\n <button class=\"btn btn-sm btn-secondary\" (click)=\"isEditingTitle = false\">Cancel</button>\n </ng-template>\n </h2>\n <a class=\"view-all\" *ngIf=\"!postSlice\" routerLink=\"/resources/release-notes\">VIEW ALL ></a>\n </div>\n <div class=\"w-100 text-center mt-3\" *ngIf=\"!isLoaded\">\n <p-progressSpinner strokeWidth=\"2\"> </p-progressSpinner>\n </div>\n <div *ngIf=\"releasePosts['product']?.length === 0 && isLoaded\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Resource.NoDataMessage' | transloco\"/>\n </div>\n <div class=\"row mt-5 d-flex flex-wrap justify-content-center gap-4 video-row\" *ngIf=\"hasProductReleases()\">\n <div class=\"resource-blog-card p-4\" *ngFor=\"let post of releasePosts['product']\">\n <pw-resource-edit-card-lazy\n [canEdit]=\"canEditResourcesValue\"\n [id]=\"post.id\"\n [resourceData]=\"post\"\n (updated)=\"getProductReleasePosts(1, 100)\">\n </pw-resource-edit-card-lazy>\n <p class=\"resource-title\" [innerHTML]=\"post.title\"></p>\n <img *ngIf=\"!post.picture?.url?.includes('default-photo.jpg'); else resourceRocketBox\"\n src=\"{{ post.picture.url }}\"\n class=\"resource-image mt-auto\"\n alt=\"Product Resource Icon\" />\n\n <ng-template #resourceRocketBox>\n <img\n src=\"assets/img/resource/rocket-box.png\"\n class=\"press-release-icon mt-auto\"\n alt=\"Product Resource Default Icon\" />\n </ng-template>\n <ng-template #ctaContent>\n <span>{{ post?.cta_text && post.cta_text !== 'null' ? post.cta_text : 'Read Now' }}</span>\n <span class=\"arrow\">\u2192</span>\n </ng-template>\n <a *ngIf=\"post?.external_url; else internalLink\"\n class=\"resource-btn mt-3\"\n aria-label=\"Navigate to external url\"\n [href]=\"post.external_url\"\n target=\"_blank\"\n rel=\"noopener noreferrer\">\n <ng-container *ngTemplateOutlet=\"ctaContent\"></ng-container>\n </a>\n\n <ng-template #internalLink>\n <a class=\"resource-btn mt-3\" aria-label=\"Navigate to resource view\" [routerLink]=\"['/resources/view', post?.slug]\">\n <ng-container *ngTemplateOutlet=\"ctaContent\"></ng-container>\n </a>\n </ng-template>\n </div>\n </div>\n </div>\n</section>\n<section class=\"resource-vault-section bg-white\" *ngIf=\"isReleasePress && hasPressReleases()\">\n <div class=\"container\">\n <div class=\"d-flex justify-content-between align-items-center flex-wrap\">\n <h2 class=\"section-heading d-flex align-items-center\" [ngClass]=\"{ 'w-50': isPressEditingTitle }\">\n <ng-container *ngIf=\"!isPressEditingTitle; else editTitleBlock\">\n <span *ngIf=\"postTags['press']?.title; else fallback\" [innerHTML]=\"postTags['press']?.title\"></span>\n <ng-template #fallback>Press Release Notes</ng-template>\n <i *ngIf=\"canEditResourcesValue\" class=\"fa fa-edit in-page-edit-icon ms-3 cursor-pointer\" (click)=\"toggleEditPressTitle()\" (keydown.enter)=\"toggleEditPressTitle()\" (keydown.space)=\"toggleEditPressTitle()\" title=\"Edit Title\"></i>\n </ng-container>\n\n <ng-template #editTitleBlock>\n <input [(ngModel)]=\"editedTitle\" class=\"form-control d-inline w-auto me-2\" [ngClass]=\"{ 'w-100': isPressEditingTitle }\" id=\"input_editedTitle_1600\" name=\"input_editedTitle_1600\" />\n <button class=\"btn btn-sm btn-primary me-1\" (click)=\"saveEditedTitle('press')\">Save</button>\n <button class=\"btn btn-sm btn-secondary\" (click)=\"isPressEditingTitle = false\">Cancel</button>\n </ng-template>\n </h2>\n <a *ngIf=\"!postSlice\" class=\"view-all\" routerLink=\"/resources/release-notes\">VIEW ALL ></a>\n </div>\n <div class=\"w-100 text-center mt-3\" *ngIf=\"!isLoaded\">\n <p-progressSpinner strokeWidth=\"2\"> </p-progressSpinner>\n </div>\n <div *ngIf=\"releasePosts['press']?.length === 0 && isLoaded\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Resource.NoDataMessage' | transloco\"/>\n </div>\n <div class=\"row mt-5 d-flex flex-wrap justify-content-center gap-4 video-row\" *ngIf=\"hasPressReleases()\">\n <div class=\"resource-blog-card p-4\" *ngFor=\"let post of releasePosts['press']\">\n <pw-resource-edit-card-lazy\n [canEdit]=\"canEditResourcesValue\"\n [id]=\"post.id\"\n [resourceData]=\"post\"\n (updated)=\"getPressReleasePosts(1, 100)\">\n </pw-resource-edit-card-lazy>\n <p class=\"resource-title\" [innerHTML]=\"post.title\"></p>\n <img *ngIf=\"!post.picture?.url.includes('default-photo.jpg'); else resourceRocketBox\"\n src=\"{{ post.picture.url }}\"\n class=\"resource-image mt-auto\"\n alt=\"Press Resource Icon\" />\n\n <ng-template #resourceRocketBox>\n <img\n src=\"assets/img/resource/rocket-box.png\"\n class=\"press-release-icon mt-auto\"\n alt=\"Press Resource Default Icon\" />\n </ng-template>\n <a *ngIf=\"post?.external_url; else internalLink\"\n class=\"resource-btn mt-3\"\n aria-label=\"Navigate to external url\"\n [href]=\"post.external_url\"\n target=\"_blank\"\n rel=\"noopener noreferrer\">\n <span>{{ post?.cta_text && post.cta_text !== 'null' ? post.cta_text : 'Read Now' }}</span>\n <span class=\"arrow\">\u2192</span>\n </a>\n\n <ng-template #internalLink>\n <a class=\"resource-btn mt-3\" aria-label=\"Navigate to resource view\" [routerLink]=\"['/resources/view', post?.slug]\">\n <span>{{ post?.cta_text && post.cta_text !== 'null' ? post.cta_text : 'Read Now' }}</span>\n <span class=\"arrow\">\u2192</span>\n </a>\n </ng-template>\n </div>\n </div>\n </div>\n</section>\n\n", styles: [".bold{font-weight:700}.resource-heading{margin-bottom:2rem}.resource-note{margin-top:1rem;font-size:.85rem;color:#555}.resource-divider{border:0;height:40px;width:100%;background:linear-gradient(to bottom,#0000,#00000026);margin:0}.press-release-icon{height:auto!important;margin:0 11px 1.9rem;display:block;align-self:center;width:auto!important;aspect-ratio:0!important;object-fit:cover;margin-top:auto;margin-right:0!important}.resource-vault-section{padding:60px 0;background:#fff;padding-bottom:9rem!important;padding-top:7rem!important;box-shadow:0 4px 32px -14px #40576d4d!important}.resource-vault-section .vault-heading{font-size:3rem;font-weight:300}.resource-vault-section .explore-link{color:#000;font-weight:400;text-decoration:none;font-size:1.5rem}.resource-vault-section .resource-blog-card{display:flex;flex-direction:column;justify-content:space-between;background-color:#fff;border-radius:30px;box-shadow:0 20px 40px #00000014;padding:25px;text-align:center;width:338px;height:auto!important}.resource-vault-section .resource-blog-card h5{font-size:1.5rem;font-weight:400;margin-bottom:.5rem;color:var(--text-color, black)}.resource-vault-section .resource-blog-card p{font-size:1.5rem;color:var(--text-color, black);line-height:2rem}.resource-vault-section .resource-blog-card img{width:100%;border-radius:10px;aspect-ratio:1/1;object-fit:cover;margin-top:auto;margin-right:0!important;max-width:250px!important;align-self:center!important}.resource-vault-section .resource-blog-card iframe{height:210px;border-radius:10px;object-fit:cover;margin-right:0!important;max-width:280px!important}.resource-vault-section .resource-blog-card .resource-btn{background-color:var(--text-color, black);color:#fff;margin-top:auto;padding:10px 24px;border-radius:24px;font-size:1.5rem;font-weight:500;width:100%;max-width:240px;cursor:pointer;transition:background .3s ease;display:flex;justify-content:space-between;align-self:center;align-items:center;text-align:left;text-decoration:none;border:1px solid;box-shadow:none!important;border-color:var(--text-color, black)}.resource-vault-section .resource-blog-card .resource-btn:hover{background:#fff;color:var(--text-color, black)!important}.resource-vault-section .vault-description{text-align:left;max-width:657px;color:#182527;line-height:2.3rem!important;font-size:1.65rem}@media (width <= 1200px){.resource-vault-section .vault-heading{font-size:3.5rem}.resource-vault-section .vault-description{margin-top:1.35rem}.resource-vault-section .resource-btn{margin-left:0!important}}.video-row{gap:5.5rem!important;margin-top:3rem!important}@media (width >= 991px){section.bg-white.text-center.extra-top-padding{position:relative;overflow:hidden}section.bg-white.text-center.extra-top-padding .banner-header{margin-bottom:4rem!important}}.vault-header{text-align:left}@media (width >= 768px) and (width <= 1200px){.container{padding:0 6rem!important}}@media (width <= 768px){.video-row{gap:3rem!important}}@media (max-width: 768px){.resource-vault-section{padding-bottom:6rem!important}.resource-vault-section .container{padding-top:0rem!important;padding-bottom:0rem!important}.vault-header{text-align:center!important}.vault-heading{font-size:3rem!important}}@media (width <= 1200px){.container{padding:7rem 3rem 1rem!important}}\n"] }]
601
- }], ctorParameters: () => [{ type: i0.Injector }, { type: ResourceService }, { type: i2.TagService }], propDecorators: { releaseHeader: [{
602
- type: Input
603
- }], categoryId: [{
604
- type: Input
605
- }], isReleasePress: [{
606
- type: Input
607
- }], isResource: [{
608
- type: Input
609
- }], postSlice: [{
610
- type: Input
611
- }], resourceTitle: [{
612
- type: Input
613
- }], tag: [{
614
- type: Input
615
- }], user: [{
616
- type: Input
617
- }], userLoggedIn: [{
618
- type: Input
619
- }] } });
620
-
621
- class CaseStudyCardComponent extends AppBaseComponent {
622
- constructor(injector, resourceService, tagService, cdr) {
623
- super(injector);
624
- this.resourceService = resourceService;
625
- this.tagService = tagService;
626
- this.cdr = cdr;
627
- this.showCaseStudyHeader = false;
628
- this.postSlice = false;
629
- this.canEditResourcesValue = false;
630
- this.isLoaded = false;
631
- this.masterSubscriptionId = this.appConfig.master_subscription.subscription_id;
632
- this.companyName = this.appConfig.company.name;
633
- this.posts = [];
634
- this.isEditingTitle = false;
635
- }
636
- ngOnInit() {
637
- if (this.userLoggedIn) {
638
- this.localStorage.getItem$('product').subscribe(res => {
639
- const data = res ? JSON.parse(res) : null;
640
- this.subscriptionId = data?.subscriptionId;
641
- });
642
- }
643
- this.getPosts(1, 10);
644
- }
645
- ngOnChanges(changes) {
646
- if (changes['user'] || changes['userLoggedIn']) {
647
- if (this.userLoggedIn && this.user) {
648
- this.updateCanEditResourcesValue();
649
- }
650
- }
651
- }
652
- getPosts(page, pageSize) {
653
- this.isLoaded = false;
654
- this.resourceService
655
- .getPublicPosts(this.getEffectiveSubscriptionId(), page, pageSize, '', this.categoryId)
656
- .subscribe(response => {
657
- const sortedPosts = (response.posts ?? [])
658
- .filter(post => post.showcase === true)
659
- .sort((a, b) => new Date(b.published_at).getTime() - new Date(a.published_at).getTime());
660
- this.posts = this.postSlice ? sortedPosts : [...sortedPosts].slice(0, 3);
661
- })
662
- .add(() => {
663
- this.isLoaded = true;
664
- this.cdr.markForCheck();
665
- });
666
- }
667
- toggleEditTitle() {
668
- this.isEditingTitle = true;
669
- this.editedTitle = this.resourceTitle;
670
- }
671
- saveEditedTitle() {
672
- HelperService.updateTagTitle(this.tag, this.editedTitle, this.tagService, this.getEffectiveSubscriptionId(), this.toast).subscribe(() => {
673
- this.resourceTitle = this.editedTitle;
674
- this.isEditingTitle = false;
675
- this.cdr.markForCheck();
676
- });
677
- }
678
- /** Helper method to get effective subscription ID */
679
- getEffectiveSubscriptionId() {
680
- return HelperService.getEffectiveSubscriptionId(this.user, this.subscriptionId, this.masterSubscriptionId);
681
- }
682
- updateCanEditResourcesValue() {
683
- this.canEditResourcesValue = HelperService.canEditResources(this.user, this.userLoggedIn, this.permissionService);
684
- }
685
- canEditResources() {
686
- return this.canEditResourcesValue;
687
- }
688
- trackByPostId(index, post) {
689
- return post.id;
690
- }
691
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: CaseStudyCardComponent, deps: [{ token: i0.Injector }, { token: ResourceService }, { token: i2.TagService }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component }); }
692
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.20", type: CaseStudyCardComponent, isStandalone: false, selector: "pw-case-studies-card", inputs: { showCaseStudyHeader: "showCaseStudyHeader", categoryId: "categoryId", postSlice: "postSlice", tag: "tag", resourceTitle: "resourceTitle", user: "user", userLoggedIn: "userLoggedIn" }, usesInheritance: true, usesOnChanges: true, ngImport: i0, template: "<section class=\"resource-vault-section bg-white text-center py-5 extra-top-padding section-outer\" id=\"case-studies\">\n <div class=\"container\">\n <ng-container *ngIf=\"showCaseStudyHeader; else fallbackBlock\">\n <div class=\"d-flex justify-content-between align-items-center flex-wrap\">\n <ng-container *ngTemplateOutlet=\"caseStudyHeaderTemplate\"></ng-container>\n <a class=\"view-all\" routerLink=\"/resources/case-studies\">VIEW ALL ></a>\n </div>\n </ng-container>\n\n <ng-template #fallbackBlock>\n <div class=\"d-md-flex justify-content-between align-items-start\">\n <ng-container *ngTemplateOutlet=\"caseStudyHeaderTemplate\"></ng-container>\n </div>\n </ng-template>\n\n <ng-template #caseStudyHeaderTemplate>\n <h2 class=\"section-heading d-flex align-items-center\" id=\"case-studies\" [ngClass]=\"{ 'w-50': isEditingTitle }\">\n <ng-container *ngIf=\"!isEditingTitle; else editTitleBlock\">\n <span *ngIf=\"resourceTitle; else fallback\">\n <span [innerHTML]=\"resourceTitle\"></span>\n </span>\n <ng-template #fallback>Case Studies</ng-template>\n <i *ngIf=\"canEditResourcesValue\"\n class=\"fa fa-edit in-page-edit-icon ms-3 cursor-pointer\"\n (click)=\"toggleEditTitle()\"\n (keydown.enter)=\"toggleEditTitle()\"\n (keydown.space)=\"toggleEditTitle()\"\n title=\"Edit Title\"></i>\n </ng-container>\n\n <ng-template #editTitleBlock>\n <input [(ngModel)]=\"editedTitle\" class=\"form-control d-inline w-auto me-2\" [ngClass]=\"{ 'w-100': isEditingTitle }\" id=\"input_editedTitle_9216\" name=\"input_editedTitle_9216\" />\n <button class=\"btn btn-sm btn-primary me-1\" (click)=\"saveEditedTitle()\">Save</button>\n <button class=\"btn btn-sm btn-secondary\" (click)=\"isEditingTitle = false\">Cancel</button>\n </ng-template>\n </h2>\n </ng-template>\n\n\n <div class=\"w-100 text-center mt-3\" *ngIf=\"!isLoaded\">\n <p-progressSpinner strokeWidth=\"2\"> </p-progressSpinner>\n </div>\n <div *ngIf=\"posts.length === 0 && isLoaded\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Resource.NoDataMessage' | transloco\"/>\n </div>\n\n\n <div class=\"row d-flex flex-wrap justify-content-center gap-4 video-row\" *ngIf=\"posts.length !== 0 && isLoaded\">\n <div class=\"testimonial-box\" *ngFor=\"let post of posts; trackBy: trackByPostId\">\n\n <pw-resource-edit-card-lazy\n [canEdit]=\"canEditResourcesValue\"\n [id]=\"post.id\"\n [resourceData]=\"post\"\n (updated)=\"getPosts(1, 100)\">\n </pw-resource-edit-card-lazy>\n\n <div>\n <img *ngIf=\"!post.rectangular_picture.url.includes('default-photo.jpg') \" [src]=\"post.rectangular_picture.url\"\n alt=\"IT Partners Logo\"\n class=\"company-logo mb-3\"\n loading=\"lazy\" />\n\n <p class=\"mb-4 mt-3 testimonial-section\">\n <span [innerHTML]=\"post.title\"></span>\n </p>\n </div>\n\n <!-- BOTTOM AVATAR -->\n <div class=\"avatar-container mt-5\">\n <img [src]=\"post.picture.url\"\n alt=\"User Avatar\"\n *ngIf=\"post.picture.url && !post.picture.url.includes('default-photo.jpg')\"\n class=\"testimonial-avatar\"\n loading=\"lazy\" />\n <a *ngIf=\"post?.external_url; else internalLink\"\n class=\"read-more-btn-overlay\"\n aria-label=\"Navigate to external url\"\n [href]=\"post.external_url\"\n target=\"_blank\"\n rel=\"noopener noreferrer\">\n <span>{{ post?.cta_text && post.cta_text !== 'null' ? post.cta_text : 'Read Now' }}</span>\n <span class=\"arrow\">\u2192</span>\n </a>\n\n <ng-template #internalLink>\n <a class=\"read-more-btn-overlay\" aria-label=\"Navigate to resource view\" [routerLink]=\"['/resources/view', post?.slug]\">\n <span>{{ post?.cta_text && post.cta_text !== 'null' ? post.cta_text : 'Read Now' }}</span>\n <span class=\"arrow\">\u2192</span>\n </a>\n </ng-template>\n </div>\n </div>\n </div>\n </div>\n</section>\n", styles: [".resource-vault-section{background:#fff;text-align:center;padding:3rem 0}.section-outer,.container{padding:0 15px}.d-md-flex{display:flex}.justify-content-between{justify-content:space-between}.align-items-start{align-items:flex-start}.vault-heading{font-size:2rem;font-weight:700}.video-row{margin-top:3rem;gap:5.5rem!important}.row{display:flex;flex-wrap:wrap}.col-md-6,.col-lg-4{flex:0 0 auto;width:100%}@media (width >= 768px){.col-md-6,.col-lg-4{width:50%}}@media (width >= 992px){.col-md-6,.col-lg-4{width:33.3333%}}.mb-4{margin-bottom:1.5rem}.testimonial-box{display:flex;flex-direction:column;justify-content:space-between;background:#fff;color:#000;border-radius:20px;box-shadow:0 0 20px #0000001a;text-align:center;width:338px;height:auto;padding:2.5rem 1.5rem;font-size:1.1rem;min-height:421.4px!important}.testimonial-box .testimonial-section{font-size:1.5rem;line-height:2rem;font-weight:400;color:var(--text-color, black)}.testimonial-box .testimonial-section strong{display:block}.testimonial-box .company-logo{width:100%!important;height:auto!important;max-width:150px!important;object-fit:contain;align-self:center}.testimonial-box .avatar-container{margin-top:auto;position:relative;display:inline-block}.testimonial-box .avatar-container .testimonial-avatar{width:60%;aspect-ratio:1/1;height:auto;border-radius:50%;object-fit:fill}.testimonial-box .avatar-container .read-more-btn-overlay{position:absolute;text-decoration:none!important;bottom:0;left:50%;transform:translate(-50%);background-color:var(--text-color, black);color:#fff;width:240px;padding:10px 24px;border-radius:24px;font-size:1.5rem;font-weight:500;cursor:pointer;transition:background .3s ease;display:flex;justify-content:space-between;align-items:center;text-align:left;border:1px solid;box-shadow:none!important;border-color:var(--text-color, black)}.testimonial-box .avatar-container .read-more-btn-overlay:hover{background:#fff;color:var(--text-color, black)!important}.testimonial-box .avatar-container .read-more-btn-overlay .arrow{margin-bottom:.3rem}\n"], dependencies: [{ kind: "directive", type: i3.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i3.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i3.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i3.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i1.RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "info", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "routerLink"] }, { kind: "directive", type: i1$1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: i6.NoDataComponent, selector: "pw-no-data", inputs: ["message", "description", "withImage"] }, { kind: "component", type: i7.ProgressSpinner, selector: "p-progressSpinner, p-progress-spinner, p-progressspinner", inputs: ["styleClass", "style", "strokeWidth", "fill", "animationDuration", "ariaLabel"] }, { kind: "directive", type: i8.LazyImgDirective, selector: "img" }, { kind: "component", type: ResourceEditCardLazyComponent, selector: "pw-resource-edit-card-lazy", inputs: ["id", "resourceData", "canEdit"], outputs: ["updated"] }, { kind: "pipe", type: i10.TranslocoPipe, name: "transloco" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
693
- }
694
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: CaseStudyCardComponent, decorators: [{
695
- type: Component,
696
- args: [{ selector: 'pw-case-studies-card', changeDetection: ChangeDetectionStrategy.OnPush, standalone: false, template: "<section class=\"resource-vault-section bg-white text-center py-5 extra-top-padding section-outer\" id=\"case-studies\">\n <div class=\"container\">\n <ng-container *ngIf=\"showCaseStudyHeader; else fallbackBlock\">\n <div class=\"d-flex justify-content-between align-items-center flex-wrap\">\n <ng-container *ngTemplateOutlet=\"caseStudyHeaderTemplate\"></ng-container>\n <a class=\"view-all\" routerLink=\"/resources/case-studies\">VIEW ALL ></a>\n </div>\n </ng-container>\n\n <ng-template #fallbackBlock>\n <div class=\"d-md-flex justify-content-between align-items-start\">\n <ng-container *ngTemplateOutlet=\"caseStudyHeaderTemplate\"></ng-container>\n </div>\n </ng-template>\n\n <ng-template #caseStudyHeaderTemplate>\n <h2 class=\"section-heading d-flex align-items-center\" id=\"case-studies\" [ngClass]=\"{ 'w-50': isEditingTitle }\">\n <ng-container *ngIf=\"!isEditingTitle; else editTitleBlock\">\n <span *ngIf=\"resourceTitle; else fallback\">\n <span [innerHTML]=\"resourceTitle\"></span>\n </span>\n <ng-template #fallback>Case Studies</ng-template>\n <i *ngIf=\"canEditResourcesValue\"\n class=\"fa fa-edit in-page-edit-icon ms-3 cursor-pointer\"\n (click)=\"toggleEditTitle()\"\n (keydown.enter)=\"toggleEditTitle()\"\n (keydown.space)=\"toggleEditTitle()\"\n title=\"Edit Title\"></i>\n </ng-container>\n\n <ng-template #editTitleBlock>\n <input [(ngModel)]=\"editedTitle\" class=\"form-control d-inline w-auto me-2\" [ngClass]=\"{ 'w-100': isEditingTitle }\" id=\"input_editedTitle_9216\" name=\"input_editedTitle_9216\" />\n <button class=\"btn btn-sm btn-primary me-1\" (click)=\"saveEditedTitle()\">Save</button>\n <button class=\"btn btn-sm btn-secondary\" (click)=\"isEditingTitle = false\">Cancel</button>\n </ng-template>\n </h2>\n </ng-template>\n\n\n <div class=\"w-100 text-center mt-3\" *ngIf=\"!isLoaded\">\n <p-progressSpinner strokeWidth=\"2\"> </p-progressSpinner>\n </div>\n <div *ngIf=\"posts.length === 0 && isLoaded\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Resource.NoDataMessage' | transloco\"/>\n </div>\n\n\n <div class=\"row d-flex flex-wrap justify-content-center gap-4 video-row\" *ngIf=\"posts.length !== 0 && isLoaded\">\n <div class=\"testimonial-box\" *ngFor=\"let post of posts; trackBy: trackByPostId\">\n\n <pw-resource-edit-card-lazy\n [canEdit]=\"canEditResourcesValue\"\n [id]=\"post.id\"\n [resourceData]=\"post\"\n (updated)=\"getPosts(1, 100)\">\n </pw-resource-edit-card-lazy>\n\n <div>\n <img *ngIf=\"!post.rectangular_picture.url.includes('default-photo.jpg') \" [src]=\"post.rectangular_picture.url\"\n alt=\"IT Partners Logo\"\n class=\"company-logo mb-3\"\n loading=\"lazy\" />\n\n <p class=\"mb-4 mt-3 testimonial-section\">\n <span [innerHTML]=\"post.title\"></span>\n </p>\n </div>\n\n <!-- BOTTOM AVATAR -->\n <div class=\"avatar-container mt-5\">\n <img [src]=\"post.picture.url\"\n alt=\"User Avatar\"\n *ngIf=\"post.picture.url && !post.picture.url.includes('default-photo.jpg')\"\n class=\"testimonial-avatar\"\n loading=\"lazy\" />\n <a *ngIf=\"post?.external_url; else internalLink\"\n class=\"read-more-btn-overlay\"\n aria-label=\"Navigate to external url\"\n [href]=\"post.external_url\"\n target=\"_blank\"\n rel=\"noopener noreferrer\">\n <span>{{ post?.cta_text && post.cta_text !== 'null' ? post.cta_text : 'Read Now' }}</span>\n <span class=\"arrow\">\u2192</span>\n </a>\n\n <ng-template #internalLink>\n <a class=\"read-more-btn-overlay\" aria-label=\"Navigate to resource view\" [routerLink]=\"['/resources/view', post?.slug]\">\n <span>{{ post?.cta_text && post.cta_text !== 'null' ? post.cta_text : 'Read Now' }}</span>\n <span class=\"arrow\">\u2192</span>\n </a>\n </ng-template>\n </div>\n </div>\n </div>\n </div>\n</section>\n", styles: [".resource-vault-section{background:#fff;text-align:center;padding:3rem 0}.section-outer,.container{padding:0 15px}.d-md-flex{display:flex}.justify-content-between{justify-content:space-between}.align-items-start{align-items:flex-start}.vault-heading{font-size:2rem;font-weight:700}.video-row{margin-top:3rem;gap:5.5rem!important}.row{display:flex;flex-wrap:wrap}.col-md-6,.col-lg-4{flex:0 0 auto;width:100%}@media (width >= 768px){.col-md-6,.col-lg-4{width:50%}}@media (width >= 992px){.col-md-6,.col-lg-4{width:33.3333%}}.mb-4{margin-bottom:1.5rem}.testimonial-box{display:flex;flex-direction:column;justify-content:space-between;background:#fff;color:#000;border-radius:20px;box-shadow:0 0 20px #0000001a;text-align:center;width:338px;height:auto;padding:2.5rem 1.5rem;font-size:1.1rem;min-height:421.4px!important}.testimonial-box .testimonial-section{font-size:1.5rem;line-height:2rem;font-weight:400;color:var(--text-color, black)}.testimonial-box .testimonial-section strong{display:block}.testimonial-box .company-logo{width:100%!important;height:auto!important;max-width:150px!important;object-fit:contain;align-self:center}.testimonial-box .avatar-container{margin-top:auto;position:relative;display:inline-block}.testimonial-box .avatar-container .testimonial-avatar{width:60%;aspect-ratio:1/1;height:auto;border-radius:50%;object-fit:fill}.testimonial-box .avatar-container .read-more-btn-overlay{position:absolute;text-decoration:none!important;bottom:0;left:50%;transform:translate(-50%);background-color:var(--text-color, black);color:#fff;width:240px;padding:10px 24px;border-radius:24px;font-size:1.5rem;font-weight:500;cursor:pointer;transition:background .3s ease;display:flex;justify-content:space-between;align-items:center;text-align:left;border:1px solid;box-shadow:none!important;border-color:var(--text-color, black)}.testimonial-box .avatar-container .read-more-btn-overlay:hover{background:#fff;color:var(--text-color, black)!important}.testimonial-box .avatar-container .read-more-btn-overlay .arrow{margin-bottom:.3rem}\n"] }]
697
- }], ctorParameters: () => [{ type: i0.Injector }, { type: ResourceService }, { type: i2.TagService }, { type: i0.ChangeDetectorRef }], propDecorators: { showCaseStudyHeader: [{
698
- type: Input
699
- }], categoryId: [{
700
- type: Input
701
- }], postSlice: [{
702
- type: Input
703
- }], tag: [{
704
- type: Input
705
- }], resourceTitle: [{
706
- type: Input
707
- }], user: [{
708
- type: Input
709
- }], userLoggedIn: [{
710
- type: Input
711
- }] } });
712
-
713
- class ResourceCardComponent extends AppBaseComponent {
714
- constructor(injector, resourceService, tagService) {
715
- super(injector);
716
- this.resourceService = resourceService;
717
- this.tagService = tagService;
718
- this.isHeaderVisible = true;
719
- this.isRelated = false;
720
- this.postSlice = false;
721
- this.isLoaded = false;
722
- this.masterSubscriptionId = this.appConfig.master_subscription.subscription_id;
723
- this.posts = [];
724
- this.canEditResourcesValue = false;
725
- }
726
- ngOnInit() {
727
- if (this.userLoggedIn) {
728
- this.localStorage.getItem$('product').subscribe(res => {
729
- const data = res ? JSON.parse(res) : null;
730
- this.subscriptionId = data?.subscriptionId;
731
- });
732
- }
733
- this.getPosts(1, 10);
734
- }
735
- ngOnChanges(changes) {
736
- if (changes['user'] || changes['userLoggedIn']) {
737
- if (this.userLoggedIn && this.user) {
738
- this.updateCanEditResourcesValue();
739
- }
740
- }
741
- }
742
- getPosts(page, pageSize) {
743
- this.isLoaded = false;
744
- this.resourceService
745
- .getPublicPosts(this.getEffectiveSubscriptionId(), page, pageSize, '', this.categoryId)
746
- .subscribe(response => {
747
- const sortedPosts = (response.posts ?? [])
748
- .filter(post => post.showcase === true)
749
- .sort((a, b) => new Date(b.published_at).getTime() - new Date(a.published_at).getTime());
750
- this.posts = this.postSlice ? sortedPosts : [...sortedPosts].slice(0, 3);
751
- })
752
- .add(() => {
753
- this.isLoaded = true;
754
- });
755
- }
756
- toggleTagEditTitle() {
757
- this.isEditingTitle = true;
758
- this.editedTitle = this.resourceTitle;
759
- }
760
- saveEditedTitle() {
761
- HelperService.updateTagTitle(this.tag, this.editedTitle, this.tagService, this.getEffectiveSubscriptionId(), this.toast).subscribe(() => {
762
- this.resourceTitle = this.editedTitle;
763
- this.isEditingTitle = false;
764
- });
765
- }
766
- /** Helper method to get effective subscription ID */
767
- getEffectiveSubscriptionId() {
768
- return HelperService.getEffectiveSubscriptionId(this.user, this.subscriptionId, this.masterSubscriptionId);
769
- }
770
- updateCanEditResourcesValue() {
771
- this.canEditResourcesValue = HelperService.canEditResources(this.user, this.userLoggedIn, this.permissionService);
772
- }
773
- canEditResources() {
774
- return this.canEditResourcesValue;
775
- }
776
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: ResourceCardComponent, deps: [{ token: i0.Injector }, { token: ResourceService }, { token: i2.TagService }], target: i0.ɵɵFactoryTarget.Component }); }
777
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.20", type: ResourceCardComponent, isStandalone: false, selector: "pw-resource-cards", inputs: { categoryId: "categoryId", isHeaderVisible: "isHeaderVisible", isRelated: "isRelated", resourceTitle: "resourceTitle", postSlice: "postSlice", header: "header", tag: "tag", resourceLink: "resourceLink", user: "user", userLoggedIn: "userLoggedIn" }, usesInheritance: true, usesOnChanges: true, ngImport: i0, template: "<section class=\"resource-vault-section bg-white\">\n <div class=\"container\">\n <div class=\"d-flex justify-content-between align-items-center flex-wrap\" *ngIf=\"isHeaderVisible\">\n <h2 class=\"section-heading d-flex align-items-center\" [ngClass]=\"{ 'w-50': isEditingTitle }\">\n <ng-container *ngIf=\"!isEditingTitle; else editTitleBlock\">\n <span *ngIf=\"resourceTitle; else fallback\" [innerHTML]=\"resourceTitle\"></span>\n <ng-template #fallback>Our team\u2019s articles</ng-template>\n <i *ngIf=\"!isRelated && canEditResourcesValue\" class=\"fa fa-edit in-page-edit-icon ms-3 cursor-pointer\" (click)=\"toggleTagEditTitle()\" (keydown.enter)=\"toggleTagEditTitle()\" (keydown.space)=\"toggleTagEditTitle()\" title=\"Edit Title\"></i>\n </ng-container>\n\n <ng-template #editTitleBlock>\n <input [(ngModel)]=\"editedTitle\" class=\"form-control d-inline w-auto me-2\" [ngClass]=\"{ 'w-100': isEditingTitle }\" id=\"input_editedTitle_9056\" name=\"input_editedTitle_9056\" />\n <button class=\"btn btn-sm btn-primary me-1\" (click)=\"saveEditedTitle()\">Save</button>\n <button class=\"btn btn-sm btn-secondary\" (click)=\"isEditingTitle = false\">Cancel</button>\n </ng-template>\n </h2>\n <a class=\"view-all\" [routerLink]=\"resourceLink\">VIEW ALL ></a>\n </div>\n\n <div class=\"w-100 text-center mt-3\" *ngIf=\"!isLoaded\">\n <p-progressSpinner strokeWidth=\"2\"> </p-progressSpinner>\n </div>\n <div *ngIf=\"posts.length === 0 && isLoaded\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Resource.NoDataMessage' | transloco\"/>\n </div>\n\n <div class=\"row d-flex flex-wrap justify-content-center gap-4 video-row\" *ngIf=\"posts.length !== 0 && isLoaded\">\n <div class=\"resource-blog-card p-4\" *ngFor=\"let post of posts\">\n <pw-resource-edit-card-lazy\n [canEdit]=\"canEditResourcesValue\"\n [id]=\"post.id\"\n [resourceData]=\"post\"\n (updated)=\"getPosts(1, 100)\">\n </pw-resource-edit-card-lazy>\n <p class=\"resource-title\" [innerHTML]=\"post.title \"></p>\n <a\n [href]=\"post.external_url || ('/resources/view/' + post?.slug)\"\n target=\"_blank\"\n rel=\"noopener noreferrer\"\n aria-label=\"Navigate to resource\"\n >\n <img\n [src]=\"post.picture.url\"\n class=\"img-fluid my-3 mt-auto\"\n alt=\"Webinar\"\n /></a>\n <a *ngIf=\"post?.external_url; else internalLink\"\n class=\"resource-btn mt-3\"\n [href]=\"post.external_url\"\n aria-label=\"Navigate to external url\"\n target=\"_blank\"\n rel=\"noopener noreferrer\">\n <span>{{ post?.cta_text && post.cta_text !== 'null' ? post.cta_text : 'Read Now' }}</span>\n <span class=\"arrow\">\u2192</span>\n </a>\n\n <ng-template #internalLink>\n <a class=\"resource-btn mt-3\" aria-label=\"Navigate to resource view\" [href]=\"'/resources/view/' + post?.slug\" target=\"_blank\">\n <span>{{ post?.cta_text && post.cta_text !== 'null' ? post.cta_text : 'Read Now' }}</span>\n <span class=\"arrow\">\u2192</span>\n </a>\n </ng-template>\n </div>\n </div>\n </div>\n </section>", styles: [".bold{font-weight:700}.resource-heading{margin-bottom:2rem}.resource-note{margin-top:1rem;font-size:.85rem;color:#555}.resource-divider{border:0;height:40px;width:100%;background:linear-gradient(to bottom,#0000,#00000026);margin:0}.press-release-icon{height:auto!important;margin:0 11px 1.9rem;display:block;align-self:center;width:auto!important;aspect-ratio:0!important;object-fit:cover;margin-top:auto;margin-right:0!important}.resource-vault-section{padding:60px 0;background:#fff;padding-bottom:9rem!important;padding-top:7rem!important;box-shadow:0 4px 32px -14px #40576d4d!important}.resource-vault-section .vault-heading{font-size:3rem;font-weight:300}.resource-vault-section .explore-link{color:#000;font-weight:400;text-decoration:none;font-size:1.5rem}.resource-vault-section .resource-blog-card{display:flex;flex-direction:column;justify-content:space-between;background-color:#fff;border-radius:30px;box-shadow:0 20px 40px #00000014;padding:25px;text-align:center;width:338px;height:auto!important}.resource-vault-section .resource-blog-card h5{font-size:1.5rem;font-weight:400;margin-bottom:.5rem;color:var(--text-color, black)}.resource-vault-section .resource-blog-card p{font-size:1.5rem;color:var(--text-color, black);line-height:2rem}.resource-vault-section .resource-blog-card img{width:100%;border-radius:10px;aspect-ratio:1/1;object-fit:cover;margin-top:auto;margin-right:0!important;max-width:250px!important;align-self:center!important}.resource-vault-section .resource-blog-card iframe{height:210px;border-radius:10px;object-fit:cover;margin-right:0!important;max-width:280px!important}.resource-vault-section .resource-blog-card .resource-btn{background-color:var(--text-color, black);color:#fff;margin-top:auto;padding:10px 24px;border-radius:24px;font-size:1.5rem;font-weight:500;width:100%;max-width:240px;cursor:pointer;transition:background .3s ease;display:flex;justify-content:space-between;align-self:center;align-items:center;text-align:left;text-decoration:none;border:1px solid;box-shadow:none!important;border-color:var(--text-color, black)}.resource-vault-section .resource-blog-card .resource-btn:hover{background:#fff;color:var(--text-color, black)!important}.resource-vault-section .vault-description{text-align:left;max-width:657px;color:#182527;line-height:2.3rem!important;font-size:1.65rem}@media (width <= 1200px){.resource-vault-section .vault-heading{font-size:3.5rem}.resource-vault-section .vault-description{margin-top:1.35rem}.resource-vault-section .resource-btn{margin-left:0!important}}.video-row{gap:5.5rem!important;margin-top:3rem!important}@media (width >= 991px){section.bg-white.text-center.extra-top-padding{position:relative;overflow:hidden}section.bg-white.text-center.extra-top-padding .banner-header{margin-bottom:4rem!important}}.vault-header{text-align:left}@media (width >= 768px) and (width <= 1200px){.container{padding:0 6rem!important}}@media (width <= 768px){.video-row{gap:3rem!important}}@media (max-width: 768px){.resource-vault-section{padding-bottom:6rem!important}.resource-vault-section .container{padding-top:0rem!important;padding-bottom:0rem!important}.vault-header{text-align:center!important}.vault-heading{font-size:3rem!important}}@media (width <= 1200px){.container{padding:7rem 3rem 1rem!important}}\n"], dependencies: [{ kind: "directive", type: i3.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i3.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i3.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1.RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "info", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "routerLink"] }, { kind: "directive", type: i1$1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: i6.NoDataComponent, selector: "pw-no-data", inputs: ["message", "description", "withImage"] }, { kind: "component", type: i7.ProgressSpinner, selector: "p-progressSpinner, p-progress-spinner, p-progressspinner", inputs: ["styleClass", "style", "strokeWidth", "fill", "animationDuration", "ariaLabel"] }, { kind: "directive", type: i8.LazyImgDirective, selector: "img" }, { kind: "component", type: ResourceEditCardLazyComponent, selector: "pw-resource-edit-card-lazy", inputs: ["id", "resourceData", "canEdit"], outputs: ["updated"] }, { kind: "pipe", type: i10.TranslocoPipe, name: "transloco" }] }); }
778
- }
779
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: ResourceCardComponent, decorators: [{
780
- type: Component,
781
- args: [{ selector: 'pw-resource-cards', standalone: false, template: "<section class=\"resource-vault-section bg-white\">\n <div class=\"container\">\n <div class=\"d-flex justify-content-between align-items-center flex-wrap\" *ngIf=\"isHeaderVisible\">\n <h2 class=\"section-heading d-flex align-items-center\" [ngClass]=\"{ 'w-50': isEditingTitle }\">\n <ng-container *ngIf=\"!isEditingTitle; else editTitleBlock\">\n <span *ngIf=\"resourceTitle; else fallback\" [innerHTML]=\"resourceTitle\"></span>\n <ng-template #fallback>Our team\u2019s articles</ng-template>\n <i *ngIf=\"!isRelated && canEditResourcesValue\" class=\"fa fa-edit in-page-edit-icon ms-3 cursor-pointer\" (click)=\"toggleTagEditTitle()\" (keydown.enter)=\"toggleTagEditTitle()\" (keydown.space)=\"toggleTagEditTitle()\" title=\"Edit Title\"></i>\n </ng-container>\n\n <ng-template #editTitleBlock>\n <input [(ngModel)]=\"editedTitle\" class=\"form-control d-inline w-auto me-2\" [ngClass]=\"{ 'w-100': isEditingTitle }\" id=\"input_editedTitle_9056\" name=\"input_editedTitle_9056\" />\n <button class=\"btn btn-sm btn-primary me-1\" (click)=\"saveEditedTitle()\">Save</button>\n <button class=\"btn btn-sm btn-secondary\" (click)=\"isEditingTitle = false\">Cancel</button>\n </ng-template>\n </h2>\n <a class=\"view-all\" [routerLink]=\"resourceLink\">VIEW ALL ></a>\n </div>\n\n <div class=\"w-100 text-center mt-3\" *ngIf=\"!isLoaded\">\n <p-progressSpinner strokeWidth=\"2\"> </p-progressSpinner>\n </div>\n <div *ngIf=\"posts.length === 0 && isLoaded\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Resource.NoDataMessage' | transloco\"/>\n </div>\n\n <div class=\"row d-flex flex-wrap justify-content-center gap-4 video-row\" *ngIf=\"posts.length !== 0 && isLoaded\">\n <div class=\"resource-blog-card p-4\" *ngFor=\"let post of posts\">\n <pw-resource-edit-card-lazy\n [canEdit]=\"canEditResourcesValue\"\n [id]=\"post.id\"\n [resourceData]=\"post\"\n (updated)=\"getPosts(1, 100)\">\n </pw-resource-edit-card-lazy>\n <p class=\"resource-title\" [innerHTML]=\"post.title \"></p>\n <a\n [href]=\"post.external_url || ('/resources/view/' + post?.slug)\"\n target=\"_blank\"\n rel=\"noopener noreferrer\"\n aria-label=\"Navigate to resource\"\n >\n <img\n [src]=\"post.picture.url\"\n class=\"img-fluid my-3 mt-auto\"\n alt=\"Webinar\"\n /></a>\n <a *ngIf=\"post?.external_url; else internalLink\"\n class=\"resource-btn mt-3\"\n [href]=\"post.external_url\"\n aria-label=\"Navigate to external url\"\n target=\"_blank\"\n rel=\"noopener noreferrer\">\n <span>{{ post?.cta_text && post.cta_text !== 'null' ? post.cta_text : 'Read Now' }}</span>\n <span class=\"arrow\">\u2192</span>\n </a>\n\n <ng-template #internalLink>\n <a class=\"resource-btn mt-3\" aria-label=\"Navigate to resource view\" [href]=\"'/resources/view/' + post?.slug\" target=\"_blank\">\n <span>{{ post?.cta_text && post.cta_text !== 'null' ? post.cta_text : 'Read Now' }}</span>\n <span class=\"arrow\">\u2192</span>\n </a>\n </ng-template>\n </div>\n </div>\n </div>\n </section>", styles: [".bold{font-weight:700}.resource-heading{margin-bottom:2rem}.resource-note{margin-top:1rem;font-size:.85rem;color:#555}.resource-divider{border:0;height:40px;width:100%;background:linear-gradient(to bottom,#0000,#00000026);margin:0}.press-release-icon{height:auto!important;margin:0 11px 1.9rem;display:block;align-self:center;width:auto!important;aspect-ratio:0!important;object-fit:cover;margin-top:auto;margin-right:0!important}.resource-vault-section{padding:60px 0;background:#fff;padding-bottom:9rem!important;padding-top:7rem!important;box-shadow:0 4px 32px -14px #40576d4d!important}.resource-vault-section .vault-heading{font-size:3rem;font-weight:300}.resource-vault-section .explore-link{color:#000;font-weight:400;text-decoration:none;font-size:1.5rem}.resource-vault-section .resource-blog-card{display:flex;flex-direction:column;justify-content:space-between;background-color:#fff;border-radius:30px;box-shadow:0 20px 40px #00000014;padding:25px;text-align:center;width:338px;height:auto!important}.resource-vault-section .resource-blog-card h5{font-size:1.5rem;font-weight:400;margin-bottom:.5rem;color:var(--text-color, black)}.resource-vault-section .resource-blog-card p{font-size:1.5rem;color:var(--text-color, black);line-height:2rem}.resource-vault-section .resource-blog-card img{width:100%;border-radius:10px;aspect-ratio:1/1;object-fit:cover;margin-top:auto;margin-right:0!important;max-width:250px!important;align-self:center!important}.resource-vault-section .resource-blog-card iframe{height:210px;border-radius:10px;object-fit:cover;margin-right:0!important;max-width:280px!important}.resource-vault-section .resource-blog-card .resource-btn{background-color:var(--text-color, black);color:#fff;margin-top:auto;padding:10px 24px;border-radius:24px;font-size:1.5rem;font-weight:500;width:100%;max-width:240px;cursor:pointer;transition:background .3s ease;display:flex;justify-content:space-between;align-self:center;align-items:center;text-align:left;text-decoration:none;border:1px solid;box-shadow:none!important;border-color:var(--text-color, black)}.resource-vault-section .resource-blog-card .resource-btn:hover{background:#fff;color:var(--text-color, black)!important}.resource-vault-section .vault-description{text-align:left;max-width:657px;color:#182527;line-height:2.3rem!important;font-size:1.65rem}@media (width <= 1200px){.resource-vault-section .vault-heading{font-size:3.5rem}.resource-vault-section .vault-description{margin-top:1.35rem}.resource-vault-section .resource-btn{margin-left:0!important}}.video-row{gap:5.5rem!important;margin-top:3rem!important}@media (width >= 991px){section.bg-white.text-center.extra-top-padding{position:relative;overflow:hidden}section.bg-white.text-center.extra-top-padding .banner-header{margin-bottom:4rem!important}}.vault-header{text-align:left}@media (width >= 768px) and (width <= 1200px){.container{padding:0 6rem!important}}@media (width <= 768px){.video-row{gap:3rem!important}}@media (max-width: 768px){.resource-vault-section{padding-bottom:6rem!important}.resource-vault-section .container{padding-top:0rem!important;padding-bottom:0rem!important}.vault-header{text-align:center!important}.vault-heading{font-size:3rem!important}}@media (width <= 1200px){.container{padding:7rem 3rem 1rem!important}}\n"] }]
782
- }], ctorParameters: () => [{ type: i0.Injector }, { type: ResourceService }, { type: i2.TagService }], propDecorators: { categoryId: [{
783
- type: Input
784
- }], isHeaderVisible: [{
785
- type: Input
786
- }], isRelated: [{
787
- type: Input
788
- }], resourceTitle: [{
789
- type: Input
790
- }], postSlice: [{
791
- type: Input
792
- }], header: [{
793
- type: Input
794
- }], tag: [{
795
- type: Input
796
- }], resourceLink: [{
797
- type: Input
798
- }], user: [{
799
- type: Input
800
- }], userLoggedIn: [{
801
- type: Input
802
- }] } });
803
-
804
- class BaseResourceComponent extends AppBaseComponent {
805
- constructor(resourceService, tagService, authService, injector) {
806
- super(injector);
807
- this.resourceService = resourceService;
808
- this.tagService = tagService;
809
- this.authService = authService;
810
- this.masterSubscriptionId = this.appConfig.master_subscription.subscription_id;
811
- this.posts = [];
812
- this.testimonialsPosts = [];
813
- this.isLoaded = false;
814
- this.canEditResourcesValue = false;
815
- }
816
- ngOnInit() {
817
- this.getUserSubscriptionId().subscribe(response => {
818
- this.subscriptionId = response;
819
- });
820
- this.authService.getToken$().subscribe(res => {
821
- this.userLoggedIn = !!res;
822
- if (this.userLoggedIn) {
823
- this.localStorage.getItem$('product').subscribe(res => {
824
- const data = res ? JSON.parse(res) : null;
825
- this.subscriptionId = data?.subscriptionId;
826
- });
827
- this.userService.getUserInfo().subscribe(data => {
828
- this.user = data;
829
- this.updateCanEditResourcesValue();
830
- this.initializeComponent();
831
- });
832
- }
833
- else {
834
- this.initializeComponent();
835
- }
836
- });
837
- }
838
- initializeComponent() {
839
- if (this.shouldUseTagCategories()) {
840
- this.getTags();
841
- }
842
- else {
843
- this.getPostTags();
844
- }
845
- if (this.shouldLoadTestimonials()) {
846
- this.getTestimonialTags();
847
- }
848
- }
849
- getTags() {
850
- this.isLoaded = false;
851
- this.tagService
852
- .getAllTagCategories({ search: this.getSearchTerm() }, this.getEffectiveSubscriptionId())
853
- .subscribe(response => {
854
- this.tagCategory = response?.tag_categories?.[0];
855
- this.getPostTags();
856
- });
857
- }
858
- getPostTags() {
859
- this.tagService
860
- .getTagsByType('post_categories', {}, this.getEffectiveSubscriptionId())
861
- .subscribe(response => {
862
- if (this.shouldUseTagCategories()) {
863
- this.blogPostTag = response.tags.find(tag => tag.tag_category_id === this.tagCategory?.id);
864
- }
865
- else {
866
- this.blogPostTag = response.tags.find(tag => tag.name === this.getResourceType());
867
- }
868
- this.getPosts(1, 100);
869
- })
870
- .add(() => {
871
- this.isLoaded = true;
872
- });
873
- }
874
- getTestimonialTags() {
875
- this.tagService
876
- .getTagsByType('post_categories', {}, this.getEffectiveSubscriptionId())
877
- .subscribe(response => {
878
- this.blogTestimonialsPostTag = response.tags.find(tag => tag.name === 'Testimonials');
879
- this.getTestimonialsPosts(1, 100);
880
- });
881
- }
882
- getPosts(page, pageSize) {
883
- this.fetchPosts(page, pageSize, this.blogPostTag?.tag_category_id, 'posts');
884
- }
885
- getTestimonialsPosts(page, pageSize) {
886
- this.fetchPosts(page, pageSize, this.blogTestimonialsPostTag?.tag_category_id, 'testimonialsPosts');
887
- }
888
- /** Shared method to fetch posts with common filtering, sorting, and slicing logic */
889
- fetchPosts(page, pageSize, tagCategoryId, targetProperty) {
890
- this.resourceService
891
- .getPublicPosts(this.getEffectiveSubscriptionId(), page, pageSize, '', tagCategoryId)
892
- .subscribe(response => {
893
- const filteredPosts = response.posts
894
- .filter(post => post.tags?.some(tag => tag.tag_category_id === tagCategoryId))
895
- .sort((a, b) => new Date(b.published_at).getTime() - new Date(a.published_at).getTime())
896
- .slice(0, 12);
897
- if (targetProperty === 'posts') {
898
- this.posts = filteredPosts;
899
- }
900
- else {
901
- this.testimonialsPosts = filteredPosts;
902
- }
903
- });
904
- }
905
- /** Helper method to get effective subscription ID */
906
- getEffectiveSubscriptionId() {
907
- return HelperService.getEffectiveSubscriptionId(this.user, this.subscriptionId, this.masterSubscriptionId);
908
- }
909
- // Optional methods that can be overridden
910
- getSearchTerm() {
911
- return this.getResourceType();
912
- }
913
- shouldUseTagCategories() {
914
- return false;
915
- }
916
- shouldLoadTestimonials() {
917
- return false;
918
- }
919
- updateCanEditResourcesValue() {
920
- if (this.userLoggedIn && this.user) {
921
- this.canEditResourcesValue = HelperService.canEditResources(this.user, this.userLoggedIn, this.permissionService);
922
- }
923
- else {
924
- this.canEditResourcesValue = false;
925
- }
926
- }
927
- canEditResources() {
928
- return this.canEditResourcesValue;
929
- }
930
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: BaseResourceComponent, deps: [{ token: ResourceService }, { token: i2.TagService }, { token: i2.AuthService }, { token: i0.Injector }], target: i0.ɵɵFactoryTarget.Component }); }
931
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.20", type: BaseResourceComponent, isStandalone: false, selector: "ng-component", usesInheritance: true, ngImport: i0, template: '', isInline: true }); }
932
- }
933
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: BaseResourceComponent, decorators: [{
934
- type: Component,
935
- args: [{
936
- template: '',
937
- standalone: false
938
- }]
939
- }], ctorParameters: () => [{ type: ResourceService }, { type: i2.TagService }, { type: i2.AuthService }, { type: i0.Injector }] });
940
-
941
- class ResourceVaultComponent extends BaseResourceComponent {
942
- constructor(resourceService, tagService, authService, injector) {
943
- super(resourceService, tagService, authService, injector);
944
- this.showVaultSection = false;
945
- this.postSlice = false;
946
- this.isLoadedChange = new EventEmitter();
947
- this.isEditingTitle = false;
948
- }
949
- ngOnInit() {
950
- super.ngOnInit();
951
- this.getPosts(1, 10);
952
- }
953
- getResourceType() {
954
- return 'Vault';
955
- }
956
- getPosts(page, pageSize) {
957
- this.isLoaded = false;
958
- this.resourceService
959
- .getPublicPosts(this.getEffectiveSubscriptionId(), page, pageSize, '', this.categoryId)
960
- .subscribe(response => {
961
- const sortedPosts = (response.posts ?? [])
962
- .filter(post => post.showcase === true)
963
- .sort((a, b) => new Date(b.published_at).getTime() - new Date(a.published_at).getTime());
964
- this.posts = this.postSlice ? sortedPosts : [...sortedPosts].slice(0, 3);
965
- })
966
- .add(() => {
967
- this.isLoaded = true;
968
- this.isLoadedChange.emit(this.isLoaded);
969
- });
970
- }
971
- toggleEditTitle() {
972
- this.isEditingTitle = true;
973
- this.editedTitle = this.resourceTitle;
974
- }
975
- saveEditedTitle() {
976
- HelperService.updateTagTitle(this.tag, this.editedTitle, this.tagService, this.getEffectiveSubscriptionId(), this.toast).subscribe(() => {
977
- this.resourceTitle = this.editedTitle;
978
- this.isEditingTitle = false;
979
- });
980
- }
981
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: ResourceVaultComponent, deps: [{ token: ResourceService }, { token: i2.TagService }, { token: i2.AuthService }, { token: i0.Injector }], target: i0.ɵɵFactoryTarget.Component }); }
982
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.20", type: ResourceVaultComponent, isStandalone: false, selector: "pw-resource--vault", inputs: { showVaultSection: "showVaultSection", postSlice: "postSlice", categoryId: "categoryId", resourceTitle: "resourceTitle", tag: "tag" }, outputs: { isLoadedChange: "isLoadedChange" }, usesInheritance: true, ngImport: i0, template: "<section class=\"resource-vault-section bg-white text-center py-5 extra-top-padding section-outer\">\n <div class=\"container\">\n <div *ngIf=\"showVaultSection\" class=\"d-flex justify-content-between align-items-center flex-wrap mb-5\">\n <h2 class=\"section-heading d-flex align-items-center\" [ngClass]=\"{ 'w-50': isEditingTitle }\">\n <ng-container *ngIf=\"!isEditingTitle; else editTitleBlock\">\n <span *ngIf=\"resourceTitle; else fallback\" [innerHTML]=\"resourceTitle\"></span>\n <ng-template #fallback>Whitepapers &amp; Tools</ng-template>\n <i *ngIf=\"canEditResourcesValue\" class=\"fa fa-edit in-page-edit-icon ms-3 cursor-pointer\" (click)=\"toggleEditTitle()\" (keydown.enter)=\"toggleEditTitle()\" (keydown.space)=\"toggleEditTitle()\" title=\"Edit Title\"></i>\n </ng-container>\n\n <ng-template #editTitleBlock>\n <input [(ngModel)]=\"editedTitle\" class=\"form-control d-inline w-auto me-2\" [ngClass]=\"{ 'w-100': isEditingTitle }\" id=\"input_editedTitle_9216\" name=\"input_editedTitle_9216\" />\n <button class=\"btn btn-sm btn-primary me-1\" (click)=\"saveEditedTitle()\">Save</button>\n <button class=\"btn btn-sm btn-secondary\" (click)=\"isEditingTitle = false\">Cancel</button>\n </ng-template>\n </h2>\n\n <a class=\"view-all\" routerLink=\"/resources/white-papers\">VIEW ALL ></a>\n </div>\n <div class=\"w-100 text-center mt-3\" *ngIf=\"!isLoaded\">\n <p-progressSpinner strokeWidth=\"2\"> </p-progressSpinner>\n </div>\n <div *ngIf=\"posts.length === 0 && isLoaded\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Resource.NoDataMessage' | transloco\"/>\n </div>\n <div class=\"d-flex mt-2 flex-wrap justify-content-center gap-4 video-row\" *ngIf=\"posts.length !== 0 && isLoaded\">\n <div class=\"resource-blog-card text-center p-4\" *ngFor=\"let post of posts\">\n <pw-resource-edit-card-lazy\n [canEdit]=\"canEditResourcesValue\"\n [id]=\"post.id\"\n [resourceData]=\"post\"\n (updated)=\"getPosts(1, 100)\">\n </pw-resource-edit-card-lazy>\n <p class=\"mb-4\" [innerHTML]=\"post.title\"></p>\n <a\n [href]=\"post.external_url || ('/resources/view/' + post?.slug)\"\n target=\"_blank\"\n rel=\"noopener noreferrer\"\n aria-label=\"Navigate to resource\"\n >\n <img\n [src]=\"post.picture.url\"\n class=\"img-fluid my-3 mt-auto\"\n alt=\"Webinar\"\n loading=\"lazy\"\n />\n </a>\n <a *ngIf=\"post?.external_url; else internalLink\"\n class=\"resource-btn mt-3\"\n aria-label=\"Navigate to external url\"\n [href]=\"post.external_url\"\n target=\"_blank\"\n rel=\"noopener noreferrer\">\n <span>{{ post?.cta_text && post.cta_text !== 'null' ? post.cta_text : 'Read Now' }}</span>\n <span class=\"arrow\">\u2192</span>\n </a>\n\n <ng-template #internalLink>\n <a class=\"resource-btn mt-3\" aria-label=\"Navigate to resource view\" [href]=\"'/resources/view/' + post?.slug\" target=\"_blank\">\n <span>{{ post?.cta_text && post.cta_text !== 'null' ? post.cta_text : 'Read Now' }}</span>\n <span class=\"arrow\">\u2192</span>\n </a>\n </ng-template>\n </div>\n </div>\n </div>\n</section>\n", styles: [".bold{font-weight:700}.resource-heading{margin-bottom:2rem}.resource-note{margin-top:1rem;font-size:.85rem;color:#555}.resource-divider{border:0;height:40px;width:100%;background:linear-gradient(to bottom,#0000,#00000026);margin:0}.press-release-icon{height:auto!important;margin:0 11px 1.9rem;display:block;align-self:center;width:auto!important;aspect-ratio:0!important;object-fit:cover;margin-top:auto;margin-right:0!important}.resource-vault-section{padding:60px 0;background:#fff;padding-bottom:9rem!important;padding-top:7rem!important;box-shadow:0 4px 32px -14px #40576d4d!important}.resource-vault-section .vault-heading{font-size:3rem;font-weight:300}.resource-vault-section .explore-link{color:#000;font-weight:400;text-decoration:none;font-size:1.5rem}.resource-vault-section .resource-blog-card{display:flex;flex-direction:column;justify-content:space-between;background-color:#fff;border-radius:30px;box-shadow:0 20px 40px #00000014;padding:25px;text-align:center;width:338px;height:auto!important}.resource-vault-section .resource-blog-card h5{font-size:1.5rem;font-weight:400;margin-bottom:.5rem;color:var(--text-color, black)}.resource-vault-section .resource-blog-card p{font-size:1.5rem;color:var(--text-color, black);line-height:2rem}.resource-vault-section .resource-blog-card img{width:100%;border-radius:10px;aspect-ratio:1/1;object-fit:cover;margin-top:auto;margin-right:0!important;max-width:250px!important;align-self:center!important}.resource-vault-section .resource-blog-card iframe{height:210px;border-radius:10px;object-fit:cover;margin-right:0!important;max-width:280px!important}.resource-vault-section .resource-blog-card .resource-btn{background-color:var(--text-color, black);color:#fff;margin-top:auto;padding:10px 24px;border-radius:24px;font-size:1.5rem;font-weight:500;width:100%;max-width:240px;cursor:pointer;transition:background .3s ease;display:flex;justify-content:space-between;align-self:center;align-items:center;text-align:left;text-decoration:none;border:1px solid;box-shadow:none!important;border-color:var(--text-color, black)}.resource-vault-section .resource-blog-card .resource-btn:hover{background:#fff;color:var(--text-color, black)!important}.resource-vault-section .vault-description{text-align:left;max-width:657px;color:#182527;line-height:2.3rem!important;font-size:1.65rem}@media (width <= 1200px){.resource-vault-section .vault-heading{font-size:3.5rem}.resource-vault-section .vault-description{margin-top:1.35rem}.resource-vault-section .resource-btn{margin-left:0!important}}.video-row{gap:5.5rem!important;margin-top:3rem!important}@media (width >= 991px){section.bg-white.text-center.extra-top-padding{position:relative;overflow:hidden}section.bg-white.text-center.extra-top-padding .banner-header{margin-bottom:4rem!important}}.vault-header{text-align:left}@media (width >= 768px) and (width <= 1200px){.container{padding:0 6rem!important}}@media (width <= 768px){.video-row{gap:3rem!important}}@media (max-width: 768px){.resource-vault-section{padding-bottom:6rem!important}.resource-vault-section .container{padding-top:0rem!important;padding-bottom:0rem!important}.vault-header{text-align:center!important}.vault-heading{font-size:3rem!important}}@media (width <= 1200px){.container{padding:7rem 3rem 1rem!important}}\n"], dependencies: [{ kind: "directive", type: i3.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i3.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i3.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1.RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "info", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "routerLink"] }, { kind: "directive", type: i1$1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: i6.NoDataComponent, selector: "pw-no-data", inputs: ["message", "description", "withImage"] }, { kind: "component", type: i7.ProgressSpinner, selector: "p-progressSpinner, p-progress-spinner, p-progressspinner", inputs: ["styleClass", "style", "strokeWidth", "fill", "animationDuration", "ariaLabel"] }, { kind: "directive", type: i8.LazyImgDirective, selector: "img" }, { kind: "component", type: ResourceEditCardLazyComponent, selector: "pw-resource-edit-card-lazy", inputs: ["id", "resourceData", "canEdit"], outputs: ["updated"] }, { kind: "pipe", type: i10.TranslocoPipe, name: "transloco" }] }); }
983
- }
984
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: ResourceVaultComponent, decorators: [{
985
- type: Component,
986
- args: [{ selector: 'pw-resource--vault', standalone: false, template: "<section class=\"resource-vault-section bg-white text-center py-5 extra-top-padding section-outer\">\n <div class=\"container\">\n <div *ngIf=\"showVaultSection\" class=\"d-flex justify-content-between align-items-center flex-wrap mb-5\">\n <h2 class=\"section-heading d-flex align-items-center\" [ngClass]=\"{ 'w-50': isEditingTitle }\">\n <ng-container *ngIf=\"!isEditingTitle; else editTitleBlock\">\n <span *ngIf=\"resourceTitle; else fallback\" [innerHTML]=\"resourceTitle\"></span>\n <ng-template #fallback>Whitepapers &amp; Tools</ng-template>\n <i *ngIf=\"canEditResourcesValue\" class=\"fa fa-edit in-page-edit-icon ms-3 cursor-pointer\" (click)=\"toggleEditTitle()\" (keydown.enter)=\"toggleEditTitle()\" (keydown.space)=\"toggleEditTitle()\" title=\"Edit Title\"></i>\n </ng-container>\n\n <ng-template #editTitleBlock>\n <input [(ngModel)]=\"editedTitle\" class=\"form-control d-inline w-auto me-2\" [ngClass]=\"{ 'w-100': isEditingTitle }\" id=\"input_editedTitle_9216\" name=\"input_editedTitle_9216\" />\n <button class=\"btn btn-sm btn-primary me-1\" (click)=\"saveEditedTitle()\">Save</button>\n <button class=\"btn btn-sm btn-secondary\" (click)=\"isEditingTitle = false\">Cancel</button>\n </ng-template>\n </h2>\n\n <a class=\"view-all\" routerLink=\"/resources/white-papers\">VIEW ALL ></a>\n </div>\n <div class=\"w-100 text-center mt-3\" *ngIf=\"!isLoaded\">\n <p-progressSpinner strokeWidth=\"2\"> </p-progressSpinner>\n </div>\n <div *ngIf=\"posts.length === 0 && isLoaded\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Resource.NoDataMessage' | transloco\"/>\n </div>\n <div class=\"d-flex mt-2 flex-wrap justify-content-center gap-4 video-row\" *ngIf=\"posts.length !== 0 && isLoaded\">\n <div class=\"resource-blog-card text-center p-4\" *ngFor=\"let post of posts\">\n <pw-resource-edit-card-lazy\n [canEdit]=\"canEditResourcesValue\"\n [id]=\"post.id\"\n [resourceData]=\"post\"\n (updated)=\"getPosts(1, 100)\">\n </pw-resource-edit-card-lazy>\n <p class=\"mb-4\" [innerHTML]=\"post.title\"></p>\n <a\n [href]=\"post.external_url || ('/resources/view/' + post?.slug)\"\n target=\"_blank\"\n rel=\"noopener noreferrer\"\n aria-label=\"Navigate to resource\"\n >\n <img\n [src]=\"post.picture.url\"\n class=\"img-fluid my-3 mt-auto\"\n alt=\"Webinar\"\n loading=\"lazy\"\n />\n </a>\n <a *ngIf=\"post?.external_url; else internalLink\"\n class=\"resource-btn mt-3\"\n aria-label=\"Navigate to external url\"\n [href]=\"post.external_url\"\n target=\"_blank\"\n rel=\"noopener noreferrer\">\n <span>{{ post?.cta_text && post.cta_text !== 'null' ? post.cta_text : 'Read Now' }}</span>\n <span class=\"arrow\">\u2192</span>\n </a>\n\n <ng-template #internalLink>\n <a class=\"resource-btn mt-3\" aria-label=\"Navigate to resource view\" [href]=\"'/resources/view/' + post?.slug\" target=\"_blank\">\n <span>{{ post?.cta_text && post.cta_text !== 'null' ? post.cta_text : 'Read Now' }}</span>\n <span class=\"arrow\">\u2192</span>\n </a>\n </ng-template>\n </div>\n </div>\n </div>\n</section>\n", styles: [".bold{font-weight:700}.resource-heading{margin-bottom:2rem}.resource-note{margin-top:1rem;font-size:.85rem;color:#555}.resource-divider{border:0;height:40px;width:100%;background:linear-gradient(to bottom,#0000,#00000026);margin:0}.press-release-icon{height:auto!important;margin:0 11px 1.9rem;display:block;align-self:center;width:auto!important;aspect-ratio:0!important;object-fit:cover;margin-top:auto;margin-right:0!important}.resource-vault-section{padding:60px 0;background:#fff;padding-bottom:9rem!important;padding-top:7rem!important;box-shadow:0 4px 32px -14px #40576d4d!important}.resource-vault-section .vault-heading{font-size:3rem;font-weight:300}.resource-vault-section .explore-link{color:#000;font-weight:400;text-decoration:none;font-size:1.5rem}.resource-vault-section .resource-blog-card{display:flex;flex-direction:column;justify-content:space-between;background-color:#fff;border-radius:30px;box-shadow:0 20px 40px #00000014;padding:25px;text-align:center;width:338px;height:auto!important}.resource-vault-section .resource-blog-card h5{font-size:1.5rem;font-weight:400;margin-bottom:.5rem;color:var(--text-color, black)}.resource-vault-section .resource-blog-card p{font-size:1.5rem;color:var(--text-color, black);line-height:2rem}.resource-vault-section .resource-blog-card img{width:100%;border-radius:10px;aspect-ratio:1/1;object-fit:cover;margin-top:auto;margin-right:0!important;max-width:250px!important;align-self:center!important}.resource-vault-section .resource-blog-card iframe{height:210px;border-radius:10px;object-fit:cover;margin-right:0!important;max-width:280px!important}.resource-vault-section .resource-blog-card .resource-btn{background-color:var(--text-color, black);color:#fff;margin-top:auto;padding:10px 24px;border-radius:24px;font-size:1.5rem;font-weight:500;width:100%;max-width:240px;cursor:pointer;transition:background .3s ease;display:flex;justify-content:space-between;align-self:center;align-items:center;text-align:left;text-decoration:none;border:1px solid;box-shadow:none!important;border-color:var(--text-color, black)}.resource-vault-section .resource-blog-card .resource-btn:hover{background:#fff;color:var(--text-color, black)!important}.resource-vault-section .vault-description{text-align:left;max-width:657px;color:#182527;line-height:2.3rem!important;font-size:1.65rem}@media (width <= 1200px){.resource-vault-section .vault-heading{font-size:3.5rem}.resource-vault-section .vault-description{margin-top:1.35rem}.resource-vault-section .resource-btn{margin-left:0!important}}.video-row{gap:5.5rem!important;margin-top:3rem!important}@media (width >= 991px){section.bg-white.text-center.extra-top-padding{position:relative;overflow:hidden}section.bg-white.text-center.extra-top-padding .banner-header{margin-bottom:4rem!important}}.vault-header{text-align:left}@media (width >= 768px) and (width <= 1200px){.container{padding:0 6rem!important}}@media (width <= 768px){.video-row{gap:3rem!important}}@media (max-width: 768px){.resource-vault-section{padding-bottom:6rem!important}.resource-vault-section .container{padding-top:0rem!important;padding-bottom:0rem!important}.vault-header{text-align:center!important}.vault-heading{font-size:3rem!important}}@media (width <= 1200px){.container{padding:7rem 3rem 1rem!important}}\n"] }]
987
- }], ctorParameters: () => [{ type: ResourceService }, { type: i2.TagService }, { type: i2.AuthService }, { type: i0.Injector }], propDecorators: { showVaultSection: [{
988
- type: Input
989
- }], postSlice: [{
990
- type: Input
991
- }], categoryId: [{
992
- type: Input
993
- }], resourceTitle: [{
994
- type: Input
995
- }], tag: [{
996
- type: Input
997
- }], isLoadedChange: [{
998
- type: Output
999
- }] } });
1000
-
1001
- class ResourceVideoCardComponent extends AppBaseComponent {
1002
- constructor(sanitizer, resourceService, tagService, cdr, injector) {
1003
- super(injector);
1004
- this.sanitizer = sanitizer;
1005
- this.resourceService = resourceService;
1006
- this.tagService = tagService;
1007
- this.cdr = cdr;
1008
- this.showVideoSection = false;
1009
- this.postSlice = false;
1010
- this.canEditResourcesValue = false;
1011
- this.masterSubscriptionId = this.appConfig.master_subscription.subscription_id;
1012
- this.posts = [];
1013
- this.isLoaded = false;
1014
- this.videoStates = {};
1015
- this.isEditingTitle = false;
1016
- }
1017
- ngOnInit() {
1018
- if (this.userLoggedIn) {
1019
- this.localStorage.getItem$('product').subscribe(res => {
1020
- const data = res ? JSON.parse(res) : null;
1021
- this.subscriptionId = data?.subscriptionId;
1022
- });
1023
- }
1024
- this.getPosts(1, 10);
1025
- }
1026
- ngOnChanges(changes) {
1027
- if (changes['user'] || changes['userLoggedIn']) {
1028
- if (this.userLoggedIn && this.user) {
1029
- this.updateCanEditResourcesValue();
1030
- }
1031
- }
1032
- }
1033
- loadVideo(post) {
1034
- if (!post.external_url)
1035
- return;
1036
- const slug = post.slug;
1037
- let externalUrl = post.external_url;
1038
- // Append autoplay only when clicked
1039
- externalUrl += externalUrl.includes('?') ? '&autoplay=1' : '?autoplay=1';
1040
- // baseUrl is a trusted internal source (e.g. YouTube embed URL)
1041
- this.videoStates[slug].url = this.sanitizer.bypassSecurityTrustResourceUrl(externalUrl); //NOSONAR
1042
- }
1043
- getPosts(page, pageSize) {
1044
- this.isLoaded = false;
1045
- this.resourceService
1046
- .getPublicPosts(this.getEffectiveSubscriptionId(), page, pageSize, '', this.categoryId)
1047
- .subscribe(response => {
1048
- const sortedPosts = (response.posts ?? [])
1049
- .filter(post => post.showcase === true)
1050
- .sort((a, b) => new Date(b.published_at).getTime() - new Date(a.published_at).getTime());
1051
- this.posts = this.postSlice ? sortedPosts : [...sortedPosts].slice(0, 3);
1052
- this.posts.forEach(post => {
1053
- if (post.external_url) {
1054
- this.videoStates[post.slug] = {
1055
- loaded: true,
1056
- // baseUrl is a trusted internal source (e.g. YouTube embed URL)
1057
- url: this.sanitizer.bypassSecurityTrustResourceUrl(post.external_url) //NOSONAR
1058
- };
1059
- }
1060
- });
1061
- })
1062
- .add(() => {
1063
- this.isLoaded = true;
1064
- this.cdr.markForCheck();
1065
- });
1066
- }
1067
- toggleTagEditTitle() {
1068
- this.isEditingTitle = true;
1069
- this.editedTitle = this.resourceTitle;
1070
- }
1071
- saveEditedTitle() {
1072
- HelperService.updateTagTitle(this.tag, this.editedTitle, this.tagService, this.getEffectiveSubscriptionId(), this.toast).subscribe(() => {
1073
- this.resourceTitle = this.editedTitle;
1074
- this.isEditingTitle = false;
1075
- this.cdr.markForCheck();
1076
- });
1077
- }
1078
- /** Helper method to get effective subscription ID */
1079
- getEffectiveSubscriptionId() {
1080
- return HelperService.getEffectiveSubscriptionId(this.user, this.subscriptionId, this.masterSubscriptionId);
1081
- }
1082
- updateCanEditResourcesValue() {
1083
- this.canEditResourcesValue = HelperService.canEditResources(this.user, this.userLoggedIn, this.permissionService);
1084
- }
1085
- canEditResources() {
1086
- return this.canEditResourcesValue;
1087
- }
1088
- trackByPostId(index, post) {
1089
- return post.id;
1090
- }
1091
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: ResourceVideoCardComponent, deps: [{ token: i3$1.DomSanitizer }, { token: ResourceService }, { token: i2.TagService }, { token: i0.ChangeDetectorRef }, { token: i0.Injector }], target: i0.ɵɵFactoryTarget.Component }); }
1092
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.20", type: ResourceVideoCardComponent, isStandalone: false, selector: "pw-resource-video-card", inputs: { showVideoSection: "showVideoSection", categoryId: "categoryId", tag: "tag", postSlice: "postSlice", resourceTitle: "resourceTitle", user: "user", userLoggedIn: "userLoggedIn" }, usesInheritance: true, usesOnChanges: true, ngImport: i0, template: "<section class=\"resource-vault-section bg-white text-center py-5 extra-top-padding section-outer\">\n <div class=\"container\">\n <div *ngIf=\"showVideoSection\" class=\"d-flex justify-content-between align-items-center flex-wrap\">\n <h2 class=\"section-heading d-flex align-items-center\" [ngClass]=\"{ 'w-50': isEditingTitle }\">\n <ng-container *ngIf=\"!isEditingTitle; else editTitleBlock\">\n <span *ngIf=\"resourceTitle; else fallback\" [innerHTML]=\"resourceTitle\"></span>\n <ng-template #fallback>On-Demand Videos</ng-template>\n <i *ngIf=\"canEditResourcesValue\" class=\"fa fa-edit in-page-edit-icon ms-3 cursor-pointer\" (click)=\"toggleTagEditTitle()\" (keydown.enter)=\"toggleTagEditTitle()\" (keydown.space)=\"toggleTagEditTitle()\" title=\"Edit Title\"></i>\n </ng-container>\n\n <ng-template #editTitleBlock>\n <input [(ngModel)]=\"editedTitle\" class=\"form-control d-inline w-auto me-2\" [ngClass]=\"{ 'w-100': isEditingTitle }\" id=\"input_editedTitle_9216\" name=\"input_editedTitle_9216\" />\n <button class=\"btn btn-sm btn-primary me-1\" (click)=\"saveEditedTitle()\">Save</button>\n <button class=\"btn btn-sm btn-secondary\" (click)=\"isEditingTitle = false\">Cancel</button>\n </ng-template>\n </h2>\n <a class=\"view-all\" routerLink=\"/resources/videos\">VIEW ALL ></a>\n </div>\n <div class=\"w-100 text-center mt-3\" *ngIf=\"!isLoaded\">\n <p-progressSpinner strokeWidth=\"2\"> </p-progressSpinner>\n </div>\n <div *ngIf=\"posts.length === 0 && isLoaded\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Resource.NoDataMessage' | transloco\"/>\n </div>\n <div class=\"row mt-5 d-flex flex-wrap justify-content-center video-row\" *ngIf=\"posts.length !== 0 && isLoaded\">\n <div class=\"resource-blog-card\" *ngFor=\"let post of posts; trackBy: trackByPostId\">\n <pw-resource-edit-card-lazy\n [canEdit]=\"canEditResourcesValue\"\n [id]=\"post.id\"\n [resourceData]=\"post\"\n (updated)=\"getPosts(1, 10)\">\n </pw-resource-edit-card-lazy>\n <p [innerHTML]=\"post.title\" class=\"mb-5\"></p>\n <a [href]=\" post.external_url\" target=\"_blank\">\n <img\n [src]=\"post.picture?.url\"\n class=\"img-fluid mb-3\"\n [alt]=\"post.title\"\n loading=\"lazy\" />\n </a>\n\n <a class=\"resource-btn mt-3\" [href]=\" post.external_url\" target=\"_blank\">\n <span>{{ post?.cta_text && post.cta_text !== 'null' ? post.cta_text : 'Watch now' }}</span>\n <span class=\"arrow\">\u2192</span>\n </a>\n </div>\n </div>\n </div>\n\n</section>\n", styles: [".bold{font-weight:700}.resource-heading{margin-bottom:2rem}.resource-note{margin-top:1rem;font-size:.85rem;color:#555}.resource-divider{border:0;height:40px;width:100%;background:linear-gradient(to bottom,#0000,#00000026);margin:0}.press-release-icon{height:auto!important;margin:0 11px 1.9rem;display:block;align-self:center;width:auto!important;aspect-ratio:0!important;object-fit:cover;margin-top:auto;margin-right:0!important}.resource-vault-section{padding:60px 0;background:#fff;padding-bottom:9rem!important;padding-top:7rem!important;box-shadow:0 4px 32px -14px #40576d4d!important}.resource-vault-section .vault-heading{font-size:3rem;font-weight:300}.resource-vault-section .explore-link{color:#000;font-weight:400;text-decoration:none;font-size:1.5rem}.resource-vault-section .resource-blog-card{display:flex;flex-direction:column;justify-content:space-between;background-color:#fff;border-radius:30px;box-shadow:0 20px 40px #00000014;padding:25px;text-align:center;width:338px;height:auto!important}.resource-vault-section .resource-blog-card h5{font-size:1.5rem;font-weight:400;margin-bottom:.5rem;color:var(--text-color, black)}.resource-vault-section .resource-blog-card p{font-size:1.5rem;color:var(--text-color, black);line-height:2rem}.resource-vault-section .resource-blog-card img{width:100%;border-radius:10px;aspect-ratio:1/1;object-fit:cover;margin-top:auto;margin-right:0!important;max-width:250px!important;align-self:center!important}.resource-vault-section .resource-blog-card iframe{height:210px;border-radius:10px;object-fit:cover;margin-right:0!important;max-width:280px!important}.resource-vault-section .resource-blog-card .resource-btn{background-color:var(--text-color, black);color:#fff;margin-top:auto;padding:10px 24px;border-radius:24px;font-size:1.5rem;font-weight:500;width:100%;max-width:240px;cursor:pointer;transition:background .3s ease;display:flex;justify-content:space-between;align-self:center;align-items:center;text-align:left;text-decoration:none;border:1px solid;box-shadow:none!important;border-color:var(--text-color, black)}.resource-vault-section .resource-blog-card .resource-btn:hover{background:#fff;color:var(--text-color, black)!important}.resource-vault-section .vault-description{text-align:left;max-width:657px;color:#182527;line-height:2.3rem!important;font-size:1.65rem}@media (width <= 1200px){.resource-vault-section .vault-heading{font-size:3.5rem}.resource-vault-section .vault-description{margin-top:1.35rem}.resource-vault-section .resource-btn{margin-left:0!important}}.video-row{gap:5.5rem!important;margin-top:3rem!important}@media (width >= 991px){section.bg-white.text-center.extra-top-padding{position:relative;overflow:hidden}section.bg-white.text-center.extra-top-padding .banner-header{margin-bottom:4rem!important}}.vault-header{text-align:left}@media (width >= 768px) and (width <= 1200px){.container{padding:0 6rem!important}}@media (width <= 768px){.video-row{gap:3rem!important}}@media (max-width: 768px){.resource-vault-section{padding-bottom:6rem!important}.resource-vault-section .container{padding-top:0rem!important;padding-bottom:0rem!important}.vault-header{text-align:center!important}.vault-heading{font-size:3rem!important}}@media (width <= 1200px){.container{padding:7rem 3rem 1rem!important}}\n"], dependencies: [{ kind: "directive", type: i3.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i3.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i3.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1.RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "info", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "routerLink"] }, { kind: "directive", type: i1$1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: i6.NoDataComponent, selector: "pw-no-data", inputs: ["message", "description", "withImage"] }, { kind: "component", type: i7.ProgressSpinner, selector: "p-progressSpinner, p-progress-spinner, p-progressspinner", inputs: ["styleClass", "style", "strokeWidth", "fill", "animationDuration", "ariaLabel"] }, { kind: "directive", type: i8.LazyImgDirective, selector: "img" }, { kind: "component", type: ResourceEditCardLazyComponent, selector: "pw-resource-edit-card-lazy", inputs: ["id", "resourceData", "canEdit"], outputs: ["updated"] }, { kind: "pipe", type: i10.TranslocoPipe, name: "transloco" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
1093
- }
1094
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: ResourceVideoCardComponent, decorators: [{
1095
- type: Component,
1096
- args: [{ selector: 'pw-resource-video-card', changeDetection: ChangeDetectionStrategy.OnPush, standalone: false, template: "<section class=\"resource-vault-section bg-white text-center py-5 extra-top-padding section-outer\">\n <div class=\"container\">\n <div *ngIf=\"showVideoSection\" class=\"d-flex justify-content-between align-items-center flex-wrap\">\n <h2 class=\"section-heading d-flex align-items-center\" [ngClass]=\"{ 'w-50': isEditingTitle }\">\n <ng-container *ngIf=\"!isEditingTitle; else editTitleBlock\">\n <span *ngIf=\"resourceTitle; else fallback\" [innerHTML]=\"resourceTitle\"></span>\n <ng-template #fallback>On-Demand Videos</ng-template>\n <i *ngIf=\"canEditResourcesValue\" class=\"fa fa-edit in-page-edit-icon ms-3 cursor-pointer\" (click)=\"toggleTagEditTitle()\" (keydown.enter)=\"toggleTagEditTitle()\" (keydown.space)=\"toggleTagEditTitle()\" title=\"Edit Title\"></i>\n </ng-container>\n\n <ng-template #editTitleBlock>\n <input [(ngModel)]=\"editedTitle\" class=\"form-control d-inline w-auto me-2\" [ngClass]=\"{ 'w-100': isEditingTitle }\" id=\"input_editedTitle_9216\" name=\"input_editedTitle_9216\" />\n <button class=\"btn btn-sm btn-primary me-1\" (click)=\"saveEditedTitle()\">Save</button>\n <button class=\"btn btn-sm btn-secondary\" (click)=\"isEditingTitle = false\">Cancel</button>\n </ng-template>\n </h2>\n <a class=\"view-all\" routerLink=\"/resources/videos\">VIEW ALL ></a>\n </div>\n <div class=\"w-100 text-center mt-3\" *ngIf=\"!isLoaded\">\n <p-progressSpinner strokeWidth=\"2\"> </p-progressSpinner>\n </div>\n <div *ngIf=\"posts.length === 0 && isLoaded\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Resource.NoDataMessage' | transloco\"/>\n </div>\n <div class=\"row mt-5 d-flex flex-wrap justify-content-center video-row\" *ngIf=\"posts.length !== 0 && isLoaded\">\n <div class=\"resource-blog-card\" *ngFor=\"let post of posts; trackBy: trackByPostId\">\n <pw-resource-edit-card-lazy\n [canEdit]=\"canEditResourcesValue\"\n [id]=\"post.id\"\n [resourceData]=\"post\"\n (updated)=\"getPosts(1, 10)\">\n </pw-resource-edit-card-lazy>\n <p [innerHTML]=\"post.title\" class=\"mb-5\"></p>\n <a [href]=\" post.external_url\" target=\"_blank\">\n <img\n [src]=\"post.picture?.url\"\n class=\"img-fluid mb-3\"\n [alt]=\"post.title\"\n loading=\"lazy\" />\n </a>\n\n <a class=\"resource-btn mt-3\" [href]=\" post.external_url\" target=\"_blank\">\n <span>{{ post?.cta_text && post.cta_text !== 'null' ? post.cta_text : 'Watch now' }}</span>\n <span class=\"arrow\">\u2192</span>\n </a>\n </div>\n </div>\n </div>\n\n</section>\n", styles: [".bold{font-weight:700}.resource-heading{margin-bottom:2rem}.resource-note{margin-top:1rem;font-size:.85rem;color:#555}.resource-divider{border:0;height:40px;width:100%;background:linear-gradient(to bottom,#0000,#00000026);margin:0}.press-release-icon{height:auto!important;margin:0 11px 1.9rem;display:block;align-self:center;width:auto!important;aspect-ratio:0!important;object-fit:cover;margin-top:auto;margin-right:0!important}.resource-vault-section{padding:60px 0;background:#fff;padding-bottom:9rem!important;padding-top:7rem!important;box-shadow:0 4px 32px -14px #40576d4d!important}.resource-vault-section .vault-heading{font-size:3rem;font-weight:300}.resource-vault-section .explore-link{color:#000;font-weight:400;text-decoration:none;font-size:1.5rem}.resource-vault-section .resource-blog-card{display:flex;flex-direction:column;justify-content:space-between;background-color:#fff;border-radius:30px;box-shadow:0 20px 40px #00000014;padding:25px;text-align:center;width:338px;height:auto!important}.resource-vault-section .resource-blog-card h5{font-size:1.5rem;font-weight:400;margin-bottom:.5rem;color:var(--text-color, black)}.resource-vault-section .resource-blog-card p{font-size:1.5rem;color:var(--text-color, black);line-height:2rem}.resource-vault-section .resource-blog-card img{width:100%;border-radius:10px;aspect-ratio:1/1;object-fit:cover;margin-top:auto;margin-right:0!important;max-width:250px!important;align-self:center!important}.resource-vault-section .resource-blog-card iframe{height:210px;border-radius:10px;object-fit:cover;margin-right:0!important;max-width:280px!important}.resource-vault-section .resource-blog-card .resource-btn{background-color:var(--text-color, black);color:#fff;margin-top:auto;padding:10px 24px;border-radius:24px;font-size:1.5rem;font-weight:500;width:100%;max-width:240px;cursor:pointer;transition:background .3s ease;display:flex;justify-content:space-between;align-self:center;align-items:center;text-align:left;text-decoration:none;border:1px solid;box-shadow:none!important;border-color:var(--text-color, black)}.resource-vault-section .resource-blog-card .resource-btn:hover{background:#fff;color:var(--text-color, black)!important}.resource-vault-section .vault-description{text-align:left;max-width:657px;color:#182527;line-height:2.3rem!important;font-size:1.65rem}@media (width <= 1200px){.resource-vault-section .vault-heading{font-size:3.5rem}.resource-vault-section .vault-description{margin-top:1.35rem}.resource-vault-section .resource-btn{margin-left:0!important}}.video-row{gap:5.5rem!important;margin-top:3rem!important}@media (width >= 991px){section.bg-white.text-center.extra-top-padding{position:relative;overflow:hidden}section.bg-white.text-center.extra-top-padding .banner-header{margin-bottom:4rem!important}}.vault-header{text-align:left}@media (width >= 768px) and (width <= 1200px){.container{padding:0 6rem!important}}@media (width <= 768px){.video-row{gap:3rem!important}}@media (max-width: 768px){.resource-vault-section{padding-bottom:6rem!important}.resource-vault-section .container{padding-top:0rem!important;padding-bottom:0rem!important}.vault-header{text-align:center!important}.vault-heading{font-size:3rem!important}}@media (width <= 1200px){.container{padding:7rem 3rem 1rem!important}}\n"] }]
1097
- }], ctorParameters: () => [{ type: i3$1.DomSanitizer }, { type: ResourceService }, { type: i2.TagService }, { type: i0.ChangeDetectorRef }, { type: i0.Injector }], propDecorators: { showVideoSection: [{
1098
- type: Input
1099
- }], categoryId: [{
1100
- type: Input
1101
- }], tag: [{
1102
- type: Input
1103
- }], postSlice: [{
1104
- type: Input
1105
- }], resourceTitle: [{
1106
- type: Input
1107
- }], user: [{
1108
- type: Input
1109
- }], userLoggedIn: [{
1110
- type: Input
1111
- }] } });
1112
-
1113
- class UpcomingEventCardComponent extends AppBaseComponent {
1114
- constructor(resourceService, tagService, cdr, injector) {
1115
- super(injector);
1116
- this.resourceService = resourceService;
1117
- this.tagService = tagService;
1118
- this.cdr = cdr;
1119
- this.showEventContent = false;
1120
- this.postSlice = false;
1121
- this.canEditResourcesValue = false;
1122
- this.now = new Date().getTime();
1123
- this.isEditingTitle = false;
1124
- this.masterSubscriptionId = this.appConfig.master_subscription.subscription_id;
1125
- this.posts = [];
1126
- this.isLoaded = false;
1127
- }
1128
- ngOnInit() {
1129
- if (this.userLoggedIn) {
1130
- this.localStorage.getItem$('product').subscribe(res => {
1131
- const data = res ? JSON.parse(res) : null;
1132
- this.subscriptionId = data?.subscriptionId;
1133
- });
1134
- this.getPostTags();
1135
- }
1136
- else {
1137
- this.getPostTags();
1138
- }
1139
- }
1140
- ngOnChanges(changes) {
1141
- if (changes['user'] || changes['userLoggedIn']) {
1142
- if (this.userLoggedIn && this.user) {
1143
- this.updateCanEditResourcesValue();
1144
- }
1145
- }
1146
- }
1147
- getPostTags() {
1148
- this.tagService
1149
- .getTagsByType('post_categories', {}, this.getEffectiveSubscriptionId())
1150
- .subscribe(response => {
1151
- this.blogPostTag = response.tags.find(tag => tag.name === 'Events');
1152
- if (this.blogPostTag?.tag_category_id) {
1153
- if (this.postSlice) {
1154
- this.getPosts(1, 100);
1155
- }
1156
- else {
1157
- this.getAllPosts(1, 100);
1158
- }
1159
- }
1160
- else {
1161
- this.isLoaded = true;
1162
- this.cdr.markForCheck();
1163
- }
1164
- });
1165
- }
1166
- getPosts(page, pageSize) {
1167
- this.isLoaded = false;
1168
- this.resourceService
1169
- .getPublicPosts(this.getEffectiveSubscriptionId(), page, pageSize, '', this.categoryId ?? this.blogPostTag?.tag_category_id)
1170
- .subscribe(response => {
1171
- const sortedPosts = (response.posts ?? [])
1172
- .filter(post => post.showcase === true && new Date(post?.when).getTime() > this.now)
1173
- .sort((a, b) => new Date(b.published_at).getTime() - new Date(a.published_at).getTime());
1174
- this.posts = sortedPosts;
1175
- })
1176
- .add(() => {
1177
- this.isLoaded = true;
1178
- this.cdr.markForCheck();
1179
- });
1180
- }
1181
- isUpcoming(post) {
1182
- return new Date(post?.when).getTime() > this.now;
1183
- }
1184
- getAllPosts(page, pageSize) {
1185
- this.isLoaded = false;
1186
- this.resourceService
1187
- .getPublicPosts(this.getEffectiveSubscriptionId(), page, pageSize, '', this.categoryId ?? this.blogPostTag?.tag_category_id)
1188
- .subscribe(response => {
1189
- const sortedPosts = (response.posts ?? [])
1190
- .filter(post => post.showcase === true)
1191
- .sort((a, b) => new Date(b.when).getTime() - new Date(a.when).getTime());
1192
- this.posts = [...sortedPosts].slice(0, 3).reverse();
1193
- })
1194
- .add(() => {
1195
- this.isLoaded = true;
1196
- this.cdr.markForCheck();
1197
- });
1198
- }
1199
- toggleEditTitle() {
1200
- this.isEditingTitle = true;
1201
- this.editedTitle = this.resourceTitle;
1202
- }
1203
- saveEditedTitle() {
1204
- HelperService.updateTagTitle(this.tag, this.editedTitle, this.tagService, this.getEffectiveSubscriptionId(), this.toast).subscribe(() => {
1205
- this.resourceTitle = this.editedTitle;
1206
- this.isEditingTitle = false;
1207
- this.cdr.markForCheck();
1208
- });
1209
- }
1210
- /** Helper method to get effective subscription ID */
1211
- getEffectiveSubscriptionId() {
1212
- return HelperService.getEffectiveSubscriptionId(this.user, this.subscriptionId, this.masterSubscriptionId);
1213
- }
1214
- updateCanEditResourcesValue() {
1215
- this.canEditResourcesValue = HelperService.canEditResources(this.user, this.userLoggedIn, this.permissionService);
1216
- }
1217
- canEditResources() {
1218
- return this.canEditResourcesValue;
1219
- }
1220
- trackByPostId(index, post) {
1221
- return post.id;
1222
- }
1223
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: UpcomingEventCardComponent, deps: [{ token: ResourceService }, { token: i2.TagService }, { token: i0.ChangeDetectorRef }, { token: i0.Injector }], target: i0.ɵɵFactoryTarget.Component }); }
1224
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.20", type: UpcomingEventCardComponent, isStandalone: false, selector: "pw-upcoming-event-card", inputs: { showEventContent: "showEventContent", categoryId: "categoryId", tag: "tag", postSlice: "postSlice", resourceTitle: "resourceTitle", user: "user", userLoggedIn: "userLoggedIn" }, usesInheritance: true, usesOnChanges: true, ngImport: i0, template: "<section class=\"resource-vault-section bg-white text-center py-5 extra-top-padding section-outer\">\n <div class=\"container\">\n <div *ngIf=\"showEventContent\" class=\"d-flex justify-content-between align-items-center flex-wrap\">\n <h2 class=\"section-heading d-flex align-items-center\" [ngClass]=\"{ 'w-50': isEditingTitle }\">\n <ng-container *ngIf=\"!isEditingTitle; else editTitleBlock\">\n <span *ngIf=\"resourceTitle; else fallback\" [innerHTML]=\"resourceTitle\"></span>\n <ng-template #fallback>Events &amp; Webinars</ng-template>\n <i *ngIf=\"canEditResourcesValue\" class=\"fa fa-edit in-page-edit-icon ms-3 cursor-pointer\" (click)=\"toggleEditTitle()\" (keydown.enter)=\"toggleEditTitle()\" (keydown.space)=\"toggleEditTitle()\" title=\"Edit Title\"></i>\n </ng-container>\n\n <ng-template #editTitleBlock>\n <input [(ngModel)]=\"editedTitle\" class=\"form-control d-inline w-auto me-2\" [ngClass]=\"{ 'w-100': isEditingTitle }\" id=\"input_editedTitle_7936\" name=\"input_editedTitle_7936\" />\n <button class=\"btn btn-sm btn-primary me-1\" (click)=\"saveEditedTitle()\">Save</button>\n <button class=\"btn btn-sm btn-secondary\" (click)=\"isEditingTitle = false\">Cancel</button>\n </ng-template>\n </h2>\n <a class=\"view-all\" routerLink=\"/resources/events\">VIEW ALL ></a>\n </div>\n <div *ngIf=\"!showEventContent\" class=\"d-md-flex justify-content-between align-items-start\">\n <h2 class=\"section-heading d-flex align-items-center\" [ngClass]=\"{ 'w-50': isEditingTitle }\">\n <ng-container *ngIf=\"!isEditingTitle; else editTitleBlock\">\n <span *ngIf=\"resourceTitle; else fallback\" [innerHTML]=\"resourceTitle\"></span>\n <ng-template #fallback>Upcoming Events</ng-template>\n <i *ngIf=\"canEditResourcesValue\" class=\"fa fa-edit in-page-edit-icon ms-3 cursor-pointer\" (click)=\"toggleEditTitle()\" (keydown.enter)=\"toggleEditTitle()\" (keydown.space)=\"toggleEditTitle()\" title=\"Edit Title\"></i>\n </ng-container>\n\n <ng-template #editTitleBlock>\n <input [(ngModel)]=\"editedTitle\" class=\"form-control d-inline w-auto me-2\" [ngClass]=\"{ 'w-100': isEditingTitle }\" id=\"input_editedTitle_7936\" name=\"input_editedTitle_7936\" />\n <button class=\"btn btn-sm btn-primary me-1\" (click)=\"saveEditedTitle()\">Save</button>\n <button class=\"btn btn-sm btn-secondary\" (click)=\"isEditingTitle = false\">Cancel</button>\n </ng-template>\n </h2>\n </div>\n\n <div class=\"w-100 text-center mt-3\" *ngIf=\"!isLoaded\">\n <p-progressSpinner strokeWidth=\"2\"> </p-progressSpinner>\n </div>\n <div *ngIf=\"posts.length === 0 && isLoaded\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Resource.NoDataMessage' | transloco\"/>\n </div>\n\n <div class=\"row mt-5 d-flex flex-wrap justify-content-center gap-4 video-row\" *ngIf=\"posts.length !== 0 && isLoaded\">\n <div class=\"resource-blog-card d text-center p-4\" *ngFor=\"let post of posts; trackBy: trackByPostId\">\n <pw-resource-edit-card-lazy\n [canEdit]=\"canEditResourcesValue\"\n [id]=\"post.id\"\n [resourceData]=\"post\"\n (updated)=\"getAllPosts(1, 100)\">\n </pw-resource-edit-card-lazy>\n <ng-container *ngIf=\"postSlice; else conditionalCheck\">\n <h5 class=\"badge-title fw-bold\">UPCOMING:</h5>\n </ng-container>\n\n <ng-template #conditionalCheck>\n <h5 class=\"badge-title fw-bold\">\n {{ isUpcoming(post) ? 'UPCOMING:' : 'REPLAY:' }}\n </h5>\n </ng-template>\n\n <p class=\"event-title mb-4\" [innerHtml]=\"post?.title\"></p>\n <a\n [href]=\"post.external_url || ('/resources/view/' + post?.slug)\"\n target=\"_blank\"\n rel=\"noopener noreferrer\"\n aria-label=\"Navigate to resource\"\n >\n <img\n [src]=\"post.picture.url\"\n class=\"img-fluid my-3 mt-auto\"\n alt=\"Webinar\"\n loading=\"lazy\"\n />\n </a>\n\n <a *ngIf=\"post?.external_url; else internalLink\"\n class=\"resource-btn mt-3\"\n aria-label=\"Navigate to external url\"\n [href]=\"post.external_url\"\n target=\"_blank\"\n rel=\"noopener noreferrer\">\n <span>{{ post?.cta_text && post.cta_text !== 'null' ? post.cta_text : 'Read Now' }}</span>\n <span class=\"arrow\">\u2192</span>\n </a>\n\n <ng-template #internalLink>\n <a class=\"resource-btn mt-3\" aria-label=\"Navigate to resource view\" [href]=\"'/resources/view/' + post?.slug\" target=\"_blank\">\n <span>{{ post?.cta_text && post.cta_text !== 'null' ? post.cta_text : 'Read Now' }}</span>\n <span class=\"arrow\">\u2192</span>\n </a>\n </ng-template>\n </div>\n </div>\n </div>\n</section>\n\n\n<section class=\"bg-white\" *ngIf=\"!showEventContent\">\n <pw-replay-event-card [resourceTitle]=\"resourceTitle\" [user]=\"user\" [userLoggedIn]=\"userLoggedIn\"></pw-replay-event-card>\n</section>", styles: [".bold{font-weight:700}.resource-heading{margin-bottom:2rem}.resource-note{margin-top:1rem;font-size:.85rem;color:#555}.resource-divider{border:0;height:40px;width:100%;background:linear-gradient(to bottom,#0000,#00000026);margin:0}.press-release-icon{height:auto!important;margin:0 11px 1.9rem;display:block;align-self:center;width:auto!important;aspect-ratio:0!important;object-fit:cover;margin-top:auto;margin-right:0!important}.resource-vault-section{padding:60px 0;background:#fff;padding-bottom:9rem!important;padding-top:7rem!important;box-shadow:0 4px 32px -14px #40576d4d!important}.resource-vault-section .vault-heading{font-size:3rem;font-weight:300}.resource-vault-section .explore-link{color:#000;font-weight:400;text-decoration:none;font-size:1.5rem}.resource-vault-section .resource-blog-card{display:flex;flex-direction:column;justify-content:space-between;background-color:#fff;border-radius:30px;box-shadow:0 20px 40px #00000014;padding:25px;text-align:center;width:338px;height:auto!important}.resource-vault-section .resource-blog-card h5{font-size:1.5rem;font-weight:400;margin-bottom:.5rem;color:var(--text-color, black)}.resource-vault-section .resource-blog-card p{font-size:1.5rem;color:var(--text-color, black);line-height:2rem}.resource-vault-section .resource-blog-card img{width:100%;border-radius:10px;aspect-ratio:1/1;object-fit:cover;margin-top:auto;margin-right:0!important;max-width:250px!important;align-self:center!important}.resource-vault-section .resource-blog-card iframe{height:210px;border-radius:10px;object-fit:cover;margin-right:0!important;max-width:280px!important}.resource-vault-section .resource-blog-card .resource-btn{background-color:var(--text-color, black);color:#fff;margin-top:auto;padding:10px 24px;border-radius:24px;font-size:1.5rem;font-weight:500;width:100%;max-width:240px;cursor:pointer;transition:background .3s ease;display:flex;justify-content:space-between;align-self:center;align-items:center;text-align:left;text-decoration:none;border:1px solid;box-shadow:none!important;border-color:var(--text-color, black)}.resource-vault-section .resource-blog-card .resource-btn:hover{background:#fff;color:var(--text-color, black)!important}.resource-vault-section .vault-description{text-align:left;max-width:657px;color:#182527;line-height:2.3rem!important;font-size:1.65rem}@media (width <= 1200px){.resource-vault-section .vault-heading{font-size:3.5rem}.resource-vault-section .vault-description{margin-top:1.35rem}.resource-vault-section .resource-btn{margin-left:0!important}}.video-row{gap:5.5rem!important;margin-top:3rem!important}@media (width >= 991px){section.bg-white.text-center.extra-top-padding{position:relative;overflow:hidden}section.bg-white.text-center.extra-top-padding .banner-header{margin-bottom:4rem!important}}.vault-header{text-align:left}@media (width >= 768px) and (width <= 1200px){.container{padding:0 6rem!important}}@media (width <= 768px){.video-row{gap:3rem!important}}@media (max-width: 768px){.resource-vault-section{padding-bottom:6rem!important}.resource-vault-section .container{padding-top:0rem!important;padding-bottom:0rem!important}.vault-header{text-align:center!important}.vault-heading{font-size:3rem!important}}@media (width <= 1200px){.container{padding:7rem 3rem 1rem!important}}\n"], dependencies: [{ kind: "directive", type: i3.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i3.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i3.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1.RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "info", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "routerLink"] }, { kind: "directive", type: i1$1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: i6.NoDataComponent, selector: "pw-no-data", inputs: ["message", "description", "withImage"] }, { kind: "component", type: i7.ProgressSpinner, selector: "p-progressSpinner, p-progress-spinner, p-progressspinner", inputs: ["styleClass", "style", "strokeWidth", "fill", "animationDuration", "ariaLabel"] }, { kind: "directive", type: i8.LazyImgDirective, selector: "img" }, { kind: "component", type: ResourceEditCardLazyComponent, selector: "pw-resource-edit-card-lazy", inputs: ["id", "resourceData", "canEdit"], outputs: ["updated"] }, { kind: "pipe", type: i10.TranslocoPipe, name: "transloco" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
1225
- }
1226
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: UpcomingEventCardComponent, decorators: [{
1227
- type: Component,
1228
- args: [{ selector: 'pw-upcoming-event-card', changeDetection: ChangeDetectionStrategy.OnPush, standalone: false, template: "<section class=\"resource-vault-section bg-white text-center py-5 extra-top-padding section-outer\">\n <div class=\"container\">\n <div *ngIf=\"showEventContent\" class=\"d-flex justify-content-between align-items-center flex-wrap\">\n <h2 class=\"section-heading d-flex align-items-center\" [ngClass]=\"{ 'w-50': isEditingTitle }\">\n <ng-container *ngIf=\"!isEditingTitle; else editTitleBlock\">\n <span *ngIf=\"resourceTitle; else fallback\" [innerHTML]=\"resourceTitle\"></span>\n <ng-template #fallback>Events &amp; Webinars</ng-template>\n <i *ngIf=\"canEditResourcesValue\" class=\"fa fa-edit in-page-edit-icon ms-3 cursor-pointer\" (click)=\"toggleEditTitle()\" (keydown.enter)=\"toggleEditTitle()\" (keydown.space)=\"toggleEditTitle()\" title=\"Edit Title\"></i>\n </ng-container>\n\n <ng-template #editTitleBlock>\n <input [(ngModel)]=\"editedTitle\" class=\"form-control d-inline w-auto me-2\" [ngClass]=\"{ 'w-100': isEditingTitle }\" id=\"input_editedTitle_7936\" name=\"input_editedTitle_7936\" />\n <button class=\"btn btn-sm btn-primary me-1\" (click)=\"saveEditedTitle()\">Save</button>\n <button class=\"btn btn-sm btn-secondary\" (click)=\"isEditingTitle = false\">Cancel</button>\n </ng-template>\n </h2>\n <a class=\"view-all\" routerLink=\"/resources/events\">VIEW ALL ></a>\n </div>\n <div *ngIf=\"!showEventContent\" class=\"d-md-flex justify-content-between align-items-start\">\n <h2 class=\"section-heading d-flex align-items-center\" [ngClass]=\"{ 'w-50': isEditingTitle }\">\n <ng-container *ngIf=\"!isEditingTitle; else editTitleBlock\">\n <span *ngIf=\"resourceTitle; else fallback\" [innerHTML]=\"resourceTitle\"></span>\n <ng-template #fallback>Upcoming Events</ng-template>\n <i *ngIf=\"canEditResourcesValue\" class=\"fa fa-edit in-page-edit-icon ms-3 cursor-pointer\" (click)=\"toggleEditTitle()\" (keydown.enter)=\"toggleEditTitle()\" (keydown.space)=\"toggleEditTitle()\" title=\"Edit Title\"></i>\n </ng-container>\n\n <ng-template #editTitleBlock>\n <input [(ngModel)]=\"editedTitle\" class=\"form-control d-inline w-auto me-2\" [ngClass]=\"{ 'w-100': isEditingTitle }\" id=\"input_editedTitle_7936\" name=\"input_editedTitle_7936\" />\n <button class=\"btn btn-sm btn-primary me-1\" (click)=\"saveEditedTitle()\">Save</button>\n <button class=\"btn btn-sm btn-secondary\" (click)=\"isEditingTitle = false\">Cancel</button>\n </ng-template>\n </h2>\n </div>\n\n <div class=\"w-100 text-center mt-3\" *ngIf=\"!isLoaded\">\n <p-progressSpinner strokeWidth=\"2\"> </p-progressSpinner>\n </div>\n <div *ngIf=\"posts.length === 0 && isLoaded\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Resource.NoDataMessage' | transloco\"/>\n </div>\n\n <div class=\"row mt-5 d-flex flex-wrap justify-content-center gap-4 video-row\" *ngIf=\"posts.length !== 0 && isLoaded\">\n <div class=\"resource-blog-card d text-center p-4\" *ngFor=\"let post of posts; trackBy: trackByPostId\">\n <pw-resource-edit-card-lazy\n [canEdit]=\"canEditResourcesValue\"\n [id]=\"post.id\"\n [resourceData]=\"post\"\n (updated)=\"getAllPosts(1, 100)\">\n </pw-resource-edit-card-lazy>\n <ng-container *ngIf=\"postSlice; else conditionalCheck\">\n <h5 class=\"badge-title fw-bold\">UPCOMING:</h5>\n </ng-container>\n\n <ng-template #conditionalCheck>\n <h5 class=\"badge-title fw-bold\">\n {{ isUpcoming(post) ? 'UPCOMING:' : 'REPLAY:' }}\n </h5>\n </ng-template>\n\n <p class=\"event-title mb-4\" [innerHtml]=\"post?.title\"></p>\n <a\n [href]=\"post.external_url || ('/resources/view/' + post?.slug)\"\n target=\"_blank\"\n rel=\"noopener noreferrer\"\n aria-label=\"Navigate to resource\"\n >\n <img\n [src]=\"post.picture.url\"\n class=\"img-fluid my-3 mt-auto\"\n alt=\"Webinar\"\n loading=\"lazy\"\n />\n </a>\n\n <a *ngIf=\"post?.external_url; else internalLink\"\n class=\"resource-btn mt-3\"\n aria-label=\"Navigate to external url\"\n [href]=\"post.external_url\"\n target=\"_blank\"\n rel=\"noopener noreferrer\">\n <span>{{ post?.cta_text && post.cta_text !== 'null' ? post.cta_text : 'Read Now' }}</span>\n <span class=\"arrow\">\u2192</span>\n </a>\n\n <ng-template #internalLink>\n <a class=\"resource-btn mt-3\" aria-label=\"Navigate to resource view\" [href]=\"'/resources/view/' + post?.slug\" target=\"_blank\">\n <span>{{ post?.cta_text && post.cta_text !== 'null' ? post.cta_text : 'Read Now' }}</span>\n <span class=\"arrow\">\u2192</span>\n </a>\n </ng-template>\n </div>\n </div>\n </div>\n</section>\n\n\n<section class=\"bg-white\" *ngIf=\"!showEventContent\">\n <pw-replay-event-card [resourceTitle]=\"resourceTitle\" [user]=\"user\" [userLoggedIn]=\"userLoggedIn\"></pw-replay-event-card>\n</section>", styles: [".bold{font-weight:700}.resource-heading{margin-bottom:2rem}.resource-note{margin-top:1rem;font-size:.85rem;color:#555}.resource-divider{border:0;height:40px;width:100%;background:linear-gradient(to bottom,#0000,#00000026);margin:0}.press-release-icon{height:auto!important;margin:0 11px 1.9rem;display:block;align-self:center;width:auto!important;aspect-ratio:0!important;object-fit:cover;margin-top:auto;margin-right:0!important}.resource-vault-section{padding:60px 0;background:#fff;padding-bottom:9rem!important;padding-top:7rem!important;box-shadow:0 4px 32px -14px #40576d4d!important}.resource-vault-section .vault-heading{font-size:3rem;font-weight:300}.resource-vault-section .explore-link{color:#000;font-weight:400;text-decoration:none;font-size:1.5rem}.resource-vault-section .resource-blog-card{display:flex;flex-direction:column;justify-content:space-between;background-color:#fff;border-radius:30px;box-shadow:0 20px 40px #00000014;padding:25px;text-align:center;width:338px;height:auto!important}.resource-vault-section .resource-blog-card h5{font-size:1.5rem;font-weight:400;margin-bottom:.5rem;color:var(--text-color, black)}.resource-vault-section .resource-blog-card p{font-size:1.5rem;color:var(--text-color, black);line-height:2rem}.resource-vault-section .resource-blog-card img{width:100%;border-radius:10px;aspect-ratio:1/1;object-fit:cover;margin-top:auto;margin-right:0!important;max-width:250px!important;align-self:center!important}.resource-vault-section .resource-blog-card iframe{height:210px;border-radius:10px;object-fit:cover;margin-right:0!important;max-width:280px!important}.resource-vault-section .resource-blog-card .resource-btn{background-color:var(--text-color, black);color:#fff;margin-top:auto;padding:10px 24px;border-radius:24px;font-size:1.5rem;font-weight:500;width:100%;max-width:240px;cursor:pointer;transition:background .3s ease;display:flex;justify-content:space-between;align-self:center;align-items:center;text-align:left;text-decoration:none;border:1px solid;box-shadow:none!important;border-color:var(--text-color, black)}.resource-vault-section .resource-blog-card .resource-btn:hover{background:#fff;color:var(--text-color, black)!important}.resource-vault-section .vault-description{text-align:left;max-width:657px;color:#182527;line-height:2.3rem!important;font-size:1.65rem}@media (width <= 1200px){.resource-vault-section .vault-heading{font-size:3.5rem}.resource-vault-section .vault-description{margin-top:1.35rem}.resource-vault-section .resource-btn{margin-left:0!important}}.video-row{gap:5.5rem!important;margin-top:3rem!important}@media (width >= 991px){section.bg-white.text-center.extra-top-padding{position:relative;overflow:hidden}section.bg-white.text-center.extra-top-padding .banner-header{margin-bottom:4rem!important}}.vault-header{text-align:left}@media (width >= 768px) and (width <= 1200px){.container{padding:0 6rem!important}}@media (width <= 768px){.video-row{gap:3rem!important}}@media (max-width: 768px){.resource-vault-section{padding-bottom:6rem!important}.resource-vault-section .container{padding-top:0rem!important;padding-bottom:0rem!important}.vault-header{text-align:center!important}.vault-heading{font-size:3rem!important}}@media (width <= 1200px){.container{padding:7rem 3rem 1rem!important}}\n"] }]
1229
- }], ctorParameters: () => [{ type: ResourceService }, { type: i2.TagService }, { type: i0.ChangeDetectorRef }, { type: i0.Injector }], propDecorators: { showEventContent: [{
1230
- type: Input
1231
- }], categoryId: [{
1232
- type: Input
1233
- }], tag: [{
1234
- type: Input
1235
- }], postSlice: [{
1236
- type: Input
1237
- }], resourceTitle: [{
1238
- type: Input
1239
- }], user: [{
1240
- type: Input
1241
- }], userLoggedIn: [{
1242
- type: Input
1243
- }] } });
1244
-
1245
- /**
1246
- * Module containing resource card components (lightweight version)
1247
- * ResourceEditCard is lazy-loaded on demand to save 145 KB
1248
- * Trial4ContactUs moved to separate module for better tree-shaking
1249
- * Used by both ResourceRootModule and ResourceSharedModule
1250
- */
1251
- class ResourceCardsModule {
1252
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: ResourceCardsModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
1253
- static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "19.2.20", ngImport: i0, type: ResourceCardsModule, declarations: [ResourceVideoCardComponent,
1254
- UpcomingEventCardComponent,
1255
- ResourceCardComponent,
1256
- CaseStudyCardComponent,
1257
- ResourceNoteCardComponent,
1258
- ResourceVaultComponent,
1259
- ResourceEditCardLazyComponent], imports: [CommonModule,
1260
- RouterModule,
1261
- FormsModule,
1262
- ReactiveFormsModule,
1263
- PipesModule,
1264
- PaginatorModule,
1265
- SelectModule,
1266
- ResourceSharedComponentsModule,
1267
- CoreTranslocoModule,
1268
- TranslocoModule,
1269
- DirectivesModule,
1270
- DragDropModule,
1271
- NgxCaptchaModule,
1272
- Trial4ContactUsModule // ✅ Import standalone module
1273
- ], exports: [ResourceVideoCardComponent,
1274
- UpcomingEventCardComponent,
1275
- ResourceCardComponent,
1276
- CaseStudyCardComponent,
1277
- ResourceNoteCardComponent,
1278
- ResourceVaultComponent,
1279
- Trial4ContactUsModule, // ✅ Re-export for backward compatibility
1280
- ResourceEditCardLazyComponent,
1281
- PaginatorModule // Export PaginatorModule so ResourceCompanyCardComponent can use p-paginator
1282
- ] }); }
1283
- static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: ResourceCardsModule, imports: [CommonModule,
1284
- RouterModule,
1285
- FormsModule,
1286
- ReactiveFormsModule,
1287
- PipesModule,
1288
- PaginatorModule,
1289
- SelectModule,
1290
- ResourceSharedComponentsModule,
1291
- CoreTranslocoModule,
1292
- TranslocoModule,
1293
- DirectivesModule,
1294
- DragDropModule,
1295
- NgxCaptchaModule,
1296
- Trial4ContactUsModule // ✅ Import standalone module
1297
- , Trial4ContactUsModule,
1298
- PaginatorModule // Export PaginatorModule so ResourceCompanyCardComponent can use p-paginator
1299
- ] }); }
1300
- }
1301
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: ResourceCardsModule, decorators: [{
1302
- type: NgModule,
1303
- args: [{
1304
- declarations: [
1305
- ResourceVideoCardComponent,
1306
- UpcomingEventCardComponent,
1307
- ResourceCardComponent,
1308
- CaseStudyCardComponent,
1309
- ResourceNoteCardComponent,
1310
- ResourceVaultComponent,
1311
- ResourceEditCardLazyComponent
1312
- ],
1313
- imports: [
1314
- CommonModule,
1315
- RouterModule,
1316
- FormsModule,
1317
- ReactiveFormsModule,
1318
- PipesModule,
1319
- PaginatorModule,
1320
- SelectModule,
1321
- ResourceSharedComponentsModule,
1322
- CoreTranslocoModule,
1323
- TranslocoModule,
1324
- DirectivesModule,
1325
- DragDropModule,
1326
- NgxCaptchaModule,
1327
- Trial4ContactUsModule // ✅ Import standalone module
1328
- ],
1329
- exports: [
1330
- ResourceVideoCardComponent,
1331
- UpcomingEventCardComponent,
1332
- ResourceCardComponent,
1333
- CaseStudyCardComponent,
1334
- ResourceNoteCardComponent,
1335
- ResourceVaultComponent,
1336
- Trial4ContactUsModule, // ✅ Re-export for backward compatibility
1337
- ResourceEditCardLazyComponent,
1338
- PaginatorModule // Export PaginatorModule so ResourceCompanyCardComponent can use p-paginator
1339
- ],
1340
- schemas: [CUSTOM_ELEMENTS_SCHEMA]
1341
- }]
1342
- }] });
1343
-
1344
- // Shared components used across multiple resource routes
1345
- // Note: Most heavy modules (Quill, Calendar, UiSwitch, etc.) are now in ResourceCardsModule
1346
- class ResourceSharedModule {
1347
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: ResourceSharedModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
1348
- static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "19.2.20", ngImport: i0, type: ResourceSharedModule, declarations: [ResourceCompanyCardComponent, ResourceTopBannerEditComponent], imports: [CommonModule,
1349
- RouterModule,
1350
- FormsModule,
1351
- ReactiveFormsModule,
1352
- PipesModule,
1353
- ResourceSharedComponentsModule,
1354
- CoreTranslocoModule,
1355
- TranslocoModule,
1356
- DirectivesModule,
1357
- InputTextModule,
1358
- InputTextarea,
1359
- ResourceCardsModule,
1360
- HubSpotMeetingsSharedModule // For pw-book-a-demo component (HubSpotMeetingsComponent)
1361
- ], exports: [
1362
- // Export the 2 components specific to this module
1363
- ResourceCompanyCardComponent,
1364
- ResourceTopBannerEditComponent,
1365
- // Export card components module (includes all heavy modules + card components)
1366
- ResourceCardsModule,
1367
- // Export HubSpotMeetingsSharedModule to make pw-book-a-demo component available
1368
- HubSpotMeetingsSharedModule,
1369
- // Export common lightweight modules
1370
- CommonModule,
1371
- RouterModule,
1372
- FormsModule,
1373
- ReactiveFormsModule,
1374
- PipesModule,
1375
- ResourceSharedComponentsModule,
1376
- CoreTranslocoModule,
1377
- TranslocoModule,
1378
- DirectivesModule,
1379
- InputTextModule,
1380
- InputTextarea] }); }
1381
- static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: ResourceSharedModule, imports: [CommonModule,
1382
- RouterModule,
1383
- FormsModule,
1384
- ReactiveFormsModule,
1385
- PipesModule,
1386
- ResourceSharedComponentsModule,
1387
- CoreTranslocoModule,
1388
- TranslocoModule,
1389
- DirectivesModule,
1390
- InputTextModule,
1391
- ResourceCardsModule,
1392
- HubSpotMeetingsSharedModule // For pw-book-a-demo component (HubSpotMeetingsComponent)
1393
- ,
1394
- // Export card components module (includes all heavy modules + card components)
1395
- ResourceCardsModule,
1396
- // Export HubSpotMeetingsSharedModule to make pw-book-a-demo component available
1397
- HubSpotMeetingsSharedModule,
1398
- // Export common lightweight modules
1399
- CommonModule,
1400
- RouterModule,
1401
- FormsModule,
1402
- ReactiveFormsModule,
1403
- PipesModule,
1404
- ResourceSharedComponentsModule,
1405
- CoreTranslocoModule,
1406
- TranslocoModule,
1407
- DirectivesModule,
1408
- InputTextModule] }); }
1409
- }
1410
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: ResourceSharedModule, decorators: [{
1411
- type: NgModule,
1412
- args: [{
1413
- declarations: [ResourceCompanyCardComponent, ResourceTopBannerEditComponent],
1414
- imports: [
1415
- CommonModule,
1416
- RouterModule,
1417
- FormsModule,
1418
- ReactiveFormsModule,
1419
- PipesModule,
1420
- ResourceSharedComponentsModule,
1421
- CoreTranslocoModule,
1422
- TranslocoModule,
1423
- DirectivesModule,
1424
- InputTextModule,
1425
- InputTextarea,
1426
- ResourceCardsModule,
1427
- HubSpotMeetingsSharedModule // For pw-book-a-demo component (HubSpotMeetingsComponent)
1428
- ],
1429
- exports: [
1430
- // Export the 2 components specific to this module
1431
- ResourceCompanyCardComponent,
1432
- ResourceTopBannerEditComponent,
1433
- // Export card components module (includes all heavy modules + card components)
1434
- ResourceCardsModule,
1435
- // Export HubSpotMeetingsSharedModule to make pw-book-a-demo component available
1436
- HubSpotMeetingsSharedModule,
1437
- // Export common lightweight modules
1438
- CommonModule,
1439
- RouterModule,
1440
- FormsModule,
1441
- ReactiveFormsModule,
1442
- PipesModule,
1443
- ResourceSharedComponentsModule,
1444
- CoreTranslocoModule,
1445
- TranslocoModule,
1446
- DirectivesModule,
1447
- InputTextModule,
1448
- InputTextarea
1449
- ],
1450
- schemas: [CUSTOM_ELEMENTS_SCHEMA]
1451
- }]
1452
- }] });
1453
-
1454
- class ResourceEditCardComponent extends AppBaseComponent {
1455
- constructor(fb, modalService, resourceService, authService, tagService, injector) {
1456
- super(injector);
1457
- this.fb = fb;
1458
- this.modalService = modalService;
1459
- this.resourceService = resourceService;
1460
- this.authService = authService;
1461
- this.tagService = tagService;
1462
- this.updated = new EventEmitter();
1463
- this.image = '';
1464
- this.rectangularImage = '';
1465
- this.file = null;
1466
- this.rectangularFile = null;
1467
- this.selectedTags = [];
1468
- this.allTags = [];
1469
- this.tagsSuggestion = [];
1470
- this.buttonBusy = false;
1471
- this.editForm = this.fb.group({
1472
- title: [''],
1473
- external_url: [''],
1474
- cta_text: [''],
1475
- when: [''],
1476
- showcase: [false],
1477
- published_at: [false],
1478
- accepted_at: [false],
1479
- body: ['']
1480
- });
1481
- }
1482
- ngOnInit() {
1483
- this.authService.getToken$().subscribe(res => {
1484
- this.userLoggedIn = !!res;
1485
- if (this.userLoggedIn) {
1486
- this.localStorage.getItem$('product').subscribe(res => {
1487
- const data = res ? JSON.parse(res) : null;
1488
- this.subscriptionId = data?.subscriptionId;
1489
- });
1490
- }
1491
- });
1492
- }
1493
- navigateToResourceEdit() {
1494
- const basePath = `/admin/resources/${this.resourceData?.slug}`;
1495
- const fullUrl = `${location.origin}${basePath}`;
1496
- window.open(fullUrl, '_blank');
1497
- }
1498
- openModal(modalTemplate) {
1499
- if (this.resourceData) {
1500
- const when = this.resourceData.when ? new Date(this.resourceData.when) : null;
1501
- this.editForm.setValue({
1502
- title: this.resourceData.title ?? '',
1503
- external_url: this.resourceData.external_url ?? '',
1504
- cta_text: this.resourceData.cta_text ?? '',
1505
- when: when ?? '',
1506
- showcase: !!this.resourceData.showcase,
1507
- published_at: !!this.resourceData.published_at,
1508
- accepted_at: !!this.resourceData.accepted_at,
1509
- body: this.resourceData.body
1510
- });
1511
- this.image = this.resourceData.picture?.url ?? '';
1512
- this.selectedTags = this.resourceData?.tags?.length ? [...this.resourceData.tags] : [];
1513
- this.rectangularImage = this.resourceData.rectangular_picture?.url ?? '';
1514
- }
1515
- this.modalService.open(modalTemplate, { centered: true, size: 'lg' });
1516
- this.getPostTags();
1517
- }
1518
- search(event) {
1519
- let values = [];
1520
- if (event.query) {
1521
- values = this.allTags.filter(x => x.name.toLowerCase().includes(event.query.toLowerCase()));
1522
- }
1523
- else {
1524
- this.allTags.forEach(element => {
1525
- values.push(element);
1526
- });
1527
- }
1528
- this.tagsSuggestion = values;
1529
- }
1530
- getPostTags() {
1531
- this.tagService
1532
- .getTagsByType('post_categories', {}, this.subscriptionId)
1533
- .subscribe(response => {
1534
- this.allTags = response.tags;
1535
- });
1536
- }
1537
- deleteRectangularImage() {
1538
- this.rectangularImage = null;
1539
- this.rectangularFile = null;
1540
- }
1541
- openImageModal(modalTemplate) {
1542
- this.imageModalRef = this.modalService.open(modalTemplate, { centered: true, size: 'md' });
1543
- }
1544
- onImageSelected(base64) {
1545
- this.image = base64;
1546
- this.file = HelperService.convertBase64ToFile(base64);
1547
- this.imageModalRef?.close();
1548
- }
1549
- onRectangularImageSelection(base64) {
1550
- this.rectangularImage = base64;
1551
- this.rectangularFile = HelperService.convertBase64ToFile(base64);
1552
- this.imageModalRef?.close();
1553
- }
1554
- removeImage() {
1555
- this.image = null;
1556
- this.file = null;
1557
- }
1558
- saveResource() {
1559
- this.buttonBusy = true;
1560
- this.saveTags(this.id);
1561
- const payload = {
1562
- ...this.editForm.value,
1563
- subscription_id: this.subscriptionId
1564
- };
1565
- this.handlePicture(payload);
1566
- this.handlePublishedAt(payload);
1567
- this.handleAcceptedAt(payload);
1568
- this.handleAcceptedAt(payload);
1569
- this.handleOptionalFields(payload);
1570
- this.handleRectangularPicture(payload);
1571
- this.handleRemovals(payload);
1572
- this.resourceService.updatePost(payload, this.id).subscribe(() => {
1573
- this.buttonBusy = false;
1574
- this.toast.success('Blog Post Updated');
1575
- this.updated.emit();
1576
- this.modalService.dismissAll();
1577
- });
1578
- }
1579
- saveTags(id) {
1580
- if (this.selectedTags.length) {
1581
- const data = {
1582
- entity_tags: this.selectedTags.map(tag => ({ tag_id: tag.id })),
1583
- slug: id,
1584
- tag_entity: 'Post' // or use TAG_ENTITY.POST if you imported it
1585
- };
1586
- this.tagService.addTags(data, this.subscriptionId).subscribe();
1587
- }
1588
- }
1589
- handlePicture(data) {
1590
- if (this.file) {
1591
- data.picture = this.file;
1592
- }
1593
- else {
1594
- delete data.picture;
1595
- }
1596
- }
1597
- handlePublishedAt(data) {
1598
- const control = this.editForm.get('published_at');
1599
- if (control?.dirty) {
1600
- data.published_at = control.value ? moment().format('DD-MMM-YYYY') : '';
1601
- }
1602
- else {
1603
- delete data.published_at;
1604
- }
1605
- }
1606
- handleAcceptedAt(data) {
1607
- const control = this.editForm.get('accepted_at');
1608
- if (control?.dirty) {
1609
- data.accepted_at = control.value ? moment().format('DD-MMM-YYYY') : '';
1610
- }
1611
- else {
1612
- delete data.accepted_at;
1613
- }
1614
- }
1615
- handleOptionalFields(data) {
1616
- if (!this.editForm.get('when')?.value) {
1617
- data.when = '';
1618
- }
1619
- if (!this.editForm.get('showcase')?.value) {
1620
- data.showcase = '';
1621
- }
1622
- }
1623
- handleRectangularPicture(data) {
1624
- if (this.rectangularFile) {
1625
- data.rectangular_picture = this.rectangularFile;
1626
- }
1627
- else {
1628
- delete data.rectangular_picture;
1629
- }
1630
- }
1631
- handleRemovals(data) {
1632
- if (!this.file && !this.image) {
1633
- data.remove_picture = true;
1634
- }
1635
- if (!this.rectangularFile && !this.rectangularImage) {
1636
- data.remove_rectangular_picture = true;
1637
- }
1638
- }
1639
- openRectModal(content) {
1640
- this.imageModalRef = this.modalService.open(content, {
1641
- centered: true,
1642
- windowClass: 'modal-holder'
1643
- });
1644
- }
1645
- handleImageError(event, fallbackPath) {
1646
- HelperService.handleImageFallbackPath(event, fallbackPath);
1647
- }
1648
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: ResourceEditCardComponent, deps: [{ token: i1$1.FormBuilder }, { token: i2$1.NgbModal }, { token: ResourceService }, { token: i2.AuthService }, { token: i2.TagService }, { token: i0.Injector }], target: i0.ɵɵFactoryTarget.Component }); }
1649
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.20", type: ResourceEditCardComponent, isStandalone: false, selector: "pw-resource-edit-card", inputs: { id: "id", resourceData: "resourceData" }, outputs: { updated: "updated" }, usesInheritance: true, ngImport: i0, template: "<div class=\"edit-card\">\n <i class=\"fa fa-edit cursor-pointer text-dark in-page-edit-icon d-flex justify-content-center mb-2\"\n (click)=\"openModal(editResourceModal)\"\n (keydown.enter)=\"openModal(editResourceModal)\"\n (keydown.space)=\"openModal(editResourceModal)\"\n title=\"Edit Resource\"></i>\n</div>\n\n<ng-template #editResourceModal let-modal>\n <div class=\"modal-header\">\n <h5 class=\"modal-title\">Edit Resource</h5>\n <i class=\"fa fa-edit cursor-pointer text-dark in-page-edit-icon d-flex justify-content-center ms-3\"\n (click)=\"navigateToResourceEdit()\"\n (keydown.enter)=\"navigateToResourceEdit()\"\n (keydown.space)=\"navigateToResourceEdit()\"\n title=\"Go to the main edit page\"></i>\n <button type=\"button\" class=\"btn-close\" aria-label=\"Close\" (click)=\"modal.dismiss()\"></button>\n </div>\n\n <div class=\"modal-body\">\n <form [formGroup]=\"editForm\">\n <div class=\"row\">\n\n\n <div class=\"col-12\">\n <pw-input-container label=\"Title\" name=\"title\">\n <input type=\"text\" class=\"form-control\" formControlName=\"title\" id=\"input_title_1\" name=\"input_title_1\"/>\n </pw-input-container>\n </div>\n\n <div class=\"col-12 row\">\n <pw-input-container label=\"CTA Text\" name=\"cta_text\" class=\"col-md-6\"\n [showTooltip]=\"true\"\n [tooltipText]=\"'Resource.Posts.Tooltip.CtaText' | transloco\">\n <input type=\"text\" class=\"form-control\" formControlName=\"cta_text\" id=\"input_cta_text_2\" name=\"input_cta_text_2\"/>\n </pw-input-container>\n\n <pw-input-container label=\"External URL\" name=\"external_url\" class=\"col-md-6\"\n [showTooltip]=\"true\"\n [tooltipText]=\"'Resource.Posts.Tooltip.ExternalUrl' | transloco\">\n <input type=\"text\" class=\"form-control\" formControlName=\"external_url\" id=\"input_external_url_3\" name=\"input_external_url_3\"/>\n </pw-input-container>\n </div>\n\n <div class=\"col-12\">\n <pw-input-container\n [label]=\"'Resource.Posts.Body' | transloco\"\n name=\"body\"\n [errorMsg]=\"'Resource.Posts.Validation.Body' | transloco\">\n <quill-editor\n [styles]=\"{ height: '300px' }\"\n class=\"quillEditor\"\n [modules]=\"editorConfig\"\n formControlName=\"body\"\n [ngClass]=\"{\n 'w-100': true,\n 'quill-container': true,\n 'is-invalid': submitted && f['body'].errors\n }\">\n </quill-editor>\n </pw-input-container>\n </div>\n\n <div class=\"col-12 col-md-3 col-sm-6\">\n <pw-input-container\n [label]=\"'Resource.Posts.When' | transloco\"\n [showTooltip]=\"true\"\n [tooltipText]=\"'Resource.Posts.Tooltip.When' | transloco\"\n name=\"when\">\n <p-calendar inputId=\"resource-edit-card-when\" formControlName=\"when\"\n [showIcon]=\"true\"\n dateFormat=\"dd-M-yy\"\n [placeholder]=\"'Select Date'\"\n [ngClass]=\"{ 'is-invalid': submitted && f['when'].errors }\">\n </p-calendar>\n </pw-input-container>\n </div>\n\n <div class=\"col-12 col-md-8\">\n <pw-input-container\n [label]=\"'Resource.Posts.Tags' | transloco\"\n class=\"ui-fluid skills-modal tags\"\n [showTooltip]=\"true\"\n [tooltipText]=\"'Resource.Posts.Tooltip.CtaText' | transloco\"\n name=\"cta_text\">\n <p-autoComplete [(ngModel)]=\"selectedTags\"\n class=\"body-bg\"\n [suggestions]=\"tagsSuggestion\"\n dataKey=\"id\"\n field=\"name\"\n (completeMethod)=\"search($event)\"\n styleClass=\"w-100\"\n [minLength]=\"1\"\n [maxlength]=\"10\"\n [dropdown]=\"true\"\n [ngModelOptions]=\"{ standalone: true }\"\n placeholder=\"Tags\"\n [multiple]=\"true\">\n </p-autoComplete>\n </pw-input-container>\n </div>\n\n <div class=\"col-12 row\">\n <div class=\"col-md-4 col-sm-6\">\n <pw-input-container\n [label]=\"'SHOWCASE'\"\n [showTooltip]=\"true\"\n [tooltipText]=\"'Mark as showcase post'\"\n name=\"showcase\">\n <ui-switch formControlName=\"showcase\" class=\"d-block\"></ui-switch>\n </pw-input-container>\n </div>\n\n <div class=\"col-md-4 col-sm-6\">\n <pw-input-container\n [label]=\"'PUBLISHED'\"\n [showTooltip]=\"true\"\n [tooltipText]=\"'Set to publish the post'\"\n name=\"published_at\">\n <ui-switch formControlName=\"published_at\" class=\"d-block\"></ui-switch>\n </pw-input-container>\n </div>\n\n <div class=\"col-md-4 col-sm-6\">\n <pw-input-container\n [label]=\"'ACCEPTED BY ADMIN'\"\n [showTooltip]=\"true\"\n [tooltipText]=\"'Indicates approval by admin'\"\n name=\"accepted_at\">\n <ui-switch formControlName=\"accepted_at\" class=\"d-block\"></ui-switch>\n </pw-input-container>\n </div>\n </div>\n\n <div class=\"col-12 col-md-4 col-sm-4 my-4 ms-3\">\n <div class=\"text-center mb-4\">\n <span id=\"resource-edit-cover-picture-label\" class=\"pw-label-style\">{{ 'Resource.Posts.CoverPicture' | transloco }}</span>\n <div class=\"text-center d-flex flex-column align-items-center\">\n <img [src]=\"(image && !image.includes('default-photo.jpg')) ? image : 'assets/img/resource/blog.png'\"\n (click)=\"openImageModal(imageCropContent)\"\n (keydown.enter)=\"openImageModal(imageCropContent)\"\n class=\"image w-100\"\n alt=\"Modal\"\n (error)=\"handleImageError($event, 'assets/img/resource/blog.png')\" />\n <div class=\"d-flex justify-content-between align-items-center mt-2\">\n <a class=\"d-inline-block\" (click)=\"openImageModal(imageCropContent)\">\n {{ slug !== 'create' ? 'Edit' : 'Add' }} Picture\n </a>\n <i *ngIf=\"image && !image.includes('default-photo.jpg')\"\n class=\"fa fa-trash delete-icon text-danger ms-2 cursor-pointer\"\n title=\"Remove Image\"\n (click)=\"removeImage()\"\n (keydown.enter)=\"removeImage()\"></i>\n </div>\n </div>\n </div>\n </div>\n\n <div class=\"col-12 col-md-4 col-sm-4 my-4 ms-3\">\n <div class=\"text-center mb-4\">\n <span id=\"resource-edit-rectangular-picture-label\" class=\"pw-label-style\">Rectangular Picture</span>\n <div class=\"text-center d-flex flex-column align-items-center\">\n <img [src]=\"(rectangularImage && !rectangularImage.includes('default-photo.jpg')) ? rectangularImage : 'assets/img/resource/blog.png'\"\n (click)=\"openRectModal(rectContent)\"\n (keydown.enter)=\"openRectModal(rectContent)\"\n class=\"image w-100\"\n alt=\"Uploaded rectangular media preview\"\n (error)=\"handleImageError($event, 'assets/img/resource/blog.png')\" />\n <div class=\"d-flex justify-content-between align-items-center mt-2\">\n <a class=\"d-inline-block\" (click)=\"openRectModal(rectContent)\">\n {{ slug !== 'create' ? 'Edit' : 'Add' }} Picture\n </a>\n <i *ngIf=\"rectangularImage && !rectangularImage.includes('default-photo.jpg')\"\n class=\"fa fa-trash delete-icon text-danger ms-2 cursor-pointer\"\n title=\"Remove Image\"\n (click)=\"deleteRectangularImage()\"\n (keydown.enter)=\"deleteRectangularImage()\"></i>\n </div>\n </div>\n </div>\n </div>\n\n </div>\n </form>\n </div>\n\n <div class=\"modal-footer\">\n <button class=\"btn btn-secondary\" (click)=\"modal.dismiss()\">Cancel</button>\n <button class=\"btn btn-primary\" [buttonBusy]=\"buttonBusy\" (click)=\"saveResource()\">Save</button>\n </div>\n</ng-template>\n\n<ng-template #imageCropContent let-modal>\n <div class=\"modal-header\">\n <h5 class=\"modal-title\">Upload Picture</h5>\n <button type=\"button\" class=\"btn-close\" (click)=\"modal.dismiss()\"></button>\n </div>\n <div class=\"modal-body\">\n <small>You can upload a JPG, GIF, or PNG file. (Do not upload pictures containing celebrities,\n nudity, artwork or copyrighted images.)</small>\n <pw-image-cropper\n [aspectRatio]=\"'dynamic'\"\n (imageSelectionEvent)=\"onImageSelected($event)\"\n (closeEvent)=\"modal.close()\">\n </pw-image-cropper>\n </div>\n</ng-template>\n\n<ng-template #rectContent let-modal>\n <div class=\"modal-header\">\n <h5 class=\"modal-title\">Upload Picture</h5>\n <button type=\"button\" class=\"btn-close float-end\" aria-label=\"Close\" (click)=\"modal.dismiss()\"></button>\n </div>\n <div class=\"modal-body\">\n <small>You can upload a JPG, GIF, or PNG file. (Do not upload pictures containing celebrities,\n nudity, artwork or copyrighted images.)</small>\n <pw-image-cropper\n #profile\n [aspectRatio]=\"'dynamic'\"\n (imageSelectionEvent)=\"onRectangularImageSelection($event)\"\n (closeEvent)=\"onClose()\">\n </pw-image-cropper>\n </div>\n</ng-template>\n", styles: ["::ng-deep .modal-content{margin-top:5rem!important}\n"], dependencies: [{ kind: "directive", type: i3.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i3.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1$1.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i1$1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1$1.MaxLengthValidator, selector: "[maxlength][formControlName],[maxlength][formControl],[maxlength][ngModel]", inputs: ["maxlength"] }, { kind: "directive", type: i1$1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i1$1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i1$1.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "component", type: i6$2.Calendar, selector: "p-calendar", inputs: ["iconDisplay", "style", "styleClass", "inputStyle", "inputId", "name", "inputStyleClass", "placeholder", "ariaLabelledBy", "ariaLabel", "iconAriaLabel", "disabled", "dateFormat", "multipleSeparator", "rangeSeparator", "inline", "showOtherMonths", "selectOtherMonths", "showIcon", "fluid", "icon", "appendTo", "readonlyInput", "shortYearCutoff", "monthNavigator", "yearNavigator", "hourFormat", "timeOnly", "stepHour", "stepMinute", "stepSecond", "showSeconds", "required", "showOnFocus", "showWeek", "startWeekFromFirstDayOfYear", "showClear", "dataType", "selectionMode", "maxDateCount", "showButtonBar", "todayButtonStyleClass", "clearButtonStyleClass", "autofocus", "autoZIndex", "baseZIndex", "panelStyleClass", "panelStyle", "keepInvalid", "hideOnDateTimeSelect", "touchUI", "timeSeparator", "focusTrap", "showTransitionOptions", "hideTransitionOptions", "tabindex", "variant", "minDate", "maxDate", "disabledDates", "disabledDays", "yearRange", "showTime", "responsiveOptions", "numberOfMonths", "firstDayOfWeek", "locale", "view", "defaultDate"], outputs: ["onFocus", "onBlur", "onClose", "onSelect", "onClear", "onInput", "onTodayClick", "onClearClick", "onMonthChange", "onYearChange", "onClickOutside", "onShow"] }, { kind: "component", type: i7$1.AutoComplete, selector: "p-autoComplete, p-autocomplete, p-auto-complete", inputs: ["minLength", "delay", "style", "panelStyle", "styleClass", "panelStyleClass", "inputStyle", "inputId", "inputStyleClass", "placeholder", "readonly", "disabled", "scrollHeight", "lazy", "virtualScroll", "virtualScrollItemSize", "virtualScrollOptions", "maxlength", "name", "required", "size", "appendTo", "autoHighlight", "forceSelection", "type", "autoZIndex", "baseZIndex", "ariaLabel", "dropdownAriaLabel", "ariaLabelledBy", "dropdownIcon", "unique", "group", "completeOnFocus", "showClear", "field", "dropdown", "showEmptyMessage", "dropdownMode", "multiple", "tabindex", "dataKey", "emptyMessage", "showTransitionOptions", "hideTransitionOptions", "autofocus", "autocomplete", "optionGroupChildren", "optionGroupLabel", "overlayOptions", "suggestions", "itemSize", "optionLabel", "optionValue", "id", "searchMessage", "emptySelectionMessage", "selectionMessage", "autoOptionFocus", "selectOnFocus", "searchLocale", "optionDisabled", "focusOnHover", "typeahead", "variant", "fluid"], outputs: ["completeMethod", "onSelect", "onUnselect", "onFocus", "onBlur", "onDropdownClick", "onClear", "onKeyUp", "onShow", "onHide", "onLazyLoad"] }, { kind: "component", type: i6$1.ProfileImageCropperComponent, selector: "pw-image-cropper", inputs: ["aspectRatio", "dynamicData"], outputs: ["imageSelectionEvent", "closeEvent", "fileChangeEvent"] }, { kind: "component", type: i6.InputContainerComponent, selector: "pw-input-container", inputs: ["name", "controlId", "useAriaLabelledbyOnly", "label", "labelClass", "tooltipPosition", "required", "errorMsg", "isReadOnly", "showTooltip", "tooltipText", "showTriangle", "afterLabel", "showAfterLabel", "showTriangleText", "isLeftTooltip"] }, { kind: "directive", type: i8.ButtonBusyDirective, selector: "[buttonBusy]", inputs: ["buttonBusy", "busyText"] }, { kind: "directive", type: i8.LazyImgDirective, selector: "img" }, { kind: "component", type: i11.QuillEditorComponent, selector: "quill-editor" }, { kind: "component", type: i12.UiSwitchComponent, selector: "ui-switch", inputs: ["size", "color", "switchOffColor", "switchColor", "defaultBgColor", "defaultBoColor", "checkedLabel", "uncheckedLabel", "checkedTextColor", "uncheckedTextColor", "beforeChange", "ariaLabel", "checked", "disabled", "reverse", "loading"], outputs: ["change", "changeEvent", "valueChange"] }, { kind: "pipe", type: i10.TranslocoPipe, name: "transloco" }] }); }
1650
- }
1651
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: ResourceEditCardComponent, decorators: [{
1652
- type: Component,
1653
- args: [{ selector: 'pw-resource-edit-card', standalone: false, template: "<div class=\"edit-card\">\n <i class=\"fa fa-edit cursor-pointer text-dark in-page-edit-icon d-flex justify-content-center mb-2\"\n (click)=\"openModal(editResourceModal)\"\n (keydown.enter)=\"openModal(editResourceModal)\"\n (keydown.space)=\"openModal(editResourceModal)\"\n title=\"Edit Resource\"></i>\n</div>\n\n<ng-template #editResourceModal let-modal>\n <div class=\"modal-header\">\n <h5 class=\"modal-title\">Edit Resource</h5>\n <i class=\"fa fa-edit cursor-pointer text-dark in-page-edit-icon d-flex justify-content-center ms-3\"\n (click)=\"navigateToResourceEdit()\"\n (keydown.enter)=\"navigateToResourceEdit()\"\n (keydown.space)=\"navigateToResourceEdit()\"\n title=\"Go to the main edit page\"></i>\n <button type=\"button\" class=\"btn-close\" aria-label=\"Close\" (click)=\"modal.dismiss()\"></button>\n </div>\n\n <div class=\"modal-body\">\n <form [formGroup]=\"editForm\">\n <div class=\"row\">\n\n\n <div class=\"col-12\">\n <pw-input-container label=\"Title\" name=\"title\">\n <input type=\"text\" class=\"form-control\" formControlName=\"title\" id=\"input_title_1\" name=\"input_title_1\"/>\n </pw-input-container>\n </div>\n\n <div class=\"col-12 row\">\n <pw-input-container label=\"CTA Text\" name=\"cta_text\" class=\"col-md-6\"\n [showTooltip]=\"true\"\n [tooltipText]=\"'Resource.Posts.Tooltip.CtaText' | transloco\">\n <input type=\"text\" class=\"form-control\" formControlName=\"cta_text\" id=\"input_cta_text_2\" name=\"input_cta_text_2\"/>\n </pw-input-container>\n\n <pw-input-container label=\"External URL\" name=\"external_url\" class=\"col-md-6\"\n [showTooltip]=\"true\"\n [tooltipText]=\"'Resource.Posts.Tooltip.ExternalUrl' | transloco\">\n <input type=\"text\" class=\"form-control\" formControlName=\"external_url\" id=\"input_external_url_3\" name=\"input_external_url_3\"/>\n </pw-input-container>\n </div>\n\n <div class=\"col-12\">\n <pw-input-container\n [label]=\"'Resource.Posts.Body' | transloco\"\n name=\"body\"\n [errorMsg]=\"'Resource.Posts.Validation.Body' | transloco\">\n <quill-editor\n [styles]=\"{ height: '300px' }\"\n class=\"quillEditor\"\n [modules]=\"editorConfig\"\n formControlName=\"body\"\n [ngClass]=\"{\n 'w-100': true,\n 'quill-container': true,\n 'is-invalid': submitted && f['body'].errors\n }\">\n </quill-editor>\n </pw-input-container>\n </div>\n\n <div class=\"col-12 col-md-3 col-sm-6\">\n <pw-input-container\n [label]=\"'Resource.Posts.When' | transloco\"\n [showTooltip]=\"true\"\n [tooltipText]=\"'Resource.Posts.Tooltip.When' | transloco\"\n name=\"when\">\n <p-calendar inputId=\"resource-edit-card-when\" formControlName=\"when\"\n [showIcon]=\"true\"\n dateFormat=\"dd-M-yy\"\n [placeholder]=\"'Select Date'\"\n [ngClass]=\"{ 'is-invalid': submitted && f['when'].errors }\">\n </p-calendar>\n </pw-input-container>\n </div>\n\n <div class=\"col-12 col-md-8\">\n <pw-input-container\n [label]=\"'Resource.Posts.Tags' | transloco\"\n class=\"ui-fluid skills-modal tags\"\n [showTooltip]=\"true\"\n [tooltipText]=\"'Resource.Posts.Tooltip.CtaText' | transloco\"\n name=\"cta_text\">\n <p-autoComplete [(ngModel)]=\"selectedTags\"\n class=\"body-bg\"\n [suggestions]=\"tagsSuggestion\"\n dataKey=\"id\"\n field=\"name\"\n (completeMethod)=\"search($event)\"\n styleClass=\"w-100\"\n [minLength]=\"1\"\n [maxlength]=\"10\"\n [dropdown]=\"true\"\n [ngModelOptions]=\"{ standalone: true }\"\n placeholder=\"Tags\"\n [multiple]=\"true\">\n </p-autoComplete>\n </pw-input-container>\n </div>\n\n <div class=\"col-12 row\">\n <div class=\"col-md-4 col-sm-6\">\n <pw-input-container\n [label]=\"'SHOWCASE'\"\n [showTooltip]=\"true\"\n [tooltipText]=\"'Mark as showcase post'\"\n name=\"showcase\">\n <ui-switch formControlName=\"showcase\" class=\"d-block\"></ui-switch>\n </pw-input-container>\n </div>\n\n <div class=\"col-md-4 col-sm-6\">\n <pw-input-container\n [label]=\"'PUBLISHED'\"\n [showTooltip]=\"true\"\n [tooltipText]=\"'Set to publish the post'\"\n name=\"published_at\">\n <ui-switch formControlName=\"published_at\" class=\"d-block\"></ui-switch>\n </pw-input-container>\n </div>\n\n <div class=\"col-md-4 col-sm-6\">\n <pw-input-container\n [label]=\"'ACCEPTED BY ADMIN'\"\n [showTooltip]=\"true\"\n [tooltipText]=\"'Indicates approval by admin'\"\n name=\"accepted_at\">\n <ui-switch formControlName=\"accepted_at\" class=\"d-block\"></ui-switch>\n </pw-input-container>\n </div>\n </div>\n\n <div class=\"col-12 col-md-4 col-sm-4 my-4 ms-3\">\n <div class=\"text-center mb-4\">\n <span id=\"resource-edit-cover-picture-label\" class=\"pw-label-style\">{{ 'Resource.Posts.CoverPicture' | transloco }}</span>\n <div class=\"text-center d-flex flex-column align-items-center\">\n <img [src]=\"(image && !image.includes('default-photo.jpg')) ? image : 'assets/img/resource/blog.png'\"\n (click)=\"openImageModal(imageCropContent)\"\n (keydown.enter)=\"openImageModal(imageCropContent)\"\n class=\"image w-100\"\n alt=\"Modal\"\n (error)=\"handleImageError($event, 'assets/img/resource/blog.png')\" />\n <div class=\"d-flex justify-content-between align-items-center mt-2\">\n <a class=\"d-inline-block\" (click)=\"openImageModal(imageCropContent)\">\n {{ slug !== 'create' ? 'Edit' : 'Add' }} Picture\n </a>\n <i *ngIf=\"image && !image.includes('default-photo.jpg')\"\n class=\"fa fa-trash delete-icon text-danger ms-2 cursor-pointer\"\n title=\"Remove Image\"\n (click)=\"removeImage()\"\n (keydown.enter)=\"removeImage()\"></i>\n </div>\n </div>\n </div>\n </div>\n\n <div class=\"col-12 col-md-4 col-sm-4 my-4 ms-3\">\n <div class=\"text-center mb-4\">\n <span id=\"resource-edit-rectangular-picture-label\" class=\"pw-label-style\">Rectangular Picture</span>\n <div class=\"text-center d-flex flex-column align-items-center\">\n <img [src]=\"(rectangularImage && !rectangularImage.includes('default-photo.jpg')) ? rectangularImage : 'assets/img/resource/blog.png'\"\n (click)=\"openRectModal(rectContent)\"\n (keydown.enter)=\"openRectModal(rectContent)\"\n class=\"image w-100\"\n alt=\"Uploaded rectangular media preview\"\n (error)=\"handleImageError($event, 'assets/img/resource/blog.png')\" />\n <div class=\"d-flex justify-content-between align-items-center mt-2\">\n <a class=\"d-inline-block\" (click)=\"openRectModal(rectContent)\">\n {{ slug !== 'create' ? 'Edit' : 'Add' }} Picture\n </a>\n <i *ngIf=\"rectangularImage && !rectangularImage.includes('default-photo.jpg')\"\n class=\"fa fa-trash delete-icon text-danger ms-2 cursor-pointer\"\n title=\"Remove Image\"\n (click)=\"deleteRectangularImage()\"\n (keydown.enter)=\"deleteRectangularImage()\"></i>\n </div>\n </div>\n </div>\n </div>\n\n </div>\n </form>\n </div>\n\n <div class=\"modal-footer\">\n <button class=\"btn btn-secondary\" (click)=\"modal.dismiss()\">Cancel</button>\n <button class=\"btn btn-primary\" [buttonBusy]=\"buttonBusy\" (click)=\"saveResource()\">Save</button>\n </div>\n</ng-template>\n\n<ng-template #imageCropContent let-modal>\n <div class=\"modal-header\">\n <h5 class=\"modal-title\">Upload Picture</h5>\n <button type=\"button\" class=\"btn-close\" (click)=\"modal.dismiss()\"></button>\n </div>\n <div class=\"modal-body\">\n <small>You can upload a JPG, GIF, or PNG file. (Do not upload pictures containing celebrities,\n nudity, artwork or copyrighted images.)</small>\n <pw-image-cropper\n [aspectRatio]=\"'dynamic'\"\n (imageSelectionEvent)=\"onImageSelected($event)\"\n (closeEvent)=\"modal.close()\">\n </pw-image-cropper>\n </div>\n</ng-template>\n\n<ng-template #rectContent let-modal>\n <div class=\"modal-header\">\n <h5 class=\"modal-title\">Upload Picture</h5>\n <button type=\"button\" class=\"btn-close float-end\" aria-label=\"Close\" (click)=\"modal.dismiss()\"></button>\n </div>\n <div class=\"modal-body\">\n <small>You can upload a JPG, GIF, or PNG file. (Do not upload pictures containing celebrities,\n nudity, artwork or copyrighted images.)</small>\n <pw-image-cropper\n #profile\n [aspectRatio]=\"'dynamic'\"\n (imageSelectionEvent)=\"onRectangularImageSelection($event)\"\n (closeEvent)=\"onClose()\">\n </pw-image-cropper>\n </div>\n</ng-template>\n", styles: ["::ng-deep .modal-content{margin-top:5rem!important}\n"] }]
1654
- }], ctorParameters: () => [{ type: i1$1.FormBuilder }, { type: i2$1.NgbModal }, { type: ResourceService }, { type: i2.AuthService }, { type: i2.TagService }, { type: i0.Injector }], propDecorators: { id: [{
1655
- type: Input
1656
- }], resourceData: [{
1657
- type: Input
1658
- }], updated: [{
1659
- type: Output
1660
- }] } });
1661
-
1662
- var resourceEditCard_component = /*#__PURE__*/Object.freeze({
1663
- __proto__: null,
1664
- ResourceEditCardComponent: ResourceEditCardComponent
1665
- });
1666
-
1667
- /**
1668
- * Lazy-loadable module for ResourceEditCard
1669
- * Contains heavy dependencies (Quill, Calendar, etc.) that are only needed for admins
1670
- * This module is dynamically imported when edit button is clicked
1671
- */
1672
- class ResourceEditModule {
1673
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: ResourceEditModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
1674
- static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "19.2.20", ngImport: i0, type: ResourceEditModule, declarations: [ResourceEditCardComponent], imports: [CommonModule,
1675
- FormsModule,
1676
- ReactiveFormsModule,
1677
- CalendarModule,
1678
- AutoCompleteModule,
1679
- ResourceSharedComponentsModule,
1680
- CoreTranslocoModule,
1681
- TranslocoModule,
1682
- DirectivesModule, i11.QuillModule, UiSwitchModule], exports: [ResourceEditCardComponent] }); }
1683
- static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: ResourceEditModule, imports: [CommonModule,
1684
- FormsModule,
1685
- ReactiveFormsModule,
1686
- CalendarModule,
1687
- AutoCompleteModule,
1688
- ResourceSharedComponentsModule,
1689
- CoreTranslocoModule,
1690
- TranslocoModule,
1691
- DirectivesModule,
1692
- QuillModule.forRoot(),
1693
- UiSwitchModule] }); }
1694
- }
1695
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: ResourceEditModule, decorators: [{
1696
- type: NgModule,
1697
- args: [{
1698
- declarations: [ResourceEditCardComponent],
1699
- imports: [
1700
- CommonModule,
1701
- FormsModule,
1702
- ReactiveFormsModule,
1703
- CalendarModule,
1704
- AutoCompleteModule,
1705
- ResourceSharedComponentsModule,
1706
- CoreTranslocoModule,
1707
- TranslocoModule,
1708
- DirectivesModule,
1709
- QuillModule.forRoot(),
1710
- UiSwitchModule
1711
- ],
1712
- exports: [ResourceEditCardComponent],
1713
- schemas: [CUSTOM_ELEMENTS_SCHEMA]
1714
- }]
1715
- }] });
1716
-
1717
- class TestimonialCardListComponent {
1718
- constructor() {
1719
- this.editPost = new EventEmitter();
1720
- this.posts = [];
1721
- this.postHeader = '';
1722
- this.canEdit = false;
1723
- }
1724
- ngOnChanges(changes) {
1725
- if (changes.posts && this.posts?.length) {
1726
- setTimeout(() => this.initSwiper(), 0); // Wait for DOM to render
1727
- }
1728
- }
1729
- async initSwiper() {
1730
- // Dynamically import Swiper only when needed (lazy-load ~150KB library)
1731
- const { default: Swiper } = await import('swiper');
1732
- const { Navigation, Pagination } = await import('swiper/modules');
1733
- this.swiper = new Swiper('.swiper-container', {
1734
- modules: [Navigation, Pagination],
1735
- slidesPerView: 1,
1736
- spaceBetween: 24,
1737
- centeredSlides: true,
1738
- touchRatio: 1,
1739
- touchAngle: 45,
1740
- grabCursor: true,
1741
- navigation: {
1742
- nextEl: '.swiper-button-next',
1743
- prevEl: '.swiper-button-prev'
1744
- },
1745
- pagination: {
1746
- el: '.swiper-pagination',
1747
- clickable: true
1748
- },
1749
- breakpoints: {
1750
- 425: {
1751
- slidesPerView: 1.05,
1752
- centeredSlides: true
1753
- },
1754
- 470: {
1755
- slidesPerView: 1.25,
1756
- centeredSlides: true
1757
- },
1758
- 564: {
1759
- slidesPerView: 1.5,
1760
- centeredSlides: true
1761
- },
1762
- 640: {
1763
- slidesPerView: 1.5,
1764
- centeredSlides: true
1765
- },
1766
- 768: {
1767
- slidesPerView: 1.5,
1768
- centeredSlides: true
1769
- },
1770
- 1024: {
1771
- slidesPerView: 2, // Allow room between cards
1772
- centeredSlides: false
1773
- },
1774
- 1200: {
1775
- slidesPerView: 3,
1776
- centeredSlides: false
1777
- }
1778
- }
1779
- });
1780
- }
1781
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: TestimonialCardListComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
1782
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.20", type: TestimonialCardListComponent, isStandalone: false, selector: "pw-testimonial-card", inputs: { posts: "posts", postHeader: "postHeader", canEdit: "canEdit" }, outputs: { editPost: "editPost" }, usesOnChanges: true, ngImport: i0, template: "<section class=\"resource-section section-outer bg-white\">\n <div class=\"container\">\n <div *ngIf=\"postHeader\" class=\"d-flex justify-content-between align-items-center flex-wrap mb-3\">\n <h2 class=\"section-heading\">{{postHeader}}</h2>\n </div>\n <div *ngIf=\"posts.length === 0\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Resource.NoDataMessage' | transloco\"/>\n </div>\n<div [hidden]=\"posts.length === 0\">\n <div class=\"swiper-container\">\n <div class=\"swiper-wrapper\">\n <div class=\"swiper-slide\" *ngFor=\"let post of posts\">\n <div class=\"testimonial-box\">\n <pw-resource-edit-card-lazy\n [canEdit]=\"canEdit\"\n [id]=\"post.id\"\n [resourceData]=\"post\"\n (updated)=\"editPost.emit(1, 100)\">\n </pw-resource-edit-card-lazy>\n <div class=\"stars mb-5\">\u2605\u2605\u2605\u2605\u2605</div>\n <div class=\"testimonial-content\">\n <div class=\"ql-container ql-snow ql-res\">\n <div class=\"ql-editor\"\n [innerHTML]=\"post?.body\">\n </div>\n </div>\n </div>\n\n <!-- THIS STAYS AT BOTTOM -->\n <div class=\"avatar-container\">\n <img\n *ngIf=\"!post.rectangular_picture.url.includes('default-photo.jpg') \" [src]=\"post.rectangular_picture.url\"\n alt=\"Logo\"\n class=\"testimonial-logo mt-4\"\n />\n </div>\n </div>\n\n </div>\n </div>\n <div class=\"swiper-pagination\"></div>\n <div class=\"swiper-button-prev\"></div>\n <div class=\"swiper-button-next\"></div>\n </div>\n</div>\n </div>\n</section>", styles: [".resource-section{box-shadow:0 4px 32px -14px #40576d4d!important;position:relative}@media (width >= 768px) and (width <= 1200px){.container{padding:0 6rem!important}}@media (width <= 767px){.container{padding:0 1rem!important}}.ql-res{resize:none!important;border-width:0}.swiper-container{padding:20px;position:relative;overflow:hidden}@media (width >= 768px){.swiper-container{padding:20px 40px}}.resource-card{background:#fff;border-radius:8px;box-shadow:0 0 20px #0000001a;padding:1.5rem;height:100%;display:flex;flex-direction:column;margin:0 auto;width:100%;max-width:350px}.resource-title{font-size:1.25rem;font-weight:600;margin-bottom:1rem}.resource-image{width:100%;aspect-ratio:1/1;object-fit:cover;border-radius:4px}.read-now-btn{margin-top:auto;display:inline-flex;align-items:center;gap:.5rem;color:#000;text-decoration:none;font-weight:500}.read-now-btn .arrow{transition:transform .2s ease}.read-now-btn:hover .arrow{transform:translate(5px)}.swiper-button-prev,.swiper-button-next{color:#000}.swiper-button-prev:after,.swiper-button-next:after{font-size:24px}@media (width <= 767px){.swiper-button-prev,.swiper-button-next{display:none}}.swiper-pagination{position:relative;margin-top:20px}.swiper-pagination-bullet{background:#000;opacity:.5}.swiper-pagination-bullet-active{opacity:1}.swiper-wrapper{display:flex;align-items:stretch}.swiper-slide{display:flex;align-items:stretch;height:auto}.testimonial-box{display:flex;flex-direction:column;justify-content:space-between;background:#fff;border-radius:20px;padding:2.5rem 1.5rem;box-shadow:0 0 20px #0000001a;text-align:center;width:338px;font-size:1.1rem;height:100%;min-height:100%}.testimonial-box span{margin:0;font-size:22px}.testimonial-box .avatar-container{margin-top:auto}.testimonial-box .testimonial-logo{width:100%!important;height:auto!important;max-width:150px!important;object-fit:contain;align-self:center}.testimonial-box .stars{font-size:2.2rem;color:#f6b300;margin-bottom:2.5rem}.centaris-text{margin-bottom:3rem!important}@media (width <= 768px){::ng-deep .swiper-wrapper{gap:1rem!important}.testimonial-box{width:300px!important}}\n", ".video-row{gap:5.5rem!important;margin-top:3rem!important}::ng-deep .resource-section{box-shadow:0 4px 32px -14px #40576d4d!important}.release-icon{height:auto;margin:0 11px 1.9rem;display:block;align-self:center}@media (width >= 768px) and (width <= 1200px){.resource-title{font-size:1.4rem!important}}textarea{font-size:1.4rem!important}@media (width <= 768px){.resource-title{font-size:1.2rem!important}.container{padding:1rem!important}}@media (width >= 768px) and (width <= 1200px){.container{padding:1rem 3rem!important}}@media (width <= 1200px){.resource-vault-section .vault-heading{font-size:3.5rem}.resource-vault-section .vault-description{margin-top:1.35rem}.resource-vault-section .vault-card{width:100%!important}.resource-vault-section .vault-btn{margin-left:0!important;width:100%!important}}@media (width >= 991px){::ng-deep .trial-meeting-section:before{top:600px!important}::ng-deep .dashboard{margin-bottom:1rem!important}section.bg-white.text-center.extra-top-padding{position:relative;overflow:hidden}section.bg-white.text-center.extra-top-padding .banner-header{margin-bottom:4rem!important}section.bg-white.text-center.extra-top-padding:before,section.bg-white.text-center.extra-top-padding:after{content:\"\";position:absolute;background:url(/assets/img/logos/background-banner.png) no-repeat;background-size:contain;width:160px;height:450px;z-index:0;opacity:.8}section.bg-white.text-center.extra-top-padding:before{top:500px;left:0}section.bg-white.text-center.extra-top-padding:after{top:90px;right:0}}.vault-header{text-align:left}@media (width >= 768px) and (width <= 1200px){.container{padding:0 6rem!important}}@media (width <= 1200px){.resource-card{width:100%!important}.release-notes-section{padding:7rem 0!important}}@media (width >= 768px) and (width <= 1200px){.resource-hero-section{padding:0 6rem!important}.cards-row{justify-content:center}}.resource-body-section{background-color:#fff}.resource-body-section .container{padding:0 1.5rem;padding-bottom:4rem!important;padding-top:7rem!important;max-width:850px;margin:0 auto;text-align:left}.user-not-logged-in{background:#f7f7f7;border:1px solid rgb(238,238,238);font-weight:400}.user-not-logged-in a{color:var(--first)!important;text-decoration:none;font-weight:500}.resource-book-section{background:#fff;padding-top:7rem;padding-bottom:0}.resource-book-section .container{max-width:850px;margin:0 auto;padding:0 2rem!important;text-align:left}.resource-book-section .resource-contact{line-height:1.6;font-size:1.5rem}.resource-book-section .resource-contact a{text-decoration:underline;color:#000;margin:0 .2rem}.resource-book-section .resource-contact a:hover{color:var(--first)!important}.resource-offer-section{background:#fff;padding-top:2rem}.resource-offer-section .container{max-width:850px;margin:0 auto;padding:0 1.5rem;text-align:left}.resource-offer-section .resource-title{font-size:2rem;font-weight:700;color:#000;margin-bottom:.25em!important}.resource-offer-section .resource-title strong{font-weight:700}.resource-offer-section .resource-description{font-size:1.5rem;line-height:1.8rem;color:#333;margin-bottom:1.5rem}.resource-offer-section .resource-offer-list{font-size:1.1rem;line-height:1.5rem;margin-bottom:2.5rem;margin-top:2.5rem}.resource-offer-section .resource-offer-list p{font-size:1.5rem;margin:.5rem 0;font-weight:400}.resource-offer-section .resource-signup{margin-bottom:2.5rem}.resource-offer-section .resource-signup .signup-link{font-size:1.5rem;font-weight:400;text-decoration:underline;color:#000}@media (width <= 768px){.resource-offer-section .resource-book-section{padding-top:2rem!important}.resource-offer-section .container{text-align:left}.resource-offer-section .resource-title{font-size:1.5rem}.resource-offer-section .resource-description,.resource-offer-section .resource-offer-list,.resource-offer-section .resource-signup,.resource-offer-section .signup-link,.resource-offer-section .resource-contact,.resource-offer-section .resource-offer-list p{font-size:1.2rem!important}}.resource-offer-intro{font-size:1.5rem;font-weight:400}.outer-section-fadeout{position:absolute;top:139rem;height:40px;width:100%;background:linear-gradient(to bottom,#fff0,#f8f9fa)}.body-divider{border:0;height:40px;width:100%;background:linear-gradient(to bottom,#0000,#00000026);margin:0}@media (width <= 768px){.resource-book-section{padding-top:2rem!important}.resource-contact{font-size:1.2rem!important}}::ng-deep .body-quill{border-width:0!important;max-width:900px;display:block;margin-left:auto;margin-right:auto}::ng-deep .p-textarea{border-radius:.5rem;border:1px solid #ced4da;font-size:1rem!important}.card{background-color:#fff;border-radius:12px}.comment-row{gap:2rem;padding-bottom:5rem;max-width:1000px;display:block;margin-left:auto;margin-right:auto}.comment-label{font-size:1.5rem!important}.response-row{max-width:1000px;display:block;margin-left:auto;margin-right:auto;margin-top:3rem!important}\n"], dependencies: [{ kind: "directive", type: i3.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i3.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i8.LazyImgDirective, selector: "img" }, { kind: "component", type: ResourceEditCardLazyComponent, selector: "pw-resource-edit-card-lazy", inputs: ["id", "resourceData", "canEdit"], outputs: ["updated"] }, { kind: "component", type: i6.NoDataComponent, selector: "pw-no-data", inputs: ["message", "description", "withImage"] }, { kind: "pipe", type: i10.TranslocoPipe, name: "transloco" }] }); }
1783
- }
1784
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: TestimonialCardListComponent, decorators: [{
1785
- type: Component,
1786
- args: [{ selector: 'pw-testimonial-card', standalone: false, template: "<section class=\"resource-section section-outer bg-white\">\n <div class=\"container\">\n <div *ngIf=\"postHeader\" class=\"d-flex justify-content-between align-items-center flex-wrap mb-3\">\n <h2 class=\"section-heading\">{{postHeader}}</h2>\n </div>\n <div *ngIf=\"posts.length === 0\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Resource.NoDataMessage' | transloco\"/>\n </div>\n<div [hidden]=\"posts.length === 0\">\n <div class=\"swiper-container\">\n <div class=\"swiper-wrapper\">\n <div class=\"swiper-slide\" *ngFor=\"let post of posts\">\n <div class=\"testimonial-box\">\n <pw-resource-edit-card-lazy\n [canEdit]=\"canEdit\"\n [id]=\"post.id\"\n [resourceData]=\"post\"\n (updated)=\"editPost.emit(1, 100)\">\n </pw-resource-edit-card-lazy>\n <div class=\"stars mb-5\">\u2605\u2605\u2605\u2605\u2605</div>\n <div class=\"testimonial-content\">\n <div class=\"ql-container ql-snow ql-res\">\n <div class=\"ql-editor\"\n [innerHTML]=\"post?.body\">\n </div>\n </div>\n </div>\n\n <!-- THIS STAYS AT BOTTOM -->\n <div class=\"avatar-container\">\n <img\n *ngIf=\"!post.rectangular_picture.url.includes('default-photo.jpg') \" [src]=\"post.rectangular_picture.url\"\n alt=\"Logo\"\n class=\"testimonial-logo mt-4\"\n />\n </div>\n </div>\n\n </div>\n </div>\n <div class=\"swiper-pagination\"></div>\n <div class=\"swiper-button-prev\"></div>\n <div class=\"swiper-button-next\"></div>\n </div>\n</div>\n </div>\n</section>", styles: [".resource-section{box-shadow:0 4px 32px -14px #40576d4d!important;position:relative}@media (width >= 768px) and (width <= 1200px){.container{padding:0 6rem!important}}@media (width <= 767px){.container{padding:0 1rem!important}}.ql-res{resize:none!important;border-width:0}.swiper-container{padding:20px;position:relative;overflow:hidden}@media (width >= 768px){.swiper-container{padding:20px 40px}}.resource-card{background:#fff;border-radius:8px;box-shadow:0 0 20px #0000001a;padding:1.5rem;height:100%;display:flex;flex-direction:column;margin:0 auto;width:100%;max-width:350px}.resource-title{font-size:1.25rem;font-weight:600;margin-bottom:1rem}.resource-image{width:100%;aspect-ratio:1/1;object-fit:cover;border-radius:4px}.read-now-btn{margin-top:auto;display:inline-flex;align-items:center;gap:.5rem;color:#000;text-decoration:none;font-weight:500}.read-now-btn .arrow{transition:transform .2s ease}.read-now-btn:hover .arrow{transform:translate(5px)}.swiper-button-prev,.swiper-button-next{color:#000}.swiper-button-prev:after,.swiper-button-next:after{font-size:24px}@media (width <= 767px){.swiper-button-prev,.swiper-button-next{display:none}}.swiper-pagination{position:relative;margin-top:20px}.swiper-pagination-bullet{background:#000;opacity:.5}.swiper-pagination-bullet-active{opacity:1}.swiper-wrapper{display:flex;align-items:stretch}.swiper-slide{display:flex;align-items:stretch;height:auto}.testimonial-box{display:flex;flex-direction:column;justify-content:space-between;background:#fff;border-radius:20px;padding:2.5rem 1.5rem;box-shadow:0 0 20px #0000001a;text-align:center;width:338px;font-size:1.1rem;height:100%;min-height:100%}.testimonial-box span{margin:0;font-size:22px}.testimonial-box .avatar-container{margin-top:auto}.testimonial-box .testimonial-logo{width:100%!important;height:auto!important;max-width:150px!important;object-fit:contain;align-self:center}.testimonial-box .stars{font-size:2.2rem;color:#f6b300;margin-bottom:2.5rem}.centaris-text{margin-bottom:3rem!important}@media (width <= 768px){::ng-deep .swiper-wrapper{gap:1rem!important}.testimonial-box{width:300px!important}}\n", ".video-row{gap:5.5rem!important;margin-top:3rem!important}::ng-deep .resource-section{box-shadow:0 4px 32px -14px #40576d4d!important}.release-icon{height:auto;margin:0 11px 1.9rem;display:block;align-self:center}@media (width >= 768px) and (width <= 1200px){.resource-title{font-size:1.4rem!important}}textarea{font-size:1.4rem!important}@media (width <= 768px){.resource-title{font-size:1.2rem!important}.container{padding:1rem!important}}@media (width >= 768px) and (width <= 1200px){.container{padding:1rem 3rem!important}}@media (width <= 1200px){.resource-vault-section .vault-heading{font-size:3.5rem}.resource-vault-section .vault-description{margin-top:1.35rem}.resource-vault-section .vault-card{width:100%!important}.resource-vault-section .vault-btn{margin-left:0!important;width:100%!important}}@media (width >= 991px){::ng-deep .trial-meeting-section:before{top:600px!important}::ng-deep .dashboard{margin-bottom:1rem!important}section.bg-white.text-center.extra-top-padding{position:relative;overflow:hidden}section.bg-white.text-center.extra-top-padding .banner-header{margin-bottom:4rem!important}section.bg-white.text-center.extra-top-padding:before,section.bg-white.text-center.extra-top-padding:after{content:\"\";position:absolute;background:url(/assets/img/logos/background-banner.png) no-repeat;background-size:contain;width:160px;height:450px;z-index:0;opacity:.8}section.bg-white.text-center.extra-top-padding:before{top:500px;left:0}section.bg-white.text-center.extra-top-padding:after{top:90px;right:0}}.vault-header{text-align:left}@media (width >= 768px) and (width <= 1200px){.container{padding:0 6rem!important}}@media (width <= 1200px){.resource-card{width:100%!important}.release-notes-section{padding:7rem 0!important}}@media (width >= 768px) and (width <= 1200px){.resource-hero-section{padding:0 6rem!important}.cards-row{justify-content:center}}.resource-body-section{background-color:#fff}.resource-body-section .container{padding:0 1.5rem;padding-bottom:4rem!important;padding-top:7rem!important;max-width:850px;margin:0 auto;text-align:left}.user-not-logged-in{background:#f7f7f7;border:1px solid rgb(238,238,238);font-weight:400}.user-not-logged-in a{color:var(--first)!important;text-decoration:none;font-weight:500}.resource-book-section{background:#fff;padding-top:7rem;padding-bottom:0}.resource-book-section .container{max-width:850px;margin:0 auto;padding:0 2rem!important;text-align:left}.resource-book-section .resource-contact{line-height:1.6;font-size:1.5rem}.resource-book-section .resource-contact a{text-decoration:underline;color:#000;margin:0 .2rem}.resource-book-section .resource-contact a:hover{color:var(--first)!important}.resource-offer-section{background:#fff;padding-top:2rem}.resource-offer-section .container{max-width:850px;margin:0 auto;padding:0 1.5rem;text-align:left}.resource-offer-section .resource-title{font-size:2rem;font-weight:700;color:#000;margin-bottom:.25em!important}.resource-offer-section .resource-title strong{font-weight:700}.resource-offer-section .resource-description{font-size:1.5rem;line-height:1.8rem;color:#333;margin-bottom:1.5rem}.resource-offer-section .resource-offer-list{font-size:1.1rem;line-height:1.5rem;margin-bottom:2.5rem;margin-top:2.5rem}.resource-offer-section .resource-offer-list p{font-size:1.5rem;margin:.5rem 0;font-weight:400}.resource-offer-section .resource-signup{margin-bottom:2.5rem}.resource-offer-section .resource-signup .signup-link{font-size:1.5rem;font-weight:400;text-decoration:underline;color:#000}@media (width <= 768px){.resource-offer-section .resource-book-section{padding-top:2rem!important}.resource-offer-section .container{text-align:left}.resource-offer-section .resource-title{font-size:1.5rem}.resource-offer-section .resource-description,.resource-offer-section .resource-offer-list,.resource-offer-section .resource-signup,.resource-offer-section .signup-link,.resource-offer-section .resource-contact,.resource-offer-section .resource-offer-list p{font-size:1.2rem!important}}.resource-offer-intro{font-size:1.5rem;font-weight:400}.outer-section-fadeout{position:absolute;top:139rem;height:40px;width:100%;background:linear-gradient(to bottom,#fff0,#f8f9fa)}.body-divider{border:0;height:40px;width:100%;background:linear-gradient(to bottom,#0000,#00000026);margin:0}@media (width <= 768px){.resource-book-section{padding-top:2rem!important}.resource-contact{font-size:1.2rem!important}}::ng-deep .body-quill{border-width:0!important;max-width:900px;display:block;margin-left:auto;margin-right:auto}::ng-deep .p-textarea{border-radius:.5rem;border:1px solid #ced4da;font-size:1rem!important}.card{background-color:#fff;border-radius:12px}.comment-row{gap:2rem;padding-bottom:5rem;max-width:1000px;display:block;margin-left:auto;margin-right:auto}.comment-label{font-size:1.5rem!important}.response-row{max-width:1000px;display:block;margin-left:auto;margin-right:auto;margin-top:3rem!important}\n"] }]
1787
- }], propDecorators: { editPost: [{
1788
- type: Output
1789
- }], posts: [{
1790
- type: Input
1791
- }], postHeader: [{
1792
- type: Input
1793
- }], canEdit: [{
1794
- type: Input
1795
- }] } });
1796
-
1797
- /**
1798
- * Generated bundle index. Do not edit.
1799
- */
1800
-
1801
- export { BaseResourceComponent as B, CaseStudyCardComponent as C, ResourceVideoCardComponent as R, TestimonialCardListComponent as T, UpcomingEventCardComponent as U, ResourceCardComponent as a, ResourceNoteCardComponent as b, ResourceVaultComponent as c, ResourceCardsModule as d, ResourceService as e, ResourceEditCardLazyComponent as f, ResourceSharedModule as g, ResourceTopBannerEditComponent as h, ResourceCompanyCardComponent as i, ResourceEditCardComponent as j, ResourceEditModule as k, ResourceModule as l, ResourcePublicModule as m, Trial4ContactUsModule as n };
1802
- //# sourceMappingURL=posiwise-resource-module-posiwise-resource-module-CBgwfoFQ.mjs.map