@activepieces/piece-ghostcms 0.1.4 → 0.1.6

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 (41) hide show
  1. package/package.json +7 -24
  2. package/src/index.js +56 -72
  3. package/README.md +0 -7
  4. package/src/index.d.ts +0 -8
  5. package/src/index.js.map +0 -1
  6. package/src/lib/actions/create-member.d.ts +0 -15
  7. package/src/lib/actions/create-member.js +0 -60
  8. package/src/lib/actions/create-member.js.map +0 -1
  9. package/src/lib/actions/create-post.d.ts +0 -20
  10. package/src/lib/actions/create-post.js +0 -84
  11. package/src/lib/actions/create-post.js.map +0 -1
  12. package/src/lib/actions/find-member.d.ts +0 -6
  13. package/src/lib/actions/find-member.js +0 -36
  14. package/src/lib/actions/find-member.js.map +0 -1
  15. package/src/lib/actions/find-user.d.ts +0 -6
  16. package/src/lib/actions/find-user.js +0 -36
  17. package/src/lib/actions/find-user.js.map +0 -1
  18. package/src/lib/actions/update-member.d.ts +0 -22
  19. package/src/lib/actions/update-member.js +0 -63
  20. package/src/lib/actions/update-member.js.map +0 -1
  21. package/src/lib/common/index.d.ts +0 -33
  22. package/src/lib/common/index.js +0 -203
  23. package/src/lib/common/index.js.map +0 -1
  24. package/src/lib/triggers/member-added.d.ts +0 -14
  25. package/src/lib/triggers/member-added.js +0 -101
  26. package/src/lib/triggers/member-added.js.map +0 -1
  27. package/src/lib/triggers/member-deleted.d.ts +0 -14
  28. package/src/lib/triggers/member-deleted.js +0 -101
  29. package/src/lib/triggers/member-deleted.js.map +0 -1
  30. package/src/lib/triggers/member-edited.d.ts +0 -14
  31. package/src/lib/triggers/member-edited.js +0 -106
  32. package/src/lib/triggers/member-edited.js.map +0 -1
  33. package/src/lib/triggers/page-published.d.ts +0 -14
  34. package/src/lib/triggers/page-published.js +0 -208
  35. package/src/lib/triggers/page-published.js.map +0 -1
  36. package/src/lib/triggers/post-published.d.ts +0 -14
  37. package/src/lib/triggers/post-published.js +0 -209
  38. package/src/lib/triggers/post-published.js.map +0 -1
  39. package/src/lib/triggers/post-scheduled.d.ts +0 -14
  40. package/src/lib/triggers/post-scheduled.js +0 -209
  41. package/src/lib/triggers/post-scheduled.js.map +0 -1
@@ -1,209 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.postPublished = void 0;
4
- const tslib_1 = require("tslib");
5
- const pieces_framework_1 = require("@activepieces/pieces-framework");
6
- const __1 = require("../..");
7
- const common_1 = require("../common");
8
- exports.postPublished = (0, pieces_framework_1.createTrigger)({
9
- auth: __1.ghostAuth,
10
- name: 'post_published',
11
- displayName: 'Post Published',
12
- description: 'Triggers when a post is published',
13
- type: pieces_framework_1.TriggerStrategy.WEBHOOK,
14
- props: {},
15
- onEnable(context) {
16
- return tslib_1.__awaiter(this, void 0, void 0, function* () {
17
- var _a;
18
- const webhookData = yield common_1.common.subscribeWebhook(context.auth, 'post.published', context.webhookUrl);
19
- yield ((_a = context.store) === null || _a === void 0 ? void 0 : _a.put('_post_published_trigger', {
20
- webhookId: webhookData.webhooks[0].id,
21
- }));
22
- });
23
- },
24
- onDisable(context) {
25
- return tslib_1.__awaiter(this, void 0, void 0, function* () {
26
- var _a;
27
- const response = yield ((_a = context.store) === null || _a === void 0 ? void 0 : _a.get('_post_published_trigger'));
28
- if (response !== null && response !== undefined) {
29
- yield common_1.common.unsubscribeWebhook(context.auth, response.webhookId);
30
- }
31
- });
32
- },
33
- run(context) {
34
- return tslib_1.__awaiter(this, void 0, void 0, function* () {
35
- return [context.payload.body];
36
- });
37
- },
38
- sampleData: {
39
- post: {
40
- current: {
41
- id: '64be83c424cb9a0001f49f1d',
42
- url: 'https://test-publication.ghost.io/test-post/',
43
- html: '<p>Hello my friends</p><p></p><p>this is testing</p>',
44
- slug: 'test-post',
45
- tags: [],
46
- uuid: '77afb2c2-af1a-4a7f-bebc-fa1e314579d0',
47
- count: {
48
- clicks: 0,
49
- negative_feedback: 0,
50
- positive_feedback: 0,
51
- },
52
- tiers: [
53
- {
54
- id: '64be4f5a03946b00098ef8f4',
55
- name: 'Free',
56
- slug: 'free',
57
- type: 'free',
58
- active: true,
59
- currency: null,
60
- created_at: '2023-07-24T10:15:54.000Z',
61
- trial_days: 0,
62
- updated_at: '2023-07-24T10:15:54.000Z',
63
- visibility: 'public',
64
- description: null,
65
- yearly_price: null,
66
- monthly_price: null,
67
- yearly_price_id: null,
68
- monthly_price_id: null,
69
- welcome_page_url: null,
70
- },
71
- {
72
- id: '64be4f5a03946b00098ef8f5',
73
- name: 'Test Publication',
74
- slug: 'default-product',
75
- type: 'paid',
76
- active: true,
77
- currency: 'usd',
78
- created_at: '2023-07-24T10:15:54.000Z',
79
- trial_days: 0,
80
- updated_at: '2023-07-24T10:15:54.000Z',
81
- visibility: 'public',
82
- description: null,
83
- yearly_price: 5000,
84
- monthly_price: 500,
85
- yearly_price_id: null,
86
- monthly_price_id: null,
87
- welcome_page_url: null,
88
- },
89
- ],
90
- title: 'Test Post',
91
- status: 'published',
92
- authors: [
93
- {
94
- id: '1',
95
- bio: null,
96
- url: 'https://test-publication.ghost.io/author/slug/',
97
- name: 'First Last',
98
- slug: 'slug',
99
- tour: null,
100
- email: 'my@email.com',
101
- roles: [
102
- {
103
- id: '64be4f5903946b00098ef8eb',
104
- name: 'Owner',
105
- created_at: '2023-07-24T10:15:53.000Z',
106
- updated_at: '2023-07-24T10:15:53.000Z',
107
- description: 'Blog Owner',
108
- },
109
- ],
110
- status: 'active',
111
- twitter: null,
112
- website: null,
113
- facebook: null,
114
- location: null,
115
- last_seen: '2023-07-24T13:05:18.000Z',
116
- created_at: '2023-07-24T10:15:53.000Z',
117
- meta_title: null,
118
- updated_at: '2023-07-24T13:05:18.000Z',
119
- cover_image: null,
120
- accessibility: '{"nightShift":true}',
121
- profile_image: 'https://www.gravatar.com/avatar/123123123?s=250&r=x&d=mp',
122
- meta_description: null,
123
- comment_notifications: true,
124
- mention_notifications: true,
125
- milestone_notifications: true,
126
- free_member_signup_notification: true,
127
- paid_subscription_started_notification: true,
128
- paid_subscription_canceled_notification: false,
129
- },
130
- ],
131
- excerpt: 'Hello my friends\n\n\n\nthis is testing',
132
- featured: false,
133
- og_image: null,
134
- og_title: null,
135
- mobiledoc: '{"version":"0.3.1","atoms":[],"cards":[],"markups":[],"sections":[[1,"p",[[0,[],0,"Hello my friends"]]],[1,"p",[]],[1,"p",[[0,[],0,"this is testing"]]]],"ghostVersion":"4.0"}',
136
- plaintext: 'Hello my friends\n\n\n\nthis is testing',
137
- comment_id: '64be83c424cb9a0001f49f1d',
138
- created_at: '2023-07-24T13:59:32.000Z',
139
- email_only: false,
140
- meta_title: null,
141
- updated_at: '2023-07-24T13:59:43.000Z',
142
- visibility: 'public',
143
- frontmatter: null,
144
- primary_tag: null,
145
- published_at: '2023-07-24T13:59:43.000Z',
146
- reading_time: 0,
147
- canonical_url: null,
148
- email_segment: 'all',
149
- email_subject: null,
150
- feature_image: null,
151
- twitter_image: null,
152
- twitter_title: null,
153
- custom_excerpt: null,
154
- og_description: null,
155
- post_revisions: [],
156
- primary_author: {
157
- id: '1',
158
- bio: null,
159
- url: 'https://test-publication.ghost.io/author/slug/',
160
- name: 'First Last',
161
- slug: 'slug',
162
- tour: null,
163
- email: 'my@email.com',
164
- roles: [
165
- {
166
- id: '64be4f5903946b00098ef8eb',
167
- name: 'Owner',
168
- created_at: '2023-07-24T10:15:53.000Z',
169
- updated_at: '2023-07-24T10:15:53.000Z',
170
- description: 'Blog Owner',
171
- },
172
- ],
173
- status: 'active',
174
- twitter: null,
175
- website: null,
176
- facebook: null,
177
- location: null,
178
- last_seen: '2023-07-24T13:05:18.000Z',
179
- created_at: '2023-07-24T10:15:53.000Z',
180
- meta_title: null,
181
- updated_at: '2023-07-24T13:05:18.000Z',
182
- cover_image: null,
183
- accessibility: '{"nightShift":true}',
184
- profile_image: 'https://www.gravatar.com/avatar/123123123?s=250&r=x&d=mp',
185
- meta_description: null,
186
- comment_notifications: true,
187
- mention_notifications: true,
188
- milestone_notifications: true,
189
- free_member_signup_notification: true,
190
- paid_subscription_started_notification: true,
191
- paid_subscription_canceled_notification: false,
192
- },
193
- custom_template: null,
194
- meta_description: null,
195
- feature_image_alt: null,
196
- codeinjection_foot: null,
197
- codeinjection_head: null,
198
- twitter_description: null,
199
- feature_image_caption: null,
200
- },
201
- previous: {
202
- status: 'draft',
203
- updated_at: '2023-07-24T13:59:39.000Z',
204
- published_at: null,
205
- },
206
- },
207
- },
208
- });
209
- //# sourceMappingURL=post-published.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"post-published.js","sourceRoot":"","sources":["../../../../../../../../packages/pieces/community/ghostcms/src/lib/triggers/post-published.ts"],"names":[],"mappings":";;;;AAAA,qEAAgF;AAEhF,6BAAkC;AAClC,sCAAmC;AAEtB,QAAA,aAAa,GAAG,IAAA,gCAAa,EAAC;IACzC,IAAI,EAAE,aAAS;IACf,IAAI,EAAE,gBAAgB;IACtB,WAAW,EAAE,gBAAgB;IAC7B,WAAW,EAAE,mCAAmC;IAChD,IAAI,EAAE,kCAAe,CAAC,OAAO;IAC7B,KAAK,EAAE,EAAE;IACH,QAAQ,CAAC,OAAO;;;YACpB,MAAM,WAAW,GAAQ,MAAM,eAAM,CAAC,gBAAgB,CACpD,OAAO,CAAC,IAAI,EACZ,gBAAgB,EAChB,OAAO,CAAC,UAAU,CACnB,CAAC;YAEF,MAAM,CAAA,MAAA,OAAO,CAAC,KAAK,0CAAE,GAAG,CAAC,yBAAyB,EAAE;gBAClD,SAAS,EAAE,WAAW,CAAC,QAAQ,CAAC,CAAC,CAAC,CAAC,EAAE;aACtC,CAAC,CAAA,CAAC;QACL,CAAC;KAAA;IACK,SAAS,CAAC,OAAO;;;YACrB,MAAM,QAAQ,GAEH,MAAM,CAAA,MAAA,OAAO,CAAC,KAAK,0CAAE,GAAG,CAAC,yBAAyB,CAAC,CAAA,CAAC;YAE/D,IAAI,QAAQ,KAAK,IAAI,IAAI,QAAQ,KAAK,SAAS,EA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a,EACX,0DAA0D;oBAC5D,gBAAgB,EAAE,IAAI;oBACtB,qBAAqB,EAAE,IAAI;oBAC3B,qBAAqB,EAAE,IAAI;oBAC3B,uBAAuB,EAAE,IAAI;oBAC7B,+BAA+B,EAAE,IAAI;oBACrC,sCAAsC,EAAE,IAAI;oBAC5C,uCAAuC,EAAE,KAAK;iBAC/C;gBACD,eAAe,EAAE,IAAI;gBACrB,gBAAgB,EAAE,IAAI;gBACtB,iBAAiB,EAAE,IAAI;gBACvB,kBAAkB,EAAE,IAAI;gBACxB,kBAAkB,EAAE,IAAI;gBACxB,mBAAmB,EAAE,IAAI;gBACzB,qBAAqB,EAAE,IAAI;aAC5B;YACD,QAAQ,EAAE;gBACR,MAAM,EAAE,OAAO;gBACf,UAAU,EAAE,0BAA0B;gBACtC,YAAY,EAAE,IAAI;aACnB;SACF;KACF;CACF,CAAC,CAAC"}
@@ -1,14 +0,0 @@
1
- import { TriggerStrategy } from '@activepieces/pieces-framework';
2
- export declare const postScheduled: import("@activepieces/pieces-framework").ITrigger<TriggerStrategy.WEBHOOK, import("@activepieces/pieces-framework").CustomAuthProperty<{
3
- baseUrl: import("@activepieces/pieces-framework").ShortTextProperty<true>;
4
- apiKey: import("@activepieces/pieces-framework").SecretTextProperty<true>;
5
- }>, {}> | import("@activepieces/pieces-framework").ITrigger<TriggerStrategy.POLLING, import("@activepieces/pieces-framework").CustomAuthProperty<{
6
- baseUrl: import("@activepieces/pieces-framework").ShortTextProperty<true>;
7
- apiKey: import("@activepieces/pieces-framework").SecretTextProperty<true>;
8
- }>, {}> | import("@activepieces/pieces-framework").ITrigger<TriggerStrategy.MANUAL, import("@activepieces/pieces-framework").CustomAuthProperty<{
9
- baseUrl: import("@activepieces/pieces-framework").ShortTextProperty<true>;
10
- apiKey: import("@activepieces/pieces-framework").SecretTextProperty<true>;
11
- }>, {}> | import("@activepieces/pieces-framework").ITrigger<TriggerStrategy.APP_WEBHOOK, import("@activepieces/pieces-framework").CustomAuthProperty<{
12
- baseUrl: import("@activepieces/pieces-framework").ShortTextProperty<true>;
13
- apiKey: import("@activepieces/pieces-framework").SecretTextProperty<true>;
14
- }>, {}>;
@@ -1,209 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.postScheduled = void 0;
4
- const tslib_1 = require("tslib");
5
- const pieces_framework_1 = require("@activepieces/pieces-framework");
6
- const __1 = require("../..");
7
- const common_1 = require("../common");
8
- exports.postScheduled = (0, pieces_framework_1.createTrigger)({
9
- auth: __1.ghostAuth,
10
- name: 'post_scheduled',
11
- displayName: 'Post Scheduled',
12
- description: 'Triggers when a post is scheduled',
13
- type: pieces_framework_1.TriggerStrategy.WEBHOOK,
14
- props: {},
15
- onEnable(context) {
16
- return tslib_1.__awaiter(this, void 0, void 0, function* () {
17
- var _a;
18
- const webhookData = yield common_1.common.subscribeWebhook(context.auth, 'post.scheduled', context.webhookUrl);
19
- yield ((_a = context.store) === null || _a === void 0 ? void 0 : _a.put('_post_scheduled_trigger', {
20
- webhookId: webhookData.webhooks[0].id,
21
- }));
22
- });
23
- },
24
- onDisable(context) {
25
- return tslib_1.__awaiter(this, void 0, void 0, function* () {
26
- var _a;
27
- const response = yield ((_a = context.store) === null || _a === void 0 ? void 0 : _a.get('_post_scheduled_trigger'));
28
- if (response !== null && response !== undefined) {
29
- yield common_1.common.unsubscribeWebhook(context.auth, response.webhookId);
30
- }
31
- });
32
- },
33
- run(context) {
34
- return tslib_1.__awaiter(this, void 0, void 0, function* () {
35
- return [context.payload.body];
36
- });
37
- },
38
- sampleData: {
39
- post: {
40
- current: {
41
- id: '64be851224cb9a0001f49f2a',
42
- url: 'https://test-publication.ghost.io/p/cdfeba97-3d7e-44e5-902c-c9f68b46a432/',
43
- html: '<p>This is a scheduled post</p>',
44
- slug: 'scheduled-post',
45
- tags: [],
46
- uuid: 'cdfeba97-3d7e-44e5-902c-c9f68b46a432',
47
- count: {
48
- clicks: 0,
49
- negative_feedback: 0,
50
- positive_feedback: 0,
51
- },
52
- tiers: [
53
- {
54
- id: '64be4f5a03946b00098ef8f4',
55
- name: 'Free',
56
- slug: 'free',
57
- type: 'free',
58
- active: true,
59
- currency: null,
60
- created_at: '2023-07-24T10:15:54.000Z',
61
- trial_days: 0,
62
- updated_at: '2023-07-24T10:15:54.000Z',
63
- visibility: 'public',
64
- description: null,
65
- yearly_price: null,
66
- monthly_price: null,
67
- yearly_price_id: null,
68
- monthly_price_id: null,
69
- welcome_page_url: null,
70
- },
71
- {
72
- id: '64be4f5a03946b00098ef8f5',
73
- name: 'Test Publication',
74
- slug: 'default-product',
75
- type: 'paid',
76
- active: true,
77
- currency: 'usd',
78
- created_at: '2023-07-24T10:15:54.000Z',
79
- trial_days: 0,
80
- updated_at: '2023-07-24T10:15:54.000Z',
81
- visibility: 'public',
82
- description: null,
83
- yearly_price: 5000,
84
- monthly_price: 500,
85
- yearly_price_id: null,
86
- monthly_price_id: null,
87
- welcome_page_url: null,
88
- },
89
- ],
90
- title: 'Scheduled post',
91
- status: 'scheduled',
92
- authors: [
93
- {
94
- id: '1',
95
- bio: null,
96
- url: 'https://test-publication.ghost.io/author/slug/',
97
- name: 'First Last',
98
- slug: 'slug',
99
- tour: null,
100
- email: 'my@email.com',
101
- roles: [
102
- {
103
- id: '64be4f5903946b00098ef8eb',
104
- name: 'Owner',
105
- created_at: '2023-07-24T10:15:53.000Z',
106
- updated_at: '2023-07-24T10:15:53.000Z',
107
- description: 'Blog Owner',
108
- },
109
- ],
110
- status: 'active',
111
- twitter: null,
112
- website: null,
113
- facebook: null,
114
- location: null,
115
- last_seen: '2023-07-24T13:05:18.000Z',
116
- created_at: '2023-07-24T10:15:53.000Z',
117
- meta_title: null,
118
- updated_at: '2023-07-24T13:05:18.000Z',
119
- cover_image: null,
120
- accessibility: '{"nightShift":true}',
121
- profile_image: 'https://www.gravatar.com/avatar/123123123?s=250&r=x&d=mp',
122
- meta_description: null,
123
- comment_notifications: true,
124
- mention_notifications: true,
125
- milestone_notifications: true,
126
- free_member_signup_notification: true,
127
- paid_subscription_started_notification: true,
128
- paid_subscription_canceled_notification: false,
129
- },
130
- ],
131
- excerpt: 'This is a scheduled post',
132
- featured: false,
133
- og_image: null,
134
- og_title: null,
135
- mobiledoc: '{"version":"0.3.1","atoms":[],"cards":[],"markups":[],"sections":[[1,"p",[[0,[],0,"This is a scheduled post"]]]],"ghostVersion":"4.0"}',
136
- plaintext: 'This is a scheduled post',
137
- comment_id: '64be851224cb9a0001f49f2a',
138
- created_at: '2023-07-24T14:05:06.000Z',
139
- email_only: false,
140
- meta_title: null,
141
- updated_at: '2023-07-24T14:05:18.000Z',
142
- visibility: 'public',
143
- frontmatter: null,
144
- primary_tag: null,
145
- published_at: '2023-07-24T14:15:12.000Z',
146
- reading_time: 0,
147
- canonical_url: null,
148
- email_segment: 'all',
149
- email_subject: null,
150
- feature_image: null,
151
- twitter_image: null,
152
- twitter_title: null,
153
- custom_excerpt: null,
154
- og_description: null,
155
- post_revisions: [],
156
- primary_author: {
157
- id: '1',
158
- bio: null,
159
- url: 'https://test-publication.ghost.io/author/slug/',
160
- name: 'First Last',
161
- slug: 'slug',
162
- tour: null,
163
- email: 'my@email.com',
164
- roles: [
165
- {
166
- id: '64be4f5903946b00098ef8eb',
167
- name: 'Owner',
168
- created_at: '2023-07-24T10:15:53.000Z',
169
- updated_at: '2023-07-24T10:15:53.000Z',
170
- description: 'Blog Owner',
171
- },
172
- ],
173
- status: 'active',
174
- twitter: null,
175
- website: null,
176
- facebook: null,
177
- location: null,
178
- last_seen: '2023-07-24T13:05:18.000Z',
179
- created_at: '2023-07-24T10:15:53.000Z',
180
- meta_title: null,
181
- updated_at: '2023-07-24T13:05:18.000Z',
182
- cover_image: null,
183
- accessibility: '{"nightShift":true}',
184
- profile_image: 'https://www.gravatar.com/avatar/123123123?s=250&r=x&d=mp',
185
- meta_description: null,
186
- comment_notifications: true,
187
- mention_notifications: true,
188
- milestone_notifications: true,
189
- free_member_signup_notification: true,
190
- paid_subscription_started_notification: true,
191
- paid_subscription_canceled_notification: false,
192
- },
193
- custom_template: null,
194
- meta_description: null,
195
- feature_image_alt: null,
196
- codeinjection_foot: null,
197
- codeinjection_head: null,
198
- twitter_description: null,
199
- feature_image_caption: null,
200
- },
201
- previous: {
202
- status: 'draft',
203
- updated_at: '2023-07-24T14:05:10.000Z',
204
- published_at: null,
205
- },
206
- },
207
- },
208
- });
209
- //# sourceMappingURL=post-scheduled.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"post-scheduled.js","sourceRoot":"","sources":["../../../../../../../../packages/pieces/community/ghostcms/src/lib/triggers/post-scheduled.ts"],"names":[],"mappings":";;;;AAAA,qEAAgF;AAEhF,6BAAkC;AAClC,sCAAmC;AAEtB,QAAA,aAAa,GAAG,IAAA,gCAAa,EAAC;IACzC,IAAI,EAAE,aAAS;IACf,IAAI,EAAE,gBAAgB;IACtB,WAAW,EAAE,gBAAgB;IAC7B,WAAW,EAAE,mCAAmC;IAChD,IAAI,EAAE,kCAAe,CAAC,OAAO;IAC7B,KAAK,EAAE,EAAE;IACH,QAAQ,CAAC,OAAO;;;YACpB,MAAM,WAAW,GAAQ,MAAM,eAAM,CAAC,gBAAgB,CACpD,OAAO,CAAC,IAAI,EACZ,gBAAgB,EAChB,OAAO,CAAC,UAAU,CACnB,CAAC;YAEF,MAAM,CAAA,MAAA,OAAO,CAAC,KAAK,0CAAE,GAAG,CAAC,yBAAyB,EAAE;gBAClD,SAAS,EAAE,WAAW,CAAC,QAAQ,CAAC,CAAC,CAAC,CAAC,EAAE;aACtC,CAAC,CAAA,CAAC;QACL,CAAC;KAAA;IACK,SAAS,CAAC,OAAO;;;YACrB,MAAM,QAAQ,GAEH,MAAM,CAAA,MAAA,OAAO,CAAC,KAAK,0CAAE,GAAG,CAAC,yBAAyB,CAAC,CAAA,CAAC;YAE/D,IAAI,QAAQ,KAAK,IAAI,IAAI,QAAQ,KAAK,SAAS,EAAE,CAAC;gBAChD,MAAM,eAAM,CAAC,kBAAkB,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