@cakemail-org/ui-components-v2 2.0.98 → 2.0.99

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.
@@ -8,5 +8,9 @@ export declare class FormsFactory {
8
8
  static create({ form }: {
9
9
  form: Partial<TEnhancedFormModel>;
10
10
  }): Promise<EnhancedFormModel>;
11
+ static renderPublic({ id, token }: {
12
+ id: string;
13
+ token: string;
14
+ }): Promise<string>;
11
15
  }
12
16
  export * from "./types";
package/dist/cjs/index.js CHANGED
@@ -10174,6 +10174,15 @@ function renderForm(_a) {
10174
10174
  }
10175
10175
  });
10176
10176
  }
10177
+ function renderPublicHtmlForm(_a) {
10178
+ var id = _a.id, token = _a.token;
10179
+ return callApi({
10180
+ url: uiKitConfig.GATEWAY_PROXY + "/forms/" + id + "/render-html?token=" + token,
10181
+ fetchOptions: {
10182
+ method: exports.EMethods.get
10183
+ }
10184
+ });
10185
+ }
10177
10186
 
10178
10187
  exports.EEditorType = void 0;
10179
10188
  (function (EEditorType) {
@@ -17098,7 +17107,7 @@ var FormModel = /** @class */ (function (_super) {
17098
17107
  var SummaryEnhancedFormModel = /** @class */ (function (_super) {
17099
17108
  __extends(SummaryEnhancedFormModel, _super);
17100
17109
  function SummaryEnhancedFormModel(_a) {
17101
- var id = _a.id, list_id = _a.list_id, enabled = _a.enabled, name = _a.name, description = _a.description, tags = _a.tags, post_redirect_url = _a.post_redirect_url, double_opt_in = _a.double_opt_in, double_opt_in_redirect_url = _a.double_opt_in_redirect_url, submission_url = _a.submission_url, async_processing = _a.async_processing, branding = _a.branding, created_on = _a.created_on, updated_on = _a.updated_on, published_on = _a.published_on, edited_by = _a.edited_by, thumbnail_url = _a.thumbnail_url, recaptcha = _a.recaptcha;
17110
+ var id = _a.id, list_id = _a.list_id, enabled = _a.enabled, name = _a.name, description = _a.description, tags = _a.tags, post_redirect_url = _a.post_redirect_url, double_opt_in = _a.double_opt_in, double_opt_in_redirect_url = _a.double_opt_in_redirect_url, submission_url = _a.submission_url, async_processing = _a.async_processing, branding = _a.branding, created_on = _a.created_on, updated_on = _a.updated_on, published_on = _a.published_on, edited_by = _a.edited_by, thumbnail_url = _a.thumbnail_url, recaptcha = _a.recaptcha, published_url = _a.published_url;
17102
17111
  var _this = _super.call(this, { id: id, name: name, list_id: list_id, double_opt_in: double_opt_in }) || this;
17103
17112
  _this.enabled = enabled;
17104
17113
  _this.description = description;
@@ -17114,6 +17123,7 @@ var SummaryEnhancedFormModel = /** @class */ (function (_super) {
17114
17123
  _this.edited_by = edited_by;
17115
17124
  _this.thumbnail_url = thumbnail_url;
17116
17125
  _this.recaptcha = recaptcha;
17126
+ _this.published_url = published_url;
17117
17127
  return _this;
17118
17128
  }
17119
17129
  SummaryEnhancedFormModel.prototype.enable = function () {
@@ -17441,6 +17451,16 @@ var FormsFactory = /** @class */ (function () {
17441
17451
  });
17442
17452
  });
17443
17453
  };
17454
+ FormsFactory.renderPublic = function (_a) {
17455
+ return __awaiter(this, arguments, void 0, function (_b) {
17456
+ var id = _b.id, token = _b.token;
17457
+ return __generator(this, function (_c) {
17458
+ return [2 /*return*/, renderPublicHtmlForm({ id: id, token: token }).then(function (data) {
17459
+ return data;
17460
+ })];
17461
+ });
17462
+ });
17463
+ };
17444
17464
  return FormsFactory;
17445
17465
  }());
17446
17466
 
@@ -17937,6 +17957,7 @@ exports.removeQueryParams = removeQueryParams;
17937
17957
  exports.removeTrailingChar = removeTrailingChar;
17938
17958
  exports.renderCampaign = renderCampaign;
17939
17959
  exports.renderForm = renderForm;
17960
+ exports.renderPublicHtmlForm = renderPublicHtmlForm;
17940
17961
  exports.renderTemplate = renderTemplate;
17941
17962
  exports.requestSupportService = requestSupportService;
17942
17963
  exports.resumeCampaign = resumeCampaign;
@@ -44,16 +44,17 @@ export declare class SummaryEnhancedFormModel extends CommonFormModel {
44
44
  tags: string[] | null;
45
45
  post_redirect_url: string;
46
46
  double_opt_in_redirect_url: string;
47
- submission_url: string;
48
47
  async_processing: boolean;
49
48
  branding: string;
49
+ recaptcha: TEnhancedFormRecaptcha;
50
+ readonly submission_url: string;
50
51
  readonly created_on: number;
51
52
  readonly updated_on: number;
52
53
  readonly published_on: number;
53
54
  readonly edited_by: TEnhancedFormEditedBy;
54
55
  readonly thumbnail_url: string;
55
- recaptcha: TEnhancedFormRecaptcha;
56
- constructor({ id, list_id, enabled, name, description, tags, post_redirect_url, double_opt_in, double_opt_in_redirect_url, submission_url, async_processing, branding, created_on, updated_on, published_on, edited_by, thumbnail_url, recaptcha, }: TSummaryEnhancedFormModel);
56
+ readonly published_url: string;
57
+ constructor({ id, list_id, enabled, name, description, tags, post_redirect_url, double_opt_in, double_opt_in_redirect_url, submission_url, async_processing, branding, created_on, updated_on, published_on, edited_by, thumbnail_url, recaptcha, published_url }: TSummaryEnhancedFormModel);
57
58
  enable(): Promise<EnhancedFormModel>;
58
59
  disable(): Promise<EnhancedFormModel>;
59
60
  publish(): Promise<EnhancedFormModel>;
@@ -53,6 +53,7 @@ export interface TSummaryEnhancedFormModel {
53
53
  readonly edited_by: TEnhancedFormEditedBy;
54
54
  readonly thumbnail_url: string;
55
55
  recaptcha: TEnhancedFormRecaptcha;
56
+ published_url: string;
56
57
  }
57
58
  export interface TEnhancedFormModel extends TSummaryEnhancedFormModel {
58
59
  content: TEnhancedFormContent;
@@ -27,4 +27,8 @@ export declare function renderForm({ id, published }: {
27
27
  id: string;
28
28
  published: boolean;
29
29
  }): Promise<any>;
30
+ export declare function renderPublicHtmlForm({ id, token }: {
31
+ id: string;
32
+ token: string;
33
+ }): Promise<any>;
30
34
  export * from "./types";
@@ -8,5 +8,9 @@ export declare class FormsFactory {
8
8
  static create({ form }: {
9
9
  form: Partial<TEnhancedFormModel>;
10
10
  }): Promise<EnhancedFormModel>;
11
+ static renderPublic({ id, token }: {
12
+ id: string;
13
+ token: string;
14
+ }): Promise<string>;
11
15
  }
12
16
  export * from "./types";
package/dist/esm/index.js CHANGED
@@ -10154,6 +10154,15 @@ function renderForm(_a) {
10154
10154
  }
10155
10155
  });
10156
10156
  }
10157
+ function renderPublicHtmlForm(_a) {
10158
+ var id = _a.id, token = _a.token;
10159
+ return callApi({
10160
+ url: uiKitConfig.GATEWAY_PROXY + "/forms/" + id + "/render-html?token=" + token,
10161
+ fetchOptions: {
10162
+ method: EMethods.get
10163
+ }
10164
+ });
10165
+ }
10157
10166
 
10158
10167
  var EEditorType;
10159
10168
  (function (EEditorType) {
@@ -17078,7 +17087,7 @@ var FormModel = /** @class */ (function (_super) {
17078
17087
  var SummaryEnhancedFormModel = /** @class */ (function (_super) {
17079
17088
  __extends(SummaryEnhancedFormModel, _super);
17080
17089
  function SummaryEnhancedFormModel(_a) {
17081
- var id = _a.id, list_id = _a.list_id, enabled = _a.enabled, name = _a.name, description = _a.description, tags = _a.tags, post_redirect_url = _a.post_redirect_url, double_opt_in = _a.double_opt_in, double_opt_in_redirect_url = _a.double_opt_in_redirect_url, submission_url = _a.submission_url, async_processing = _a.async_processing, branding = _a.branding, created_on = _a.created_on, updated_on = _a.updated_on, published_on = _a.published_on, edited_by = _a.edited_by, thumbnail_url = _a.thumbnail_url, recaptcha = _a.recaptcha;
17090
+ var id = _a.id, list_id = _a.list_id, enabled = _a.enabled, name = _a.name, description = _a.description, tags = _a.tags, post_redirect_url = _a.post_redirect_url, double_opt_in = _a.double_opt_in, double_opt_in_redirect_url = _a.double_opt_in_redirect_url, submission_url = _a.submission_url, async_processing = _a.async_processing, branding = _a.branding, created_on = _a.created_on, updated_on = _a.updated_on, published_on = _a.published_on, edited_by = _a.edited_by, thumbnail_url = _a.thumbnail_url, recaptcha = _a.recaptcha, published_url = _a.published_url;
17082
17091
  var _this = _super.call(this, { id: id, name: name, list_id: list_id, double_opt_in: double_opt_in }) || this;
17083
17092
  _this.enabled = enabled;
17084
17093
  _this.description = description;
@@ -17094,6 +17103,7 @@ var SummaryEnhancedFormModel = /** @class */ (function (_super) {
17094
17103
  _this.edited_by = edited_by;
17095
17104
  _this.thumbnail_url = thumbnail_url;
17096
17105
  _this.recaptcha = recaptcha;
17106
+ _this.published_url = published_url;
17097
17107
  return _this;
17098
17108
  }
17099
17109
  SummaryEnhancedFormModel.prototype.enable = function () {
@@ -17421,6 +17431,16 @@ var FormsFactory = /** @class */ (function () {
17421
17431
  });
17422
17432
  });
17423
17433
  };
17434
+ FormsFactory.renderPublic = function (_a) {
17435
+ return __awaiter(this, arguments, void 0, function (_b) {
17436
+ var id = _b.id, token = _b.token;
17437
+ return __generator(this, function (_c) {
17438
+ return [2 /*return*/, renderPublicHtmlForm({ id: id, token: token }).then(function (data) {
17439
+ return data;
17440
+ })];
17441
+ });
17442
+ });
17443
+ };
17424
17444
  return FormsFactory;
17425
17445
  }());
17426
17446
 
@@ -17685,4 +17705,4 @@ var UsersFactory = /** @class */ (function () {
17685
17705
  return UsersFactory;
17686
17706
  }());
17687
17707
 
17688
- export { AccountModel, AccountsFactory, ActionBarContainer, ActionBarContainerHandler, AssetManager, AutomationsFactory, Avatar, BillingFactory, BrandWrapper, BrandsFactory, Button, ButtonMenu, CampaignModel, CampaignsFactory, Checkbox, Chip, CircularProgress, CodeInput, ColManager, ColorTextField, CommonFormModel, ContactModel, ContactsFactory, ContentSectionContainer, CopyToClipboard, CountryDropdown, CustomerModel, DataTable, DataTableHead, DataTableRow, DateCalendar, DatePicker, DateTimeCalendar, DateTimePicker, Dialog, DialogActions, DialogHandler, DialogTitle, Divider, Drawer, DrawerHandler, DropMenu, Dropdown, EApiLanguages, ECampaignStatuses, EEMailSummaryStatuses, EEditorType, EEmailAttachementTypes, EEmailLogType, EEmailLogTypeParam, EEmailProviders, EEmailSummaryEngagement, EEvents, EListAttributeType, EMethods, EOperatorTypes, EPartialInfoPool, EStorageType, ElementContains, Email, EmailAPIFactory, EmptyContent, EnhancedFormModel, FileUpload, FilterBar, FormModel, FormsFactory, FullBar, GenericWrapper, GenericWrapperContext, GroupedActions, Header, Icon, IconPill, InformationGroup, InlineTextEdit, LinearProgress, Link, ListCampaignModel, ListModel, ListTemplateModel, ListsFactory, LoadingContainer, LocationTextField, Logo, MD5, MetricCard, Modal, ModalHandler, ModalHeading, OverlayHandler, PhoneTextField, Radio, ResourceEdit, Search, SenderModel, SendersFactory, SideMenu, SideMenuContainer, SideMenuItem, SubNav, SummaryEnhancedFormModel, SupportFactory, SystemEmailsFactory, SystemEmailsModel, TemplateModel, TemplatesFactory, TextField, TimePicker, TimeSelector, Toggle, TopMenu, Typography, UserModel, UsersFactory, acceptListPolicy, addPartialInformation, addToImpersonificationTree, amIImpersonating, amILoggedInService, archiveCampaign, areAllPropertiesEmpty, buildMUITheme, callApi, camelCase, camelToSnakeCase, cancelCampaign, capitalizeFirstLetter, cleanPostHogId, clearImpersonificationTree, clearStorage, connectToZendeskSupportService, createAccount, createBrand, createCampaign, createCampaignLogsExports, createCampaignsReportsExport, createForm, createTemplate, deepMergeObject, deleteCampaign, deleteCampaignsReportsExport, deleteForm, deletePartialInformation, deleteStorageItem, deleteTemplate, descendingComparator, disableForm, downloadCampaignLogExport, downloadCampaignsReportsExport, emptyAccountAddress, emptyAccountLimits, enableForm, enrichBrand, enrichOrganization, enrichProfile, eventCondition, eventIdentify, eventLogout, fetchRetry, fetchRoute, findNestedProperty, formatNumber, getAccount, getAccountReport, getAdjustedBillingCycle, getBeeTokenService, getBestLocalMatch, getBrand, getBrandService, getBrandUrl, getCalendarFormat, getCampaign, getCampaignLinks, getCampaignLinksReport, getCampaignLogs, getCampaignLogsExports, getCampaignReport, getCampaignRevisions, getCampaignsReportsExport, getComparator, getCustomerProfile, getDate, getDomainFromEmail, getDomainsFromEmails, getDomainsService, getEmail, getEmailActivitySummary, getEmailReport, getEndOfDate, getForm, getHashQueryWithoutHistory, getIconSize, getList, getListLogs, getListReport, getNestedProperty, getPropertyValue, getSender, getStartOfDate, getStorage, getTColor, getTemplate, getUnixTime, getUrlQueryParam, getUser, getUtmCookies, googlePlacesMapper, hasDecimal, impersonateService, initFieldValidation, initPostHog, isColorLight, isDomainValidService, isSimpleType, isValidEmail, isValidString, isValidUrl, lisTEmailTags, listAccounts, listCampaigns, listCampaignsReportsExports, listContacts, listEmailLogs, listForms, listList, listListAttributes, listSenders, listSystemEmails, listTemplates, listUsers, logOutService, loginService, miliToSecond, modelSet, modelToJson, originalBrand, patchForm, popImpersonificationTree, postMessage, publishForm, reScheduleCampaign, removeEmptyProperties, removeQueryParams, removeTrailingChar, renderCampaign, renderForm, renderTemplate, requestSupportService, resumeCampaign, scheduleCampaign, searchCustomerProfiles, sendCampaignTest, setBrandHeadElements, setStorage, shareTemplate, splitArray, splitObject, stableSort, startPromisePool, suspendCampaign, trackEvent, truncateEmail, truncateText, uiKitConfig, unArchiveCampaign, unScheduleCampaign, unshareTemplate, updateAccount, updateAndClearUrlParams, updateCampaign, updateSystemEmails, updateTemplate, updateUser, validateColor, validateEmail, validateGenericInput, validateUrl, wait, whiteLabelBrand, whoAmi };
17708
+ export { AccountModel, AccountsFactory, ActionBarContainer, ActionBarContainerHandler, AssetManager, AutomationsFactory, Avatar, BillingFactory, BrandWrapper, BrandsFactory, Button, ButtonMenu, CampaignModel, CampaignsFactory, Checkbox, Chip, CircularProgress, CodeInput, ColManager, ColorTextField, CommonFormModel, ContactModel, ContactsFactory, ContentSectionContainer, CopyToClipboard, CountryDropdown, CustomerModel, DataTable, DataTableHead, DataTableRow, DateCalendar, DatePicker, DateTimeCalendar, DateTimePicker, Dialog, DialogActions, DialogHandler, DialogTitle, Divider, Drawer, DrawerHandler, DropMenu, Dropdown, EApiLanguages, ECampaignStatuses, EEMailSummaryStatuses, EEditorType, EEmailAttachementTypes, EEmailLogType, EEmailLogTypeParam, EEmailProviders, EEmailSummaryEngagement, EEvents, EListAttributeType, EMethods, EOperatorTypes, EPartialInfoPool, EStorageType, ElementContains, Email, EmailAPIFactory, EmptyContent, EnhancedFormModel, FileUpload, FilterBar, FormModel, FormsFactory, FullBar, GenericWrapper, GenericWrapperContext, GroupedActions, Header, Icon, IconPill, InformationGroup, InlineTextEdit, LinearProgress, Link, ListCampaignModel, ListModel, ListTemplateModel, ListsFactory, LoadingContainer, LocationTextField, Logo, MD5, MetricCard, Modal, ModalHandler, ModalHeading, OverlayHandler, PhoneTextField, Radio, ResourceEdit, Search, SenderModel, SendersFactory, SideMenu, SideMenuContainer, SideMenuItem, SubNav, SummaryEnhancedFormModel, SupportFactory, SystemEmailsFactory, SystemEmailsModel, TemplateModel, TemplatesFactory, TextField, TimePicker, TimeSelector, Toggle, TopMenu, Typography, UserModel, UsersFactory, acceptListPolicy, addPartialInformation, addToImpersonificationTree, amIImpersonating, amILoggedInService, archiveCampaign, areAllPropertiesEmpty, buildMUITheme, callApi, camelCase, camelToSnakeCase, cancelCampaign, capitalizeFirstLetter, cleanPostHogId, clearImpersonificationTree, clearStorage, connectToZendeskSupportService, createAccount, createBrand, createCampaign, createCampaignLogsExports, createCampaignsReportsExport, createForm, createTemplate, deepMergeObject, deleteCampaign, deleteCampaignsReportsExport, deleteForm, deletePartialInformation, deleteStorageItem, deleteTemplate, descendingComparator, disableForm, downloadCampaignLogExport, downloadCampaignsReportsExport, emptyAccountAddress, emptyAccountLimits, enableForm, enrichBrand, enrichOrganization, enrichProfile, eventCondition, eventIdentify, eventLogout, fetchRetry, fetchRoute, findNestedProperty, formatNumber, getAccount, getAccountReport, getAdjustedBillingCycle, getBeeTokenService, getBestLocalMatch, getBrand, getBrandService, getBrandUrl, getCalendarFormat, getCampaign, getCampaignLinks, getCampaignLinksReport, getCampaignLogs, getCampaignLogsExports, getCampaignReport, getCampaignRevisions, getCampaignsReportsExport, getComparator, getCustomerProfile, getDate, getDomainFromEmail, getDomainsFromEmails, getDomainsService, getEmail, getEmailActivitySummary, getEmailReport, getEndOfDate, getForm, getHashQueryWithoutHistory, getIconSize, getList, getListLogs, getListReport, getNestedProperty, getPropertyValue, getSender, getStartOfDate, getStorage, getTColor, getTemplate, getUnixTime, getUrlQueryParam, getUser, getUtmCookies, googlePlacesMapper, hasDecimal, impersonateService, initFieldValidation, initPostHog, isColorLight, isDomainValidService, isSimpleType, isValidEmail, isValidString, isValidUrl, lisTEmailTags, listAccounts, listCampaigns, listCampaignsReportsExports, listContacts, listEmailLogs, listForms, listList, listListAttributes, listSenders, listSystemEmails, listTemplates, listUsers, logOutService, loginService, miliToSecond, modelSet, modelToJson, originalBrand, patchForm, popImpersonificationTree, postMessage, publishForm, reScheduleCampaign, removeEmptyProperties, removeQueryParams, removeTrailingChar, renderCampaign, renderForm, renderPublicHtmlForm, renderTemplate, requestSupportService, resumeCampaign, scheduleCampaign, searchCustomerProfiles, sendCampaignTest, setBrandHeadElements, setStorage, shareTemplate, splitArray, splitObject, stableSort, startPromisePool, suspendCampaign, trackEvent, truncateEmail, truncateText, uiKitConfig, unArchiveCampaign, unScheduleCampaign, unshareTemplate, updateAccount, updateAndClearUrlParams, updateCampaign, updateSystemEmails, updateTemplate, updateUser, validateColor, validateEmail, validateGenericInput, validateUrl, wait, whiteLabelBrand, whoAmi };
@@ -44,16 +44,17 @@ export declare class SummaryEnhancedFormModel extends CommonFormModel {
44
44
  tags: string[] | null;
45
45
  post_redirect_url: string;
46
46
  double_opt_in_redirect_url: string;
47
- submission_url: string;
48
47
  async_processing: boolean;
49
48
  branding: string;
49
+ recaptcha: TEnhancedFormRecaptcha;
50
+ readonly submission_url: string;
50
51
  readonly created_on: number;
51
52
  readonly updated_on: number;
52
53
  readonly published_on: number;
53
54
  readonly edited_by: TEnhancedFormEditedBy;
54
55
  readonly thumbnail_url: string;
55
- recaptcha: TEnhancedFormRecaptcha;
56
- constructor({ id, list_id, enabled, name, description, tags, post_redirect_url, double_opt_in, double_opt_in_redirect_url, submission_url, async_processing, branding, created_on, updated_on, published_on, edited_by, thumbnail_url, recaptcha, }: TSummaryEnhancedFormModel);
56
+ readonly published_url: string;
57
+ constructor({ id, list_id, enabled, name, description, tags, post_redirect_url, double_opt_in, double_opt_in_redirect_url, submission_url, async_processing, branding, created_on, updated_on, published_on, edited_by, thumbnail_url, recaptcha, published_url }: TSummaryEnhancedFormModel);
57
58
  enable(): Promise<EnhancedFormModel>;
58
59
  disable(): Promise<EnhancedFormModel>;
59
60
  publish(): Promise<EnhancedFormModel>;
@@ -53,6 +53,7 @@ export interface TSummaryEnhancedFormModel {
53
53
  readonly edited_by: TEnhancedFormEditedBy;
54
54
  readonly thumbnail_url: string;
55
55
  recaptcha: TEnhancedFormRecaptcha;
56
+ published_url: string;
56
57
  }
57
58
  export interface TEnhancedFormModel extends TSummaryEnhancedFormModel {
58
59
  content: TEnhancedFormContent;
@@ -27,4 +27,8 @@ export declare function renderForm({ id, published }: {
27
27
  id: string;
28
28
  published: boolean;
29
29
  }): Promise<any>;
30
+ export declare function renderPublicHtmlForm({ id, token }: {
31
+ id: string;
32
+ token: string;
33
+ }): Promise<any>;
30
34
  export * from "./types";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cakemail-org/ui-components-v2",
3
- "version": "2.0.98",
3
+ "version": "2.0.99",
4
4
  "description": "ui library kit made with material UI",
5
5
  "main": "dist/cjs/index.js",
6
6
  "module": "dist/esm/index.js",