@bigbinary/neeto-playwright-commons 1.9.20 → 1.9.21

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 CHANGED
@@ -14470,13 +14470,13 @@ const NEETO_EDITOR_SELECTORS = {
14470
14470
  videoEmbedOption: "neeto-editor-fixed-menu-video-embed-option",
14471
14471
  videoEmbedInput: "neeto-editor-embed-input",
14472
14472
  videoEmbedSubmit: "neeto-editor-embed-cancel",
14473
- // TODO: Fix the selector after the issue is resolved: https://github.com/bigbinary/neeto-editor/issues/1047
14474
- videoWrapper: ".neeto-editor__video-wrapper",
14473
+ videoWrapper: "neeto-editor-video-wrapper",
14475
14474
  paragraphOption: "neeto-editor-fixed-menu-font-size-option-body2",
14476
14475
  attachmentPreview: "ne-attachments-wrapper",
14477
14476
  imageUploadLinkButton: "neeto-editor-media-uploader-link-tab",
14478
14477
  errorText: "neeto-editor-error-text",
14479
14478
  content: "editor-content",
14479
+ imageUploadDeleteButton: "neeto-editor-image-menu-Delete",
14480
14480
  };
14481
14481
  const NEETO_TEXT_MODIFIER_SELECTORS = {
14482
14482
  strikeOption: "neeto-editor-fixed-menu-strike-option",
@@ -14505,7 +14505,7 @@ const FONT_SIZE_SELECTORS = {
14505
14505
  /* eslint-disable playwright/no-nth-methods */
14506
14506
  class EditorPage {
14507
14507
  constructor(page, neetoPlaywrightUtilities) {
14508
- this.verifyDescriptionEditor = async ({ text, linkUrl = faker.faker.internet.url(), fileName = "../../../e2e/assets/images/BigBinary.png", imageUrl = "https://picsum.photos/200/300", videoUrl = "https://youtu.be/jNQXAC9IVRw", cannedResponseSuccessMessage, }) => {
14508
+ this.verifyDescriptionEditor = async ({ text, linkUrl = faker.faker.internet.url(), filePath = "../../../e2e/assets/images/BigBinary.png", imageUrl = "https://picsum.photos/200/300", videoUrl = "https://youtu.be/jNQXAC9IVRw", cannedResponseSuccessMessage, }) => {
14509
14509
  await this.page.getByTestId(NEETO_EDITOR_SELECTORS.contentField).fill(text);
14510
14510
  await this.page
14511
14511
  .getByTestId(NEETO_EDITOR_SELECTORS.fontSizeDropdown())
@@ -14586,7 +14586,7 @@ class EditorPage {
14586
14586
  const fileUploaderPromise = this.page.waitForEvent("filechooser");
14587
14587
  await this.editorAttachmentsButton.click();
14588
14588
  const fileUploader = await fileUploaderPromise;
14589
- const imagePath = Path__namespace.join(__dirname, fileName);
14589
+ const imagePath = Path__namespace.join(__dirname, filePath);
14590
14590
  await fileUploader.setFiles(imagePath);
14591
14591
  await this.neetoPlaywrightUtilities.interceptMultipleResponses({
14592
14592
  responseUrl: ROUTES.attachment,
@@ -14613,7 +14613,7 @@ class EditorPage {
14613
14613
  .getByTestId(NEETO_EDITOR_SELECTORS.imageUploadButton)
14614
14614
  .click();
14615
14615
  const fileUploader = await fileUploaderPromise;
14616
- const imagePath = Path__namespace.join(__dirname, fileName);
14616
+ const imagePath = Path__namespace.join(__dirname, filePath);
14617
14617
  await fileUploader.setFiles(imagePath);
14618
14618
  await test$1.expect(this.imageWrapper).toBeVisible({ timeout: 15000 });
14619
14619
  await this.neetoPlaywrightUtilities.verifySuccessToast();
@@ -14694,16 +14694,11 @@ class EditorPage {
14694
14694
  this.attachmentPreview = this.page.getByTestId(NEETO_EDITOR_SELECTORS.attachmentPreview);
14695
14695
  this.editorAttachmentsButton = this.page.getByTestId(NEETO_EDITOR_SELECTORS.editorAttachmentsButton);
14696
14696
  this.imageWrapper = this.page.getByTestId(NEETO_EDITOR_SELECTORS.imageWrapper);
14697
- // TODO: Fix the selector after the issue is resolved: https://github.com/bigbinary/neeto-editor/issues/1047
14698
- this.imageUploadDeleteButton = this.page
14699
- .getByTestId(COMMON_SELECTORS.dropdownContainer)
14700
- .getByRole("button")
14701
- .nth(3);
14697
+ this.imageUploadDeleteButton = this.page.getByTestId(NEETO_EDITOR_SELECTORS.imageUploadDeleteButton);
14702
14698
  this.imageUploadOption = this.page.getByTestId(NEETO_EDITOR_SELECTORS.imageUploadOption);
14703
14699
  this.cannedResponseOption = this.page.getByTestId(NEETO_EDITOR_SELECTORS.cannedResponseOption);
14704
14700
  this.videoEmbedOption = this.page.getByTestId(NEETO_EDITOR_SELECTORS.videoEmbedOption);
14705
- // TODO: Fix the selector after the issue is resolved: https://github.com/bigbinary/neeto-editor/issues/1047
14706
- this.videoWrapperSelector = this.page.locator(NEETO_EDITOR_SELECTORS.videoWrapper);
14701
+ this.videoWrapperSelector = this.page.getByTestId(NEETO_EDITOR_SELECTORS.videoWrapper);
14707
14702
  this.emojiDropdownIcon = this.page
14708
14703
  .getByTestId(NEETO_EDITOR_SELECTORS.fixedMenuWrapper)
14709
14704
  .getByTestId(COMMON_SELECTORS.dropdownIcon);