@bigbinary/neeto-playwright-commons 1.9.32 → 1.9.33
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/index.cjs.js +64 -31
- package/index.cjs.js.map +1 -1
- package/index.d.ts +22 -3
- package/index.js +65 -32
- package/index.js.map +1 -1
- package/package.json +1 -1
package/index.d.ts
CHANGED
|
@@ -1385,6 +1385,9 @@ declare class ZapierPage extends IntegrationBase {
|
|
|
1385
1385
|
}
|
|
1386
1386
|
interface VerifyDescriptionEditorParams {
|
|
1387
1387
|
text: string;
|
|
1388
|
+
editorWrapper?: Locator | Page;
|
|
1389
|
+
dynamicVariables?: string[];
|
|
1390
|
+
defaultFontSizeOption?: string;
|
|
1388
1391
|
linkUrl?: string;
|
|
1389
1392
|
filePath?: string;
|
|
1390
1393
|
attachedImageName?: string;
|
|
@@ -1406,6 +1409,7 @@ declare class EditorPage {
|
|
|
1406
1409
|
imageUploadOption: Locator;
|
|
1407
1410
|
cannedResponseOption: Locator;
|
|
1408
1411
|
videoEmbedOption: Locator;
|
|
1412
|
+
videoEmbedInput: Locator;
|
|
1409
1413
|
videoWrapperSelector: Locator;
|
|
1410
1414
|
emojiDropdownIcon: Locator;
|
|
1411
1415
|
constructor(page: Page, neetoPlaywrightUtilities: CustomCommands);
|
|
@@ -1415,6 +1419,12 @@ declare class EditorPage {
|
|
|
1415
1419
|
*
|
|
1416
1420
|
* text (required): The text to be filled in editor content field.
|
|
1417
1421
|
*
|
|
1422
|
+
* editorWrapper (optional): The wrapper of editor content field.
|
|
1423
|
+
*
|
|
1424
|
+
* dynamicVariables (optional): The array of dynamic variables used by the product in editor content field.
|
|
1425
|
+
*
|
|
1426
|
+
* defaultFontSizeOption (optional): The selected default font size of editor content field. Default is "Paragraph".
|
|
1427
|
+
*
|
|
1418
1428
|
* linkUrl (optional): The url to be added when we select the button on the editor menu to link a url to a text. Default is faker.internet.url().
|
|
1419
1429
|
*
|
|
1420
1430
|
* filePath (optional): The file path to be added when we select the button on the editor menu to attach a file in the editor. Default is "../../../e2e/assets/images/BigBinary.png".
|
|
@@ -1435,6 +1445,9 @@ declare class EditorPage {
|
|
|
1435
1445
|
*/
|
|
1436
1446
|
verifyDescriptionEditor: ({
|
|
1437
1447
|
text,
|
|
1448
|
+
editorWrapper,
|
|
1449
|
+
dynamicVariables,
|
|
1450
|
+
defaultFontSizeOption,
|
|
1438
1451
|
linkUrl,
|
|
1439
1452
|
filePath,
|
|
1440
1453
|
imageUrl,
|
|
@@ -3020,7 +3033,7 @@ declare const NEETO_EDITOR_SELECTORS: {
|
|
|
3020
3033
|
addLinkTextField: string;
|
|
3021
3034
|
addURLTextField: string;
|
|
3022
3035
|
submitLinkButton: string;
|
|
3023
|
-
fontSizeDropdown: (currentOption
|
|
3036
|
+
fontSizeDropdown: (currentOption: string) => string;
|
|
3024
3037
|
fixedMenuArrow: string;
|
|
3025
3038
|
cannedResponseOption: string;
|
|
3026
3039
|
cannedResponseSelectContainer: string;
|
|
@@ -3046,6 +3059,9 @@ declare const NEETO_EDITOR_SELECTORS: {
|
|
|
3046
3059
|
errorText: string;
|
|
3047
3060
|
content: string;
|
|
3048
3061
|
imageUploadDeleteButton: string;
|
|
3062
|
+
dynamicVariablesButton: string;
|
|
3063
|
+
emojiContainer: string;
|
|
3064
|
+
dynamicVariableSelector: (variable: string) => string;
|
|
3049
3065
|
};
|
|
3050
3066
|
declare const NEETO_TEXT_MODIFIER_SELECTORS: {
|
|
3051
3067
|
strikeOption: string;
|
|
@@ -4048,11 +4064,12 @@ declare const TOASTR_MESSAGES: {
|
|
|
4048
4064
|
*
|
|
4049
4065
|
*/
|
|
4050
4066
|
declare const ZAPIER_LIMIT_EXHAUSTED_MESSAGE = "Zapier free task limit is exhausted. Test will be aborted";
|
|
4051
|
-
declare const
|
|
4067
|
+
declare const EMOJI_LABEL = "thumbs up";
|
|
4052
4068
|
declare const ATTACHMENT_DELETION_TOASTR_MESSAGE = "Attachment has been successfully deleted.";
|
|
4053
4069
|
declare const DESCRIPTION_EDITOR_TEXTS: {
|
|
4054
4070
|
fontSize: string;
|
|
4055
4071
|
paragraph: string;
|
|
4072
|
+
normalText: string;
|
|
4056
4073
|
pasteLink: string;
|
|
4057
4074
|
invalidURLError: string;
|
|
4058
4075
|
pasteURL: string;
|
|
@@ -4061,6 +4078,8 @@ declare const DESCRIPTION_EDITOR_TEXTS: {
|
|
|
4061
4078
|
link: string;
|
|
4062
4079
|
cannedResponseHeader: string;
|
|
4063
4080
|
paragraphOption: string;
|
|
4081
|
+
search: string;
|
|
4082
|
+
emoji: string;
|
|
4064
4083
|
};
|
|
4065
4084
|
declare const EXPANDED_FONT_SIZE: {
|
|
4066
4085
|
h1: string;
|
|
@@ -4947,4 +4966,4 @@ interface Overrides {
|
|
|
4947
4966
|
* @endexample
|
|
4948
4967
|
*/
|
|
4949
4968
|
declare const definePlaywrightConfig: (overrides: Overrides) => _playwright_test.PlaywrightTestConfig<{}, {}>;
|
|
4950
|
-
export { API_ROUTES, ATTACHMENT_DELETION_TOASTR_MESSAGE, BASE_URL, CHANGELOG_WIDGET_SELECTORS, CHAT_WIDGET_SELECTORS, CHAT_WIDGET_TEXTS, COMMON_SELECTORS, CREDENTIALS, CustomCommands, type CustomFixture, DESCRIPTION_EDITOR_TEXTS, EMBED_SELECTORS,
|
|
4969
|
+
export { API_ROUTES, ATTACHMENT_DELETION_TOASTR_MESSAGE, BASE_URL, CHANGELOG_WIDGET_SELECTORS, CHAT_WIDGET_SELECTORS, CHAT_WIDGET_TEXTS, COMMON_SELECTORS, CREDENTIALS, CustomCommands, type CustomFixture, DESCRIPTION_EDITOR_TEXTS, EMBED_SELECTORS, EMOJI_LABEL, ENVIRONMENT, EXPANDED_FONT_SIZE, EditorPage, EmbedBase, FONT_SIZE_SELECTORS, GLOBAL_TRANSLATIONS_PATTERN, HELP_CENTER_SELECTORS, HelpAndProfilePage, INTEGRATIONS_TEXTS, INTEGRATION_SELECTORS, IS_STAGING_ENV, ImageUploader, IntegrationBase, KEYBOARD_SHORTCUTS_SELECTORS, LIST_MODIFIER_SELECTORS, LIST_MODIFIER_TAGS, LOGIN_SELECTORS, MEMBER_FORM_SELECTORS, MEMBER_SELECTORS, MEMBER_TEXTS, MERGE_TAGS_SELECTORS, MailosaurUtils, NEETO_AUTH_BASE_URL, NEETO_EDITOR_SELECTORS, NEETO_FILTERS_SELECTORS, NEETO_IMAGE_UPLOADER_SELECTORS, NEETO_ROUTES, NEETO_TEXT_MODIFIER_SELECTORS, OTP_EMAIL_PATTERN, OrganizationPage, PLURAL, PROFILE_SECTION_SELECTORS, PROJECT_TRANSLATIONS_PATH, ROLES_SELECTORS, ROUTES, SIGNUP_SELECTORS, SINGULAR, SLACK_DATA_QA_SELECTORS, SLACK_DEFAULT_CHANNEL, SLACK_SELECTORS, SLACK_WEB_TEXTS, STORAGE_STATE, SidebarSection, SlackPage, TAGS_SELECTORS, TEXT_MODIFIER_ROLES, TEXT_MODIFIER_SELECTORS, TEXT_MODIFIER_TAGS, THIRD_PARTY_ROUTES, TOASTR_MESSAGES, TagsPage, TeamMembers, USER_AGENTS, WebhooksPage, ZAPIER_LIMIT_EXHAUSTED_MESSAGE, ZAPIER_SELECTORS, ZAPIER_TEST_EMAIL, ZAPIER_WEB_TEXTS, ZapierPage, basicHTMLContent, clearCredentials, commands, cpuThrottlingUsingCDP, currencyUtils, decodeQRCodeFromFile, definePlaywrightConfig, executeWithThrottledResources, extractSubdomainFromError, filterUtils, generateRandomBypassEmail, generateStagingData, getByDataQA, getGlobalUserState, getImagePathAndName, getListCount, headerUtils, hexToRGB, hyphenize, i18nFixture, initializeCredentials, initializeTotp, joinHyphenCase, joinString, login, loginWithoutSSO, memberUtils, networkConditions, networkThrottlingUsingCDP, readFileSyncIfExists, removeCredentialFile, shouldSkipSetupAndTeardown, skipTest, squish, _default as stealthTest, tableUtils, toCamelCase, updateCredentials, writeDataToFile };
|
package/index.js
CHANGED
|
@@ -14,7 +14,7 @@ import require$$0$3 from 'os';
|
|
|
14
14
|
import Stream$4 from 'stream';
|
|
15
15
|
import require$$0$5 from 'events';
|
|
16
16
|
import { getI18nInstance, initI18n } from 'playwright-i18next-fixture';
|
|
17
|
-
import { isNotEmpty, humanize, isPresent, dynamicArray, isNotPresent } from '@bigbinary/neeto-cist';
|
|
17
|
+
import { isNotEmpty, humanize, hyphenate, isPresent, dynamicArray, isNotPresent } from '@bigbinary/neeto-cist';
|
|
18
18
|
import http$1 from 'http';
|
|
19
19
|
import Url from 'url';
|
|
20
20
|
import require$$0$6 from 'punycode';
|
|
@@ -13556,7 +13556,7 @@ const TOASTR_MESSAGES = {
|
|
|
13556
13556
|
zapierApiKeyGenerated: "Zapier API key is generated successfully!",
|
|
13557
13557
|
};
|
|
13558
13558
|
const ZAPIER_LIMIT_EXHAUSTED_MESSAGE = "Zapier free task limit is exhausted. Test will be aborted";
|
|
13559
|
-
const
|
|
13559
|
+
const EMOJI_LABEL = "thumbs up";
|
|
13560
13560
|
const ATTACHMENT_DELETION_TOASTR_MESSAGE = "Attachment has been successfully deleted.";
|
|
13561
13561
|
|
|
13562
13562
|
const HELP_CENTER_SELECTORS = {
|
|
@@ -14413,6 +14413,7 @@ class ZapierPage extends IntegrationBase {
|
|
|
14413
14413
|
const DESCRIPTION_EDITOR_TEXTS = {
|
|
14414
14414
|
fontSize: "Font size",
|
|
14415
14415
|
paragraph: "Paragraph",
|
|
14416
|
+
normalText: "Normal text",
|
|
14416
14417
|
pasteLink: "Paste the link here...",
|
|
14417
14418
|
invalidURLError: "Please enter a valid URL",
|
|
14418
14419
|
pasteURL: "Paste URL",
|
|
@@ -14421,6 +14422,8 @@ const DESCRIPTION_EDITOR_TEXTS = {
|
|
|
14421
14422
|
link: "Link",
|
|
14422
14423
|
cannedResponseHeader: "Canned responses",
|
|
14423
14424
|
paragraphOption: "paragraph",
|
|
14425
|
+
search: "Search",
|
|
14426
|
+
emoji: "Emoji",
|
|
14424
14427
|
};
|
|
14425
14428
|
const EXPANDED_FONT_SIZE = {
|
|
14426
14429
|
h1: "Heading 1",
|
|
@@ -14468,7 +14471,7 @@ const NEETO_EDITOR_SELECTORS = {
|
|
|
14468
14471
|
addLinkTextField: "neeto-editor-add-link-text-input",
|
|
14469
14472
|
addURLTextField: "neeto-editor-add-link-url-input",
|
|
14470
14473
|
submitLinkButton: "neeto-editor-add-link",
|
|
14471
|
-
fontSizeDropdown: (currentOption
|
|
14474
|
+
fontSizeDropdown: (currentOption) => `${joinHyphenCase(currentOption)}-dropdown-icon`,
|
|
14472
14475
|
fixedMenuArrow: "neeto-editor-fixed-menu-arrow",
|
|
14473
14476
|
cannedResponseOption: "neeto-editor-fixed-menu-canned-responses-option",
|
|
14474
14477
|
cannedResponseSelectContainer: "select-a-canned-response-select-container",
|
|
@@ -14494,6 +14497,9 @@ const NEETO_EDITOR_SELECTORS = {
|
|
|
14494
14497
|
errorText: "neeto-editor-error-text",
|
|
14495
14498
|
content: "editor-content",
|
|
14496
14499
|
imageUploadDeleteButton: "neeto-editor-image-menu-Delete",
|
|
14500
|
+
dynamicVariablesButton: "dynamic-variables-button",
|
|
14501
|
+
emojiContainer: "neeto-editor-emoji-picker",
|
|
14502
|
+
dynamicVariableSelector: (variable) => `dynamic-variables-list-item-${hyphenate(variable)}`,
|
|
14497
14503
|
};
|
|
14498
14504
|
const NEETO_TEXT_MODIFIER_SELECTORS = {
|
|
14499
14505
|
strikeOption: "neeto-editor-fixed-menu-strike-option",
|
|
@@ -14504,7 +14510,7 @@ const TEXT_MODIFIER_SELECTORS = {
|
|
|
14504
14510
|
boldOption: "neeto-editor-fixed-menu-bold-option",
|
|
14505
14511
|
italicsOption: "neeto-editor-fixed-menu-italic-option",
|
|
14506
14512
|
codeOption: "neeto-editor-fixed-menu-code-option",
|
|
14507
|
-
blockquoteOption: "neeto-editor-fixed-menu-
|
|
14513
|
+
blockquoteOption: "neeto-editor-fixed-menu-blockquote-option",
|
|
14508
14514
|
codeblockOption: "neeto-editor-fixed-menu-code-block-option",
|
|
14509
14515
|
};
|
|
14510
14516
|
const LIST_MODIFIER_SELECTORS = {
|
|
@@ -14522,40 +14528,44 @@ const FONT_SIZE_SELECTORS = {
|
|
|
14522
14528
|
/* eslint-disable playwright/no-nth-methods */
|
|
14523
14529
|
class EditorPage {
|
|
14524
14530
|
constructor(page, neetoPlaywrightUtilities) {
|
|
14525
|
-
this.verifyDescriptionEditor = async ({ text, linkUrl = faker.internet.url(), filePath = "../../../e2e/assets/images/BigBinary.png", imageUrl = "https://picsum.photos/200/300", videoUrl = "https://youtu.be/jNQXAC9IVRw", cannedResponseSuccessMessage, }) => {
|
|
14526
|
-
|
|
14527
|
-
|
|
14528
|
-
|
|
14531
|
+
this.verifyDescriptionEditor = async ({ text, editorWrapper, dynamicVariables, defaultFontSizeOption = "Paragraph", linkUrl = faker.internet.url(), filePath = "../../../e2e/assets/images/BigBinary.png", imageUrl = "https://picsum.photos/200/300", videoUrl = "https://youtu.be/jNQXAC9IVRw", cannedResponseSuccessMessage, }) => {
|
|
14532
|
+
if (!editorWrapper)
|
|
14533
|
+
editorWrapper = this.page;
|
|
14534
|
+
await editorWrapper
|
|
14535
|
+
.getByTestId(NEETO_EDITOR_SELECTORS.contentField)
|
|
14536
|
+
.fill(text);
|
|
14537
|
+
await editorWrapper
|
|
14538
|
+
.getByTestId(NEETO_EDITOR_SELECTORS.fontSizeDropdown(defaultFontSizeOption))
|
|
14529
14539
|
.click();
|
|
14530
14540
|
const fontSize = Object.keys(FONT_SIZE_SELECTORS);
|
|
14531
14541
|
for (const font of fontSize) {
|
|
14532
14542
|
const fontKey = font;
|
|
14533
|
-
await
|
|
14534
|
-
await expect(
|
|
14543
|
+
await editorWrapper.getByTestId(FONT_SIZE_SELECTORS[fontKey]).click();
|
|
14544
|
+
await expect(editorWrapper
|
|
14535
14545
|
.getByTestId(NEETO_EDITOR_SELECTORS.contentField)
|
|
14536
14546
|
.getByRole("heading", { level: Number(font.slice(1)) })).toBeVisible();
|
|
14537
|
-
await
|
|
14547
|
+
await editorWrapper
|
|
14538
14548
|
.getByTestId(NEETO_EDITOR_SELECTORS.fontSizeDropdown(EXPANDED_FONT_SIZE[fontKey]))
|
|
14539
14549
|
.click();
|
|
14540
14550
|
}
|
|
14541
14551
|
if (await this.paragraphSelector.isVisible()) {
|
|
14542
14552
|
await this.paragraphSelector.click();
|
|
14543
14553
|
const paragraphRole = DESCRIPTION_EDITOR_TEXTS.paragraphOption;
|
|
14544
|
-
await expect(
|
|
14554
|
+
await expect(editorWrapper
|
|
14545
14555
|
.getByTestId(NEETO_EDITOR_SELECTORS.contentField)
|
|
14546
14556
|
.getByRole(paragraphRole)).toBeVisible();
|
|
14547
14557
|
}
|
|
14548
14558
|
(await this.fixedMenuArrowSelector.isVisible()) &&
|
|
14549
14559
|
(await this.fixedMenuArrowSelector.click());
|
|
14550
|
-
await
|
|
14560
|
+
await editorWrapper.getByText(text).click({ clickCount: 3 });
|
|
14551
14561
|
const textModifier = Object.keys(TEXT_MODIFIER_SELECTORS);
|
|
14552
14562
|
for (const modifier of textModifier) {
|
|
14553
14563
|
const modifierKey = modifier;
|
|
14554
14564
|
const textModifierRole = TEXT_MODIFIER_ROLES[modifierKey];
|
|
14555
|
-
const textModifierSelector =
|
|
14565
|
+
const textModifierSelector = editorWrapper.getByTestId(TEXT_MODIFIER_SELECTORS[modifierKey]);
|
|
14556
14566
|
if (await textModifierSelector.isVisible()) {
|
|
14557
14567
|
await textModifierSelector.click();
|
|
14558
|
-
await expect(
|
|
14568
|
+
await expect(editorWrapper
|
|
14559
14569
|
.getByTestId(NEETO_EDITOR_SELECTORS.contentField)
|
|
14560
14570
|
.getByRole(textModifierRole)).toBeVisible();
|
|
14561
14571
|
await textModifierSelector.click();
|
|
@@ -14564,10 +14574,10 @@ class EditorPage {
|
|
|
14564
14574
|
const textDeskModifier = Object.keys(NEETO_TEXT_MODIFIER_SELECTORS);
|
|
14565
14575
|
for (const modifier of textDeskModifier) {
|
|
14566
14576
|
const modifierKey = modifier;
|
|
14567
|
-
const textModifierSelector =
|
|
14577
|
+
const textModifierSelector = editorWrapper.getByTestId(NEETO_TEXT_MODIFIER_SELECTORS[modifierKey]);
|
|
14568
14578
|
if (await textModifierSelector.isVisible()) {
|
|
14569
14579
|
await textModifierSelector.click();
|
|
14570
|
-
await expect(
|
|
14580
|
+
await expect(editorWrapper
|
|
14571
14581
|
.getByTestId(NEETO_EDITOR_SELECTORS.contentField)
|
|
14572
14582
|
.locator(TEXT_MODIFIER_TAGS[modifierKey])).toBeVisible();
|
|
14573
14583
|
await textModifierSelector.click();
|
|
@@ -14576,10 +14586,10 @@ class EditorPage {
|
|
|
14576
14586
|
const listModifier = Object.keys(LIST_MODIFIER_SELECTORS);
|
|
14577
14587
|
for (const modifier of listModifier) {
|
|
14578
14588
|
const modifierKey = modifier;
|
|
14579
|
-
const listModifierSelector =
|
|
14589
|
+
const listModifierSelector = editorWrapper.getByTestId(LIST_MODIFIER_SELECTORS[modifierKey]);
|
|
14580
14590
|
if (await listModifierSelector.isVisible()) {
|
|
14581
14591
|
await listModifierSelector.click();
|
|
14582
|
-
await expect(
|
|
14592
|
+
await expect(editorWrapper
|
|
14583
14593
|
.getByTestId(NEETO_EDITOR_SELECTORS.contentField)
|
|
14584
14594
|
.locator(LIST_MODIFIER_TAGS[modifierKey])).toBeVisible();
|
|
14585
14595
|
await listModifierSelector.click();
|
|
@@ -14594,7 +14604,7 @@ class EditorPage {
|
|
|
14594
14604
|
.getByTestId(NEETO_EDITOR_SELECTORS.addLinkDoneButton)
|
|
14595
14605
|
.click();
|
|
14596
14606
|
const linkRole = DESCRIPTION_EDITOR_TEXTS.link;
|
|
14597
|
-
await expect(
|
|
14607
|
+
await expect(editorWrapper
|
|
14598
14608
|
.getByTestId(NEETO_EDITOR_SELECTORS.contentField)
|
|
14599
14609
|
.getByRole(linkRole)).toBeVisible();
|
|
14600
14610
|
await this.page.getByTestId(NEETO_EDITOR_SELECTORS.unlinkButton).click();
|
|
@@ -14619,10 +14629,10 @@ class EditorPage {
|
|
|
14619
14629
|
await this.page
|
|
14620
14630
|
.getByTestId(COMMON_SELECTORS.alertModalSubmitButton)
|
|
14621
14631
|
.click();
|
|
14632
|
+
await this.neetoPlaywrightUtilities.verifyToast({
|
|
14633
|
+
message: ATTACHMENT_DELETION_TOASTR_MESSAGE,
|
|
14634
|
+
});
|
|
14622
14635
|
}
|
|
14623
|
-
await this.neetoPlaywrightUtilities.verifyToast({
|
|
14624
|
-
message: ATTACHMENT_DELETION_TOASTR_MESSAGE,
|
|
14625
|
-
});
|
|
14626
14636
|
if (await this.imageUploadOption.isVisible()) {
|
|
14627
14637
|
await this.imageUploadOption.click();
|
|
14628
14638
|
const fileUploaderPromise = this.page.waitForEvent("filechooser");
|
|
@@ -14633,7 +14643,6 @@ class EditorPage {
|
|
|
14633
14643
|
const imagePath = Path.join(__dirname, filePath);
|
|
14634
14644
|
await fileUploader.setFiles(imagePath);
|
|
14635
14645
|
await expect(this.imageWrapper).toBeVisible({ timeout: 15000 });
|
|
14636
|
-
await this.neetoPlaywrightUtilities.verifyToast();
|
|
14637
14646
|
await this.imageWrapper
|
|
14638
14647
|
.getByTestId(COMMON_SELECTORS.dropdownIcon)
|
|
14639
14648
|
.click();
|
|
@@ -14674,11 +14683,11 @@ class EditorPage {
|
|
|
14674
14683
|
message: cannedResponseSuccessMessage,
|
|
14675
14684
|
});
|
|
14676
14685
|
}
|
|
14677
|
-
if (await
|
|
14686
|
+
if (await editorWrapper
|
|
14678
14687
|
.getByTestId(NEETO_EDITOR_SELECTORS.videoEmbedOption)
|
|
14679
14688
|
.isVisible()) {
|
|
14680
14689
|
await this.videoEmbedOption.click();
|
|
14681
|
-
await this.
|
|
14690
|
+
await this.videoEmbedInput.fill(videoUrl);
|
|
14682
14691
|
await this.page
|
|
14683
14692
|
.getByTestId(NEETO_EDITOR_SELECTORS.videoEmbedSubmit)
|
|
14684
14693
|
.click();
|
|
@@ -14694,12 +14703,35 @@ class EditorPage {
|
|
|
14694
14703
|
if (await this.emojiDropdownIcon.isVisible()) {
|
|
14695
14704
|
await this.emojiDropdownIcon.click();
|
|
14696
14705
|
await this.page
|
|
14697
|
-
.getByRole("
|
|
14698
|
-
name: EMOJI_PICKER_LABEL,
|
|
14699
|
-
})
|
|
14700
|
-
.getByText("👍")
|
|
14706
|
+
.getByRole("button", { name: DESCRIPTION_EDITOR_TEXTS.emoji })
|
|
14701
14707
|
.click();
|
|
14702
|
-
await expect(this.page.getByTestId(NEETO_EDITOR_SELECTORS.
|
|
14708
|
+
await expect(this.page.getByTestId(NEETO_EDITOR_SELECTORS.emojiContainer)).toBeVisible({
|
|
14709
|
+
timeout: 10000,
|
|
14710
|
+
});
|
|
14711
|
+
await this.page
|
|
14712
|
+
.getByTestId(NEETO_EDITOR_SELECTORS.emojiContainer)
|
|
14713
|
+
.getByPlaceholder(DESCRIPTION_EDITOR_TEXTS.search)
|
|
14714
|
+
.fill(EMOJI_LABEL);
|
|
14715
|
+
await this.page.keyboard.press("Enter");
|
|
14716
|
+
await expect(editorWrapper.getByTestId(NEETO_EDITOR_SELECTORS.contentField)).toContainText("👍");
|
|
14717
|
+
await this.page.keyboard.press("Escape");
|
|
14718
|
+
}
|
|
14719
|
+
if (dynamicVariables &&
|
|
14720
|
+
(await editorWrapper
|
|
14721
|
+
.getByTestId(NEETO_EDITOR_SELECTORS.dynamicVariablesButton)
|
|
14722
|
+
.isVisible())) {
|
|
14723
|
+
for (const dynamicVariable of dynamicVariables) {
|
|
14724
|
+
await editorWrapper
|
|
14725
|
+
.getByTestId(NEETO_EDITOR_SELECTORS.dynamicVariablesButton)
|
|
14726
|
+
.click();
|
|
14727
|
+
await expect(this.page.getByTestId(COMMON_SELECTORS.dropdownContainer)).toBeVisible();
|
|
14728
|
+
await this.page
|
|
14729
|
+
.getByTestId(NEETO_EDITOR_SELECTORS.dynamicVariableSelector(dynamicVariable))
|
|
14730
|
+
.click();
|
|
14731
|
+
await expect(editorWrapper
|
|
14732
|
+
.getByTestId(NEETO_EDITOR_SELECTORS.contentField)
|
|
14733
|
+
.getByText(dynamicVariable)).toBeVisible();
|
|
14734
|
+
}
|
|
14703
14735
|
}
|
|
14704
14736
|
};
|
|
14705
14737
|
this.page = page;
|
|
@@ -14715,6 +14747,7 @@ class EditorPage {
|
|
|
14715
14747
|
this.imageUploadOption = this.page.getByTestId(NEETO_EDITOR_SELECTORS.imageUploadOption);
|
|
14716
14748
|
this.cannedResponseOption = this.page.getByTestId(NEETO_EDITOR_SELECTORS.cannedResponseOption);
|
|
14717
14749
|
this.videoEmbedOption = this.page.getByTestId(NEETO_EDITOR_SELECTORS.videoEmbedOption);
|
|
14750
|
+
this.videoEmbedInput = this.page.getByTestId(NEETO_EDITOR_SELECTORS.videoEmbedInput);
|
|
14718
14751
|
this.videoWrapperSelector = this.page.getByTestId(NEETO_EDITOR_SELECTORS.videoWrapper);
|
|
14719
14752
|
this.emojiDropdownIcon = this.page
|
|
14720
14753
|
.getByTestId(NEETO_EDITOR_SELECTORS.fixedMenuWrapper)
|
|
@@ -149243,5 +149276,5 @@ const definePlaywrightConfig = (overrides) => {
|
|
|
149243
149276
|
});
|
|
149244
149277
|
};
|
|
149245
149278
|
|
|
149246
|
-
export { API_ROUTES, ATTACHMENT_DELETION_TOASTR_MESSAGE, BASE_URL, CHANGELOG_WIDGET_SELECTORS, CHAT_WIDGET_SELECTORS, CHAT_WIDGET_TEXTS, COMMON_SELECTORS, CREDENTIALS, CustomCommands, DESCRIPTION_EDITOR_TEXTS, EMBED_SELECTORS,
|
|
149279
|
+
export { API_ROUTES, ATTACHMENT_DELETION_TOASTR_MESSAGE, BASE_URL, CHANGELOG_WIDGET_SELECTORS, CHAT_WIDGET_SELECTORS, CHAT_WIDGET_TEXTS, COMMON_SELECTORS, CREDENTIALS, CustomCommands, DESCRIPTION_EDITOR_TEXTS, EMBED_SELECTORS, EMOJI_LABEL, ENVIRONMENT, EXPANDED_FONT_SIZE, EditorPage, EmbedBase, FONT_SIZE_SELECTORS, GLOBAL_TRANSLATIONS_PATTERN, HELP_CENTER_SELECTORS, HelpAndProfilePage, INTEGRATIONS_TEXTS, INTEGRATION_SELECTORS, IS_STAGING_ENV, ImageUploader, IntegrationBase, KEYBOARD_SHORTCUTS_SELECTORS, LIST_MODIFIER_SELECTORS, LIST_MODIFIER_TAGS, LOGIN_SELECTORS, MEMBER_FORM_SELECTORS, MEMBER_SELECTORS, MEMBER_TEXTS, MERGE_TAGS_SELECTORS, MailosaurUtils, NEETO_AUTH_BASE_URL, NEETO_EDITOR_SELECTORS, NEETO_FILTERS_SELECTORS, NEETO_IMAGE_UPLOADER_SELECTORS, NEETO_ROUTES, NEETO_TEXT_MODIFIER_SELECTORS, OTP_EMAIL_PATTERN, OrganizationPage, PLURAL, PROFILE_SECTION_SELECTORS, PROJECT_TRANSLATIONS_PATH, ROLES_SELECTORS, ROUTES, SIGNUP_SELECTORS, SINGULAR, SLACK_DATA_QA_SELECTORS, SLACK_DEFAULT_CHANNEL, SLACK_SELECTORS, SLACK_WEB_TEXTS, STORAGE_STATE, SidebarSection, SlackPage, TAGS_SELECTORS, TEXT_MODIFIER_ROLES, TEXT_MODIFIER_SELECTORS, TEXT_MODIFIER_TAGS, THIRD_PARTY_ROUTES, TOASTR_MESSAGES, TagsPage, TeamMembers, USER_AGENTS, WebhooksPage, ZAPIER_LIMIT_EXHAUSTED_MESSAGE, ZAPIER_SELECTORS, ZAPIER_TEST_EMAIL, ZAPIER_WEB_TEXTS, ZapierPage, basicHTMLContent, clearCredentials, commands, cpuThrottlingUsingCDP, currencyUtils, decodeQRCodeFromFile, definePlaywrightConfig, executeWithThrottledResources, extractSubdomainFromError, filterUtils, generateRandomBypassEmail, generateStagingData, getByDataQA, getGlobalUserState, getImagePathAndName, getListCount, headerUtils, hexToRGB, hyphenize, i18nFixture, initializeCredentials, initializeTotp, joinHyphenCase, joinString, login, loginWithoutSSO, memberUtils, networkConditions, networkThrottlingUsingCDP, readFileSyncIfExists, removeCredentialFile, shouldSkipSetupAndTeardown, skipTest, squish, stealth as stealthTest, tableUtils, toCamelCase, updateCredentials, writeDataToFile };
|
|
149247
149280
|
//# sourceMappingURL=index.js.map
|