diff --git a/e2e/playwright/README.md b/e2e/playwright/README.md index ed1ae7428830..09db82ff3810 100644 --- a/e2e/playwright/README.md +++ b/e2e/playwright/README.md @@ -259,6 +259,15 @@ test folders migrated under this rule (see `eslint.config.mjs`) may not use `wai `setTimeout`, `force: true`, `toPass`, a `timeout` option or a call that raises a timeout (`test.setTimeout`, `page.setDefaultTimeout`). +**Animations.** `show()` of an overlay returns a promise that resolves when the show animation ends, +and both runners wait for it, so `await popup.show()` needs nothing after it. A widget created +visible with animations on returns nothing to wait for: count its `onShown` calls on `window` and +wait for the count with `page.waitForFunction`. + +**Images.** `toHaveScreenshot` compares the first picture that stays the same over two shots, and an +image that is still loading can stay the same. Before such a shot, wait until every `img` in it is +`complete`. + **Clicks.** A click is a real one: it lands on the topmost element at that point and fails when that is not the target. TestCafe delivered a click to a covered element anyway, so a test that relied on it needs the target made reachable, not the check switched off. diff --git a/e2e/playwright/models/chat.ts b/e2e/playwright/models/chat.ts new file mode 100644 index 000000000000..315264c946a1 --- /dev/null +++ b/e2e/playwright/models/chat.ts @@ -0,0 +1,49 @@ +import type { Locator, Page } from '@playwright/test'; +import type { WidgetName } from './types'; +import Widget from './internal/widget'; +import Scrollable from './scrollable'; +import TextArea from './textArea'; + +const CLASS = { + messageList: 'dx-chat-messagelist', + textArea: 'dx-textarea', + scrollable: 'dx-scrollable', + messageBubble: 'dx-chat-messagebubble', + contextMenuContent: 'dx-messagelist-context-menu-content', + menuItem: 'dx-menu-item', +}; + +export default class Chat extends Widget { + public readonly messageList: Locator; + + constructor(page: Page, selector: Locator | string) { + super(page, selector); + + this.messageList = this.element.locator(`.${CLASS.messageList}`); + } + + // eslint-disable-next-line class-methods-use-this + public getName(): WidgetName { return 'dxChat'; } + + public getTextArea(): TextArea { + return new TextArea(this.page, this.element.locator(`.${CLASS.textArea}`)); + } + + public getInput(): Locator { + return this.getTextArea().input; + } + + public getScrollable(): Scrollable { + return new Scrollable(this.page, this.element.locator(`.${CLASS.scrollable}`)); + } + + public getMessage(index: number): Locator { + return this.element.locator(`.${CLASS.messageBubble}`).nth(index); + } + + public getContextMenuItem(index: number): Locator { + return this.element + .locator(`.${CLASS.contextMenuContent} .${CLASS.menuItem}`) + .nth(index); + } +} diff --git a/packages/testcafe-models/popover.ts b/e2e/playwright/models/popover.ts similarity index 75% rename from packages/testcafe-models/popover.ts rename to e2e/playwright/models/popover.ts index 0772f7fb9826..86b07c570022 100644 --- a/packages/testcafe-models/popover.ts +++ b/e2e/playwright/models/popover.ts @@ -3,5 +3,5 @@ import Popup from './popup'; export default class Popover extends Popup { // eslint-disable-next-line class-methods-use-this - getName(): WidgetName { return 'dxPopover'; } + public getName(): WidgetName { return 'dxPopover'; } } diff --git a/e2e/playwright/models/popup.ts b/e2e/playwright/models/popup.ts index 9502b9995316..a193b1c76fba 100644 --- a/e2e/playwright/models/popup.ts +++ b/e2e/playwright/models/popup.ts @@ -10,6 +10,7 @@ const CLASS = { closeButton: 'dx-closebutton', doneButton: 'dx-popup-done', cancelButton: 'dx-popup-cancel', + overflowButton: 'dx-dropdownmenu-button', }; export default class Popup extends Overlay { @@ -30,6 +31,10 @@ export default class Popup extends Overlay { return new Button(this.page, this.getWrapper().locator(`.${CLASS.button}`).nth(index)); } + public getOverflowButton(): Button { + return new Button(this.page, this.getWrapper().locator(`.${CLASS.overflowButton}`).first()); + } + public getCloseButton(): Button { return new Button(this.page, this.getWrapper().locator(`.${CLASS.closeButton}`)); } diff --git a/e2e/playwright/models/scrollable.ts b/e2e/playwright/models/scrollable.ts new file mode 100644 index 000000000000..3bb41e7e7bf0 --- /dev/null +++ b/e2e/playwright/models/scrollable.ts @@ -0,0 +1,20 @@ +import type { WidgetName } from './types'; +import Widget from './internal/widget'; + +export interface ScrollOffset { + top: number; + left: number; +} + +export default class Scrollable extends Widget { + // eslint-disable-next-line class-methods-use-this + public getName(): WidgetName { return 'dxScrollable'; } + + public scrollOffset(): Promise { + return this.invoke('scrollOffset'); + } + + public async scrollTo(value: Partial): Promise { + await this.invoke('scrollTo', value); + } +} diff --git a/e2e/playwright/models/tabPanel.ts b/e2e/playwright/models/tabPanel.ts new file mode 100644 index 000000000000..9e9f3039b418 --- /dev/null +++ b/e2e/playwright/models/tabPanel.ts @@ -0,0 +1,16 @@ +import type { Locator } from '@playwright/test'; +import type { WidgetName } from './types'; +import Widget from './internal/widget'; + +const CLASS = { + tab: 'dx-tab', +}; + +export default class TabPanel extends Widget { + // eslint-disable-next-line class-methods-use-this + public getName(): WidgetName { return 'dxTabPanel'; } + + public getTab(index = 0): Locator { + return this.element.locator(`.${CLASS.tab}`).nth(index); + } +} diff --git a/e2e/playwright/models/toolbar.ts b/e2e/playwright/models/toolbar.ts new file mode 100644 index 000000000000..60805db8126c --- /dev/null +++ b/e2e/playwright/models/toolbar.ts @@ -0,0 +1,7 @@ +import type { WidgetName } from './types'; +import Widget from './internal/widget'; + +export default class Toolbar extends Widget { + // eslint-disable-next-line class-methods-use-this + public getName(): WidgetName { return 'dxToolbar'; } +} diff --git a/e2e/playwright/tests/editors/chat/alertList.spec.ts b/e2e/playwright/tests/editors/chat/alertList.spec.ts new file mode 100644 index 000000000000..3efd664ed882 --- /dev/null +++ b/e2e/playwright/tests/editors/chat/alertList.spec.ts @@ -0,0 +1,60 @@ +import { test } from '../../../fixtures'; +import { createWidget } from '../../../helpers/createWidget'; +import { mockDate } from '../../../helpers/mockDate'; +import { testScreenshot } from '../../../helpers/screenshots'; +import Chat from '../../../models/chat'; +import { createUser } from './data'; + +test.describe('ChatAlertList', () => { + test('Alertlist appearance', async ({ page }) => { + await mockDate(page, '2024/10/18'); + + const userFirst = createUser(1, 'First'); + const userSecond = createUser(2, 'Second'); + const msInDay = 86400000; + const today = new Date('2024/10/18').setHours(7, 22, 0, 0); + const yesterday = today - msInDay; + + const items = [{ + timestamp: yesterday, + author: userSecond, + text: 'Message text 1', + }, { + timestamp: yesterday, + author: userSecond, + text: 'Message text 2', + }, { + timestamp: today, + author: userFirst, + text: 'Message text 3', + }, { + timestamp: today, + author: userFirst, + text: 'Message text 4', + }]; + + await createWidget(page, 'dxChat', { + items, + user: userFirst, + width: 400, + height: 600, + alerts: [{ id: 1, message: 'Error Message 1. Error Description...' }], + }); + + const chat = new Chat(page, '#container'); + + await testScreenshot(page, 'Alertlist with one error.png', { element: '#container' }); + + await chat.option('alerts', [ + { id: 1, message: 'Error Message 1. Error Description...' }, + { id: 2, message: 'Error Message 2. Message was not sent' }, + { id: 3, message: 'Error Message 3. An unexpected issue occurred while processing your request. Please check your internet connection or contact support for further assistance.' }, + ]); + + await testScreenshot(page, 'Alertlist with long text in error.png', { element: '#container' }); + + await chat.option('rtlEnabled', true); + + await testScreenshot(page, 'Alertlist appearance in RTL mode.png', { element: '#container' }); + }); +}); diff --git a/e2e/playwright/tests/editors/chat/avatar.spec.ts b/e2e/playwright/tests/editors/chat/avatar.spec.ts new file mode 100644 index 000000000000..83f297d0ed10 --- /dev/null +++ b/e2e/playwright/tests/editors/chat/avatar.spec.ts @@ -0,0 +1,56 @@ +import { test } from '../../../fixtures'; +import { createWidget } from '../../../helpers/createWidget'; +import { appendElementTo } from '../../../helpers/domUtils'; +import { testScreenshot } from '../../../helpers/screenshots'; +import Chat from '../../../models/chat'; +import { avatarUrl, createUser, generateMessages } from './data'; +import { expectImagesLoaded } from './utils'; + +test.describe('ChatAvatar', () => { + test('Chat: avatar', async ({ page }) => { + await appendElementTo(page, '#container', 'div', 'chat'); + + const initialsUserFirst = createUser(1, 'First User'); + const initialsUserSecond = createUser(2, 'Second User'); + + await createWidget(page, 'dxChat', { + width: 400, + height: 600, + user: initialsUserSecond, + items: generateMessages(2, initialsUserFirst, initialsUserSecond, false, false, 2), + }, '#chat'); + + await testScreenshot(page, 'Avatar with two word initials.png', { element: '#chat' }); + + const chat = new Chat(page, '#chat'); + + const userFirst = createUser(1, 'First', avatarUrl); + const userSecond = createUser(2, 'Second', avatarUrl); + + const items = generateMessages(2, userFirst, userSecond, false, false, 2); + + await chat.option('items', items); + await expectImagesLoaded(chat.element, 1); + + await testScreenshot(page, 'Avatar with image.png', { element: '#chat' }); + }); + + test('Chat: showAvatar set to false', async ({ page }) => { + await appendElementTo(page, '#container', 'div', 'chat'); + + const userFirst = createUser(1, 'First User'); + const userSecond = createUser(2, 'Second User'); + + const items = generateMessages(2, userFirst, userSecond, false, false, 2); + + await createWidget(page, 'dxChat', { + width: 400, + height: 600, + user: userSecond, + items, + showAvatar: false, + }, '#chat'); + + await testScreenshot(page, 'Avatar with showAvatar set to false.png', { element: '#chat' }); + }); +}); diff --git a/e2e/playwright/tests/editors/chat/confirmationPopup.spec.ts b/e2e/playwright/tests/editors/chat/confirmationPopup.spec.ts new file mode 100644 index 000000000000..8a1badfe383f --- /dev/null +++ b/e2e/playwright/tests/editors/chat/confirmationPopup.spec.ts @@ -0,0 +1,38 @@ +import { test } from '../../../fixtures'; +import { createWidget } from '../../../helpers/createWidget'; +import { testScreenshot } from '../../../helpers/screenshots'; +import Chat from '../../../models/chat'; +import { createUser } from './data'; + +test.describe('ChatConfirmationPopup', () => { + test('Chat: confirmation popup', async ({ page }) => { + const userFirst = createUser(1, 'First'); + const userSecond = createUser(2, 'Second'); + + const items = [ + { author: userFirst, text: 'AAA' }, + { author: userFirst, text: 'BBB' }, + { author: userSecond, text: 'CCC' }, + ]; + + await createWidget(page, 'dxChat', { + items, + editing: { + allowDeleting: true, + }, + user: userSecond, + width: 400, + height: 600, + showDayHeaders: false, + rtlEnabled: true, + }); + + const chat = new Chat(page, '#container'); + + await chat.getMessage(2).click({ button: 'right' }); + await page.keyboard.press('ArrowDown'); + await page.keyboard.press('Enter'); + + await testScreenshot(page, 'Confirmation popup is shown.png', { element: '#container' }); + }); +}); diff --git a/e2e/playwright/tests/editors/chat/data/index.ts b/e2e/playwright/tests/editors/chat/data/index.ts new file mode 100644 index 000000000000..e8b5a1993a81 --- /dev/null +++ b/e2e/playwright/tests/editors/chat/data/index.ts @@ -0,0 +1,116 @@ +interface User { + id: number; + name: string; + avatarUrl: string; +} + +interface Attachment { + name: string; + size: number; +} + +interface Message { + timestamp: Date; + author: User; + type?: 'image' | 'text'; + src?: string; + text?: string; + attachments?: Attachment[]; +} + +export const avatarUrl = 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAJgAAACRCAYAAAA/zXHpAAAABGdBTUEAALGPC/xhBQAAACBjSFJNAAB6JgAAgIQAAPoAAACA6AAAdTAAAOpgAAA6mAAAF3CculE8AAAAUGVYSWZNTQAqAAAACAACARIAAwAAAAEAAQAAh2kABAAAAAEAAAAmAAAAAAADoAEAAwAAAAEAAQAAoAIABAAAAAEAAACYoAMABAAAAAEAAACRAAAAAPaSQrgAAAIyaVRYdFhNTDpjb20uYWRvYmUueG1wAAAAAAA8eDp4bXBtZXRhIHhtbG5zOng9ImFkb2JlOm5zOm1ldGEvIiB4OnhtcHRrPSJYTVAgQ29yZSA2LjAuMCI+CiAgIDxyZGY6UkRGIHhtbG5zOnJkZj0iaHR0cDovL3d3dy53My5vcmcvMTk5OS8wMi8yMi1yZGYtc3ludGF4LW5zIyI+CiAgICAgIDxyZGY6RGVzY3JpcHRpb24gcmRmOmFib3V0PSIiCiAgICAgICAgICAgIHhtbG5zOmV4aWY9Imh0dHA6Ly9ucy5hZG9iZS5jb20vZXhpZi8xLjAvIgogICAgICAgICAgICB4bWxuczp0aWZmPSJodHRwOi8vbnMuYWRvYmUuY29tL3RpZmYvMS4wLyI+CiAgICAgICAgIDxleGlmOlBpeGVsWURpbWVuc2lvbj40Njk8L2V4aWY6UGl4ZWxZRGltZW5zaW9uPgogICAgICAgICA8ZXhpZjpQaXhlbFhEaW1lbnNpb24+NjAwPC9leGlmOlBpeGVsWERpbWVuc2lvbj4KICAgICAgICAgPGV4aWY6Q29sb3JTcGFjZT4xPC9leGlmOkNvbG9yU3BhY2U+CiAgICAgICAgIDx0aWZmOk9yaWVudGF0aW9uPjE8L3RpZmY6T3JpZW50YXRpb24+CiAgICAgIDwvcmRmOkRlc2NyaXB0aW9uPgogICA8L3JkZjpSREY+CjwveDp4bXBtZXRhPgrvIHvVAAADyklEQVR4Ae3dMW4VUAxEUUCIgr1QsikqOkRBAwViE2yI/VASehTcjGwR5qTLt5x5c3312zx/ePXh4dnBz5d3Xw9S/u+IT99fPLmCT+/FTw5x94MJ1n3/9fYEW0fcHUCw7vuvtyfYOuLuAIJ133+9PcHWEXcHEKz7/uvtCbaOuDuAYN33X29PsHXE3QEE677/enuCrSPuDiBY9/3X2xNsHXF3AMG677/enmDriLsDCNZ9//X2BFtH3B1AsO77r7cn2Dri7gCCdd9/vT3B1hF3BxCs+/7r7Qm2jrg7gGDd919vT7B1xN0BBOu+/3p7gq0j7g4gWPf919sTbB1xdwDBuu+/3p5g64i7AwjWff/19gRbR9wdQLDu+6+3f/lYwse33x77OPvsx8LfzF5k+4CAb7ADyM0RBGu+/kF3gh1Abo4gWPP1D7oT7ABycwTBmq9/0J1gB5CbIwjWfP2D7gQ7gNwcQbDm6x90J9gB5OYIgjVf/6A7wQ4gN0cQrPn6B90JdgC5OYJgzdc/6E6wA8jNEQRrvv5Bd4IdQG6OIFjz9Q+6E+wAcnMEwZqvf9CdYAeQmyMI1nz9g+4EO4DcHEGw5usfdCfYAeTmCII1X/+gO8EOIDdHEKz5+gfdCXYAuTmCYM3XP+hOsAPIzREEa77+QXeCHUBujiBY8/UPuhPsAHJzBMGar3/QnWAHkJsjCNZ8/YPuBDuA3BxBsObrH3Qn2AHk5giCNV//oDvBDiA3RxCs+foH3Ql2ALk5gmDN1z/oTrADyM0Rj/7H22Yg/3L3j2/+3de9fvvr0cc9//z+18Ofk58/fLH9ycTvM4G/CcakmZtpSIBgIUDrMwGCzXxMQwIECwFanwkQbOZjGhIgWAjQ+kyAYDMf05AAwUKA1mcCBJv5mIYECBYCtD4TINjMxzQkQLAQoPWZAMFmPqYhAYKFAK3PBAg28zENCRAsBGh9JkCwmY9pSIBgIUDrMwGCzXxMQwIECwFanwkQbOZjGhIgWAjQ+kyAYDMf05AAwUKA1mcCBJv5mIYECBYCtD4TINjMxzQkQLAQoPWZAMFmPqYhAYKFAK3PBAg28zENCRAsBGh9JkCwmY9pSIBgIUDrMwGCzXxMQwIECwFanwkQbOZjGhIgWAjQ+kyAYDMf05AAwUKA1mcCBJv5mIYECBYCtD4TINjMxzQkQLAQoPWZAMFmPqYhAYKFAK3PBAg28zENCRAsBGh9JkCwmY9pSIBgIUDrMwGCzXxMQwIECwFanwkQbOZjGhIgWAjQ+kyAYDMf05AAwUKA1mcCvwEk7hCO5l/PKgAAAABJRU5ErkJggg=='; +export const lineBreaks = '\n\n'; + +export const createUser = (id: number, name: string, url = ''): User => ({ + id, + name, + avatarUrl: url, +}); + +export const timestamp = new Date(1721747399083); + +export const getLongText = (useLineBreaks = false, length = 1): string => { + const UUID = '9138cf2e-ced3-426a-bb53-4478536f690b'; + const longItem = '1826403415222858765740359115719081097182452189907242163763639765588452014727158270738379423360950761826403415222858765740359115719081097182452189907'; + const longItemArray = Array(length).fill(longItem); + const longString = longItemArray.join(''); + + return `${UUID}:${useLineBreaks ? lineBreaks : ''}${longString}`; +}; + +export const getShortText = (useLineBreaks = false): string => `Short${useLineBreaks ? lineBreaks : ' '}text`; + +export const generateMessages = ( + length: number, + userFirst: User, + userSecond = userFirst, + useLongText = false, + useLineBreaks = false, + coefficient = 4, + n = 1, + isEdited = false, +): Message[] => ( + Array.from({ length: length * n }, (_, i) => { + const text = useLongText + ? getLongText(useLineBreaks) + : getShortText(useLineBreaks); + + const getAuthor = () => { + if (n > 1) { + return i >= length ? userSecond : userFirst; + } + + return i % coefficient === 0 ? userFirst : userSecond; + }; + + return { + timestamp, + author: getAuthor(), + text, + isEdited, + }; + }) +); + +export const generateImageMessage = ( + user: User, + src: string, +): Message => ({ + timestamp, + author: user, + type: 'image', + src, +}); + +export const attachments = [ + { + name: '9138cf2e-ced3-426a-bb53-4478536f690b.zip', + size: 1024, + }, + { + name: '9138cf2e-ced3-426a-bb53-4478536f690b.png', + size: 10240, + }, + { + name: '9138cf2e-ced3-426a-bb53-4478536f690b.jpeg', + size: 102400, + }, + { + name: '9138cf2e-ced3-426a-bb53-4478536f690b.zip', + size: 102400, + }, +]; + +export const generateFileMessage = (author: User, longText = false): Message => ({ + text: longText ? getLongText() : getShortText(), + timestamp, + author, + attachments, +}); + +export const generateFileMessageWithoutText = (author: User): Message => ({ + text: '', + timestamp, + author, + attachments, +}); diff --git a/e2e/playwright/tests/editors/chat/etalons/Alertlist appearance in RTL mode (fluent-next.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Alertlist appearance in RTL mode (fluent-next.blue.light).png new file mode 100644 index 000000000000..cfa7dd0ec36c Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Alertlist appearance in RTL mode (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Alertlist appearance in RTL mode (fluent.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Alertlist appearance in RTL mode (fluent.blue.light).png new file mode 100644 index 000000000000..9e959e4133cb Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Alertlist appearance in RTL mode (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Alertlist with long text in error (fluent-next.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Alertlist with long text in error (fluent-next.blue.light).png new file mode 100644 index 000000000000..5fa33a901746 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Alertlist with long text in error (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Alertlist with long text in error (fluent.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Alertlist with long text in error (fluent.blue.light).png new file mode 100644 index 000000000000..c6cb3b4ada81 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Alertlist with long text in error (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Alertlist with one error (fluent-next.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Alertlist with one error (fluent-next.blue.light).png new file mode 100644 index 000000000000..4c572e39a3aa Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Alertlist with one error (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Alertlist with one error (fluent.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Alertlist with one error (fluent.blue.light).png new file mode 100644 index 000000000000..6d1069250990 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Alertlist with one error (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Avatar has correct position (fluent-next.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Avatar has correct position (fluent-next.blue.light).png new file mode 100644 index 000000000000..7e0832e4623d Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Avatar has correct position (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Avatar has correct position (fluent.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Avatar has correct position (fluent.blue.light).png new file mode 100644 index 000000000000..f5a331d863d4 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Avatar has correct position (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Avatar sizes do not affect indentation between bubbles (fluent-next.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Avatar sizes do not affect indentation between bubbles (fluent-next.blue.light).png new file mode 100644 index 000000000000..6b07be4b101a Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Avatar sizes do not affect indentation between bubbles (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Avatar sizes do not affect indentation between bubbles (fluent.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Avatar sizes do not affect indentation between bubbles (fluent.blue.light).png new file mode 100644 index 000000000000..d05d7292c80f Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Avatar sizes do not affect indentation between bubbles (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Avatar with image (fluent-next.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Avatar with image (fluent-next.blue.light).png new file mode 100644 index 000000000000..b0fd44542f8d Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Avatar with image (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Avatar with image (fluent.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Avatar with image (fluent.blue.light).png new file mode 100644 index 000000000000..4ca80cde0d36 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Avatar with image (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Avatar with showAvatar set to false (fluent-next.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Avatar with showAvatar set to false (fluent-next.blue.light).png new file mode 100644 index 000000000000..997de8f07084 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Avatar with showAvatar set to false (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Avatar with showAvatar set to false (fluent.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Avatar with showAvatar set to false (fluent.blue.light).png new file mode 100644 index 000000000000..ec149ff454f0 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Avatar with showAvatar set to false (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Avatar with two word initials (fluent-next.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Avatar with two word initials (fluent-next.blue.light).png new file mode 100644 index 000000000000..8dd5443b3bfd Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Avatar with two word initials (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Avatar with two word initials (fluent.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Avatar with two word initials (fluent.blue.light).png new file mode 100644 index 000000000000..7711768fbc42 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Avatar with two word initials (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Bubble with files without text (fluent-next.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Bubble with files without text (fluent-next.blue.light).png new file mode 100644 index 000000000000..3fc46842d7be Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Bubble with files without text (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Bubble with files without text (fluent.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Bubble with files without text (fluent.blue.light).png new file mode 100644 index 000000000000..b615df37abb1 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Bubble with files without text (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Bubbles with files (fluent-next.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Bubbles with files (fluent-next.blue.light).png new file mode 100644 index 000000000000..a41d618004dc Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Bubbles with files (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Bubbles with files (fluent.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Bubbles with files (fluent.blue.light).png new file mode 100644 index 000000000000..61e146eee742 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Bubbles with files (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Bubbles with images (fluent-next.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Bubbles with images (fluent-next.blue.light).png new file mode 100644 index 000000000000..31b2c9bd1978 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Bubbles with images (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Bubbles with images (fluent.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Bubbles with images (fluent.blue.light).png new file mode 100644 index 000000000000..d82e2c6574fc Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Bubbles with images (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Bubbles with long text (fluent-next.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Bubbles with long text (fluent-next.blue.light).png new file mode 100644 index 000000000000..06679c4fad59 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Bubbles with long text (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Bubbles with long text (fluent.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Bubbles with long text (fluent.blue.light).png new file mode 100644 index 000000000000..12ea664764f5 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Bubbles with long text (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Bubbles with long text with line breaks (fluent-next.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Bubbles with long text with line breaks (fluent-next.blue.light).png new file mode 100644 index 000000000000..17d50cf4fbc4 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Bubbles with long text with line breaks (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Bubbles with long text with line breaks (fluent.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Bubbles with long text with line breaks (fluent.blue.light).png new file mode 100644 index 000000000000..6bdf5fad7e6c Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Bubbles with long text with line breaks (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Chat suggestions outside of a chat (fluent-next.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Chat suggestions outside of a chat (fluent-next.blue.light).png new file mode 100644 index 000000000000..ec9ebee392db Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Chat suggestions outside of a chat (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Confirmation popup is shown (fluent-next.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Confirmation popup is shown (fluent-next.blue.light).png new file mode 100644 index 000000000000..ded4bde021a5 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Confirmation popup is shown (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Confirmation popup is shown (fluent.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Confirmation popup is shown (fluent.blue.light).png new file mode 100644 index 000000000000..c4f7027b34f3 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Confirmation popup is shown (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Information row with long user name (fluent-next.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Information row with long user name (fluent-next.blue.light).png new file mode 100644 index 000000000000..79d4cf741adc Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Information row with long user name (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Information row with long user name (fluent.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Information row with long user name (fluent.blue.light).png new file mode 100644 index 000000000000..a5a8887c3f13 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Information row with long user name (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/MessageGroup with edited messages (fluent-next.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/MessageGroup with edited messages (fluent-next.blue.light).png new file mode 100644 index 000000000000..911164606708 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/MessageGroup with edited messages (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/MessageGroup with edited messages (fluent.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/MessageGroup with edited messages (fluent.blue.light).png new file mode 100644 index 000000000000..fe121feddace Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/MessageGroup with edited messages (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagebox when chat has focus (fluent-next.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagebox when chat has focus (fluent-next.blue.light).png new file mode 100644 index 000000000000..83876588ca87 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagebox when chat has focus (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagebox when chat has focus (fluent.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagebox when chat has focus (fluent.blue.light).png new file mode 100644 index 000000000000..868e35346b0d Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagebox when chat has focus (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagebox when input contains long text (fluent-next.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagebox when input contains long text (fluent-next.blue.light).png new file mode 100644 index 000000000000..cc043b062e44 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagebox when input contains long text (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagebox when input contains long text (fluent.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagebox when input contains long text (fluent.blue.light).png new file mode 100644 index 000000000000..6125c51cf4a8 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagebox when input contains long text (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagebox when input contains short text (fluent-next.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagebox when input contains short text (fluent-next.blue.light).png new file mode 100644 index 000000000000..6b1fa93d062e Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagebox when input contains short text (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagebox when input contains short text (fluent.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagebox when input contains short text (fluent.blue.light).png new file mode 100644 index 000000000000..38e83725ef9e Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagebox when input contains short text (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagebox when send button has focus (fluent-next.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagebox when send button has focus (fluent-next.blue.light).png new file mode 100644 index 000000000000..ad97381e283d Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagebox when send button has focus (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagebox when send button has focus (fluent.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagebox when send button has focus (fluent.blue.light).png new file mode 100644 index 000000000000..3d2daacdf0f3 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagebox when send button has focus (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagebox with attachments and informer (fluent-next.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagebox with attachments and informer (fluent-next.blue.light).png new file mode 100644 index 000000000000..c40bbbd93170 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagebox with attachments and informer (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagebox with attachments and informer (fluent.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagebox with attachments and informer (fluent.blue.light).png new file mode 100644 index 000000000000..1cd5d22e373b Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagebox with attachments and informer (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagebox with editing preview (fluent-next.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagebox with editing preview (fluent-next.blue.light).png new file mode 100644 index 000000000000..277216b6ca1d Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagebox with editing preview (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagebox with editing preview (fluent.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagebox with editing preview (fluent.blue.light).png new file mode 100644 index 000000000000..4fecb30e5004 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagebox with editing preview (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagegroup appearance in RTL mode (fluent-next.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagegroup appearance in RTL mode (fluent-next.blue.light).png new file mode 100644 index 000000000000..99c8f8f89c4a Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagegroup appearance in RTL mode (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagegroup appearance in RTL mode (fluent.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagegroup appearance in RTL mode (fluent.blue.light).png new file mode 100644 index 000000000000..907d07743ec9 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagegroup appearance in RTL mode (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagegroup appearance in disabled state (fluent-next.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagegroup appearance in disabled state (fluent-next.blue.light).png new file mode 100644 index 000000000000..c280cbccd009 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagegroup appearance in disabled state (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagegroup appearance in disabled state (fluent.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagegroup appearance in disabled state (fluent.blue.light).png new file mode 100644 index 000000000000..1667a22c00bc Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagegroup appearance in disabled state (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagegroup with 1 bubble (fluent-next.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagegroup with 1 bubble (fluent-next.blue.light).png new file mode 100644 index 000000000000..fb84f23e4a31 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagegroup with 1 bubble (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagegroup with 1 bubble (fluent.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagegroup with 1 bubble (fluent.blue.light).png new file mode 100644 index 000000000000..fa1348636c38 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagegroup with 1 bubble (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagegroup with 2 bubbles (fluent-next.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagegroup with 2 bubbles (fluent-next.blue.light).png new file mode 100644 index 000000000000..62493998ae96 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagegroup with 2 bubbles (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagegroup with 2 bubbles (fluent.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagegroup with 2 bubbles (fluent.blue.light).png new file mode 100644 index 000000000000..c40a54151108 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagegroup with 2 bubbles (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagegroup with 3 bubbles (fluent-next.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagegroup with 3 bubbles (fluent-next.blue.light).png new file mode 100644 index 000000000000..000eb3d9675d Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagegroup with 3 bubbles (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagegroup with 3 bubbles (fluent.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagegroup with 3 bubbles (fluent.blue.light).png new file mode 100644 index 000000000000..6fa52952e9e9 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagegroup with 3 bubbles (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagegroup with 4 bubbles (fluent-next.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagegroup with 4 bubbles (fluent-next.blue.light).png new file mode 100644 index 000000000000..d2d7bffdb901 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagegroup with 4 bubbles (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagegroup with 4 bubbles (fluent.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagegroup with 4 bubbles (fluent.blue.light).png new file mode 100644 index 000000000000..b13ee41b050a Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagegroup with 4 bubbles (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagelist empty in RTL mode (fluent-next.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagelist empty in RTL mode (fluent-next.blue.light).png new file mode 100644 index 000000000000..269270d577ec Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagelist empty in RTL mode (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagelist empty in RTL mode (fluent.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagelist empty in RTL mode (fluent.blue.light).png new file mode 100644 index 000000000000..30627a41c25b Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagelist empty in RTL mode (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagelist empty in disabled state (fluent-next.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagelist empty in disabled state (fluent-next.blue.light).png new file mode 100644 index 000000000000..d2c13522d0f3 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagelist empty in disabled state (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagelist empty in disabled state (fluent.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagelist empty in disabled state (fluent.blue.light).png new file mode 100644 index 000000000000..956f83593d03 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagelist empty in disabled state (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagelist empty state (fluent-next.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagelist empty state (fluent-next.blue.light).png new file mode 100644 index 000000000000..33636da22d8f Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagelist empty state (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagelist empty state (fluent.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagelist empty state (fluent.blue.light).png new file mode 100644 index 000000000000..f49d39aec2e8 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagelist empty state (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagelist empty with limited dimensions (fluent-next.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagelist empty with limited dimensions (fluent-next.blue.light).png new file mode 100644 index 000000000000..315cd837fc01 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagelist empty with limited dimensions (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagelist empty with limited dimensions (fluent.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagelist empty with limited dimensions (fluent.blue.light).png new file mode 100644 index 000000000000..a759b9b029a9 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagelist empty with limited dimensions (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagelist scroll position after rendering in invisible container (fluent-next.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagelist scroll position after rendering in invisible container (fluent-next.blue.light).png new file mode 100644 index 000000000000..6e2662a4c80a Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagelist scroll position after rendering in invisible container (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagelist scroll position after rendering in invisible container (fluent.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagelist scroll position after rendering in invisible container (fluent.blue.light).png new file mode 100644 index 000000000000..33452491cd42 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagelist scroll position after rendering in invisible container (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagelist scrollbar middle position after typing in textarea (fluent-next.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagelist scrollbar middle position after typing in textarea (fluent-next.blue.light).png new file mode 100644 index 000000000000..dcc88e6bca48 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagelist scrollbar middle position after typing in textarea (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagelist scrollbar middle position after typing in textarea (fluent.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagelist scrollbar middle position after typing in textarea (fluent.blue.light).png new file mode 100644 index 000000000000..8ab5c0e7fbb3 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagelist scrollbar middle position after typing in textarea (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagelist scrollbar position after call renderMessage() (fluent-next.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagelist scrollbar position after call renderMessage() (fluent-next.blue.light).png new file mode 100644 index 000000000000..3a3a42b7a332 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagelist scrollbar position after call renderMessage() (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagelist scrollbar position after call renderMessage() (fluent.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagelist scrollbar position after call renderMessage() (fluent.blue.light).png new file mode 100644 index 000000000000..84e45a262962 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagelist scrollbar position after call renderMessage() (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagelist scrollbar position after send (fluent-next.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagelist scrollbar position after send (fluent-next.blue.light).png new file mode 100644 index 000000000000..b82ec7b75702 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagelist scrollbar position after send (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagelist scrollbar position after send (fluent.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagelist scrollbar position after send (fluent.blue.light).png new file mode 100644 index 000000000000..5143e865bb17 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagelist scrollbar position after send (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagelist scrollbar position after typing in textarea (fluent-next.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagelist scrollbar position after typing in textarea (fluent-next.blue.light).png new file mode 100644 index 000000000000..1f2fb5173912 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagelist scrollbar position after typing in textarea (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagelist scrollbar position after typing in textarea (fluent.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagelist scrollbar position after typing in textarea (fluent.blue.light).png new file mode 100644 index 000000000000..ba9708d44cc8 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagelist scrollbar position after typing in textarea (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagelist with a lot of messages (fluent-next.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagelist with a lot of messages (fluent-next.blue.light).png new file mode 100644 index 000000000000..daceb1bec188 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagelist with a lot of messages (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagelist with a lot of messages (fluent.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagelist with a lot of messages (fluent.blue.light).png new file mode 100644 index 000000000000..3109829aba00 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagelist with a lot of messages (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagelist with date headers (fluent-next.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagelist with date headers (fluent-next.blue.light).png new file mode 100644 index 000000000000..cb867bde41cc Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagelist with date headers (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagelist with date headers (fluent.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagelist with date headers (fluent.blue.light).png new file mode 100644 index 000000000000..d4a97f8399d9 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagelist with date headers (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagelist with editing context menu (fluent-next.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagelist with editing context menu (fluent-next.blue.light).png new file mode 100644 index 000000000000..d2066c35f89e Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagelist with editing context menu (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagelist with editing context menu (fluent.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagelist with editing context menu (fluent.blue.light).png new file mode 100644 index 000000000000..19caff7123d9 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagelist with editing context menu (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagelist with message template (fluent-next.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagelist with message template (fluent-next.blue.light).png new file mode 100644 index 000000000000..e7cb70b44a23 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagelist with message template (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagelist with message template (fluent.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagelist with message template (fluent.blue.light).png new file mode 100644 index 000000000000..4ce6ed31c740 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagelist with message template (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagelist with message template after new message add (fluent-next.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagelist with message template after new message add (fluent-next.blue.light).png new file mode 100644 index 000000000000..5fe4ef3dda2f Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagelist with message template after new message add (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagelist with message template after new message add (fluent.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagelist with message template after new message add (fluent.blue.light).png new file mode 100644 index 000000000000..8c360c8bce9e Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagelist with message template after new message add (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagelist with message template and deleted messages (fluent-next.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagelist with message template and deleted messages (fluent-next.blue.light).png new file mode 100644 index 000000000000..a47e48468e26 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagelist with message template and deleted messages (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagelist with message template and deleted messages (fluent.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagelist with message template and deleted messages (fluent.blue.light).png new file mode 100644 index 000000000000..f53aba61ebf5 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagelist with message template and deleted messages (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagelist with showDayHeaders, showUserName and showMessageTimestamp options set to false (fluent-next.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagelist with showDayHeaders, showUserName and showMessageTimestamp options set to false (fluent-next.blue.light).png new file mode 100644 index 000000000000..64667afee128 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagelist with showDayHeaders, showUserName and showMessageTimestamp options set to false (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagelist with showDayHeaders, showUserName and showMessageTimestamp options set to false (fluent.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagelist with showDayHeaders, showUserName and showMessageTimestamp options set to false (fluent.blue.light).png new file mode 100644 index 000000000000..188b16ed36a6 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagelist with showDayHeaders, showUserName and showMessageTimestamp options set to false (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagelist without message template and with deleted messages (fluent-next.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagelist without message template and with deleted messages (fluent-next.blue.light).png new file mode 100644 index 000000000000..869a5f3431fc Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagelist without message template and with deleted messages (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Messagelist without message template and with deleted messages (fluent.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Messagelist without message template and with deleted messages (fluent.blue.light).png new file mode 100644 index 000000000000..1af2c2232b94 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Messagelist without message template and with deleted messages (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Typing indicator with 1 user (fluent-next.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Typing indicator with 1 user (fluent-next.blue.light).png new file mode 100644 index 000000000000..564350ec5a8e Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Typing indicator with 1 user (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Typing indicator with 1 user (fluent.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Typing indicator with 1 user (fluent.blue.light).png new file mode 100644 index 000000000000..ddcc8306c884 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Typing indicator with 1 user (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Typing indicator with 2 users (fluent-next.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Typing indicator with 2 users (fluent-next.blue.light).png new file mode 100644 index 000000000000..23fb19bb2e9c Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Typing indicator with 2 users (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Typing indicator with 2 users (fluent.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Typing indicator with 2 users (fluent.blue.light).png new file mode 100644 index 000000000000..c3ca3a681d86 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Typing indicator with 2 users (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Typing indicator with 3 users (fluent-next.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Typing indicator with 3 users (fluent-next.blue.light).png new file mode 100644 index 000000000000..0a1c65a7e243 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Typing indicator with 3 users (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Typing indicator with 3 users (fluent.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Typing indicator with 3 users (fluent.blue.light).png new file mode 100644 index 000000000000..d10054455676 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Typing indicator with 3 users (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Typing indicator with 4 users (fluent-next.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Typing indicator with 4 users (fluent-next.blue.light).png new file mode 100644 index 000000000000..0dd5e5ad71d8 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Typing indicator with 4 users (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Typing indicator with 4 users (fluent.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Typing indicator with 4 users (fluent.blue.light).png new file mode 100644 index 000000000000..a6b0f50a227e Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Typing indicator with 4 users (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Typing indicator with a lot of items (fluent-next.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Typing indicator with a lot of items (fluent-next.blue.light).png new file mode 100644 index 000000000000..8b42cc34d119 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Typing indicator with a lot of items (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Typing indicator with a lot of items (fluent.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Typing indicator with a lot of items (fluent.blue.light).png new file mode 100644 index 000000000000..604a9ab6e378 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Typing indicator with a lot of items (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Typing indicator with emptyview (fluent-next.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Typing indicator with emptyview (fluent-next.blue.light).png new file mode 100644 index 000000000000..6b6cee9b300d Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Typing indicator with emptyview (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Typing indicator with emptyview (fluent.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Typing indicator with emptyview (fluent.blue.light).png new file mode 100644 index 000000000000..55dbbd500982 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Typing indicator with emptyview (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Typing indicator with long name (fluent-next.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Typing indicator with long name (fluent-next.blue.light).png new file mode 100644 index 000000000000..4808e2e4f78b Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Typing indicator with long name (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Typing indicator with long name (fluent.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Typing indicator with long name (fluent.blue.light).png new file mode 100644 index 000000000000..6a777d5fe409 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Typing indicator with long name (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Typing indicator without name (fluent-next.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Typing indicator without name (fluent-next.blue.light).png new file mode 100644 index 000000000000..099d07c84397 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Typing indicator without name (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/etalons/Typing indicator without name (fluent.blue.light).png b/e2e/playwright/tests/editors/chat/etalons/Typing indicator without name (fluent.blue.light).png new file mode 100644 index 000000000000..e7c6ce4f1953 Binary files /dev/null and b/e2e/playwright/tests/editors/chat/etalons/Typing indicator without name (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/chat/messageBox.spec.ts b/e2e/playwright/tests/editors/chat/messageBox.spec.ts new file mode 100644 index 000000000000..2d471e560b10 --- /dev/null +++ b/e2e/playwright/tests/editors/chat/messageBox.spec.ts @@ -0,0 +1,96 @@ +import { test } from '../../../fixtures'; +import { createWidget } from '../../../helpers/createWidget'; +import { appendElementTo } from '../../../helpers/domUtils'; +import { testScreenshot } from '../../../helpers/screenshots'; +import Chat from '../../../models/chat'; +import { + attachments, createUser, getLongText, getShortText, +} from './data'; + +test.describe('ChatMessageBox', () => { + test('Chat: messagebox', async ({ page }) => { + await appendElementTo(page, '#container', 'div', 'chat'); + await createWidget(page, 'dxChat', { + width: 400, + height: 600, + }, '#chat'); + + const chat = new Chat(page, '#chat'); + const input = chat.getInput(); + + const shortText = getShortText(); + const longText = getLongText(false, 5); + + await chat.focus(); + await testScreenshot(page, 'Messagebox when chat has focus.png', { element: '#chat' }); + + await input.click(); + await input.pressSequentially(shortText); + await testScreenshot(page, 'Messagebox when input contains short text.png', { element: '#chat' }); + + await input.click(); + await input.pressSequentially(longText); + await testScreenshot(page, 'Messagebox when input contains long text.png', { element: '#chat' }); + + await page.keyboard.press('Tab'); + await testScreenshot(page, 'Messagebox when send button has focus.png', { element: '#chat' }); + }); + + test('Chat: messagebox with editing preview', async ({ page }) => { + await appendElementTo(page, '#container', 'div', 'chat'); + + const userFirst = createUser(1, 'First'); + const userSecond = createUser(2, 'Second'); + + const items = [{ + author: userFirst, + text: 'Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.', + }, { + author: userSecond, + text: 'Short message', + }]; + + await createWidget(page, 'dxChat', { + items, + user: userFirst, + editing: { + allowUpdating: true, + }, + width: 400, + height: 600, + }, '#chat'); + + const chat = new Chat(page, '#chat'); + + await chat.getMessage(0).click({ button: 'right' }); + await chat.getContextMenuItem(0).click(); + + await testScreenshot(page, 'Messagebox with editing preview.png', { element: '#chat' }); + }); + + test('Chat: messagebox with attachments and informer', async ({ page }) => { + await appendElementTo(page, '#container', 'div', 'chat'); + await createWidget(page, 'dxChat', { + width: 812, + height: 600, + }, '#chat'); + + const chat = new Chat(page, '#chat'); + const input = chat.getInput(); + + await input.click(); + await input.pressSequentially(getLongText(false, 4)); + await chat.option({ + fileUploaderOptions: { + value: [ + ...attachments, + ...attachments, + ...attachments, + ], + }, + }); + + await chat.focus(); + await testScreenshot(page, 'Messagebox with attachments and informer.png', { element: '#chat' }); + }); +}); diff --git a/e2e/playwright/tests/editors/chat/messageBubble.spec.ts b/e2e/playwright/tests/editors/chat/messageBubble.spec.ts new file mode 100644 index 000000000000..a7d472785ba5 --- /dev/null +++ b/e2e/playwright/tests/editors/chat/messageBubble.spec.ts @@ -0,0 +1,78 @@ +import { test } from '../../../fixtures'; +import { createWidget } from '../../../helpers/createWidget'; +import { appendElementTo } from '../../../helpers/domUtils'; +import { testScreenshot } from '../../../helpers/screenshots'; +import Chat from '../../../models/chat'; +import { + createUser, + generateFileMessage, + generateFileMessageWithoutText, + generateImageMessage, + generateMessages, +} from './data'; +import { expectImagesLoaded } from './utils'; + +test.describe('ChatMessageBubble', () => { + test('Chat: messagebubble', async ({ page }) => { + await appendElementTo(page, '#container', 'div', 'chat'); + await createWidget(page, 'dxChat', { + width: 400, + height: 650, + }, '#chat'); + + const chat = new Chat(page, '#chat'); + + const userFirst = createUser(1, 'First'); + const userSecond = createUser(2, 'Second'); + + let items = generateMessages(2, userFirst, userSecond, true, false, 2); + + await chat.option({ items, user: userSecond }); + await testScreenshot(page, 'Bubbles with long text.png', { element: '#chat' }); + + items = generateMessages(2, userFirst, userSecond, true, true, 2); + + await chat.option({ items }); + await testScreenshot(page, 'Bubbles with long text with line breaks.png', { element: '#chat' }); + }); + + test('Chat: messagebubble with images and files', async ({ page }) => { + await appendElementTo(page, '#container', 'div', 'chat'); + await createWidget(page, 'dxChat', { + width: 600, + height: 650, + }, '#chat'); + + const chat = new Chat(page, '#chat'); + + const user = createUser(1, 'ImageUser'); + + const imageMessages = [ + generateImageMessage(user, '../../../apps/demos/images/products/1.png'), + generateImageMessage(user, '../../../apps/demos/images/products/1-small.png'), + ]; + + await chat.option({ items: imageMessages }); + await expectImagesLoaded(chat.element, 2); + await testScreenshot(page, 'Bubbles with images.png', { element: '#chat' }); + + const fileMessages = [ + generateFileMessage(user), + generateFileMessage(user, true), + ]; + + await chat.option({ + width: 700, + height: 720, + items: fileMessages, + }); + await testScreenshot(page, 'Bubbles with files.png', { element: '#chat' }); + + await chat.option({ + width: 600, + height: 600, + items: [generateFileMessageWithoutText(user)], + }); + await testScreenshot(page, 'Bubble with files without text.png', { element: '#chat' }); + }); +}); diff --git a/e2e/playwright/tests/editors/chat/messageGroup.spec.ts b/e2e/playwright/tests/editors/chat/messageGroup.spec.ts new file mode 100644 index 000000000000..f888cbb2de62 --- /dev/null +++ b/e2e/playwright/tests/editors/chat/messageGroup.spec.ts @@ -0,0 +1,143 @@ +import type { Page } from '@playwright/test'; +import { test } from '../../../fixtures'; +import { createWidget } from '../../../helpers/createWidget'; +import { appendElementTo, setStyleAttribute } from '../../../helpers/domUtils'; +import { testScreenshot } from '../../../helpers/screenshots'; +import Chat from '../../../models/chat'; +import { + createUser, + generateMessages, + getLongText, +} from './data'; + +const AVATAR_SELECTOR = '.dx-avatar'; +const CHAT_WRAPPER_STYLES = 'display: flex; flex-wrap: wrap; gap: 2px; width: 1270px; padding: 20px; transform: scale(0.9);'; + +const renderChatsWithBubbleCounts = async ( + page: Page, + options: Record, +): Promise => { + await appendElementTo(page, '#container', 'div', 'chat-wrapper'); + await setStyleAttribute(page, '#chat-wrapper', CHAT_WRAPPER_STYLES); + + const userFirst = createUser(1, 'First'); + const userSecond = createUser(2, 'Second'); + + for (const [idx, bubbleCount] of [1, 2, 3, 4].entries()) { + const chatId = `#chat_${idx}`; + + await appendElementTo(page, '#chat-wrapper', 'div', `chat_${idx}`); + + const items = generateMessages(bubbleCount, userFirst, userSecond, false, false, 4, 2); + + await createWidget(page, 'dxChat', { + items, + ...options, + user: userSecond, + width: 250, + height: 400, + }, chatId); + + await new Chat(page, chatId).repaint(); + } +}; + +test.describe('ChatMessageGroup', () => { + test('Chat: messagegroup, avatar rendering', async ({ page }) => { + await appendElementTo(page, '#container', 'div', 'chat'); + + const userFirst = createUser(1, 'First'); + const items = generateMessages(3, userFirst); + + await createWidget(page, 'dxChat', { + width: 400, + height: 600, + items, + }, '#chat'); + + await testScreenshot(page, 'Avatar has correct position.png', { element: '#chat' }); + + await setStyleAttribute(page, AVATAR_SELECTOR, 'width: 64px; height: 64px'); + await testScreenshot(page, 'Avatar sizes do not affect indentation between bubbles.png', { element: '#chat' }); + }); + + test('Chat: messagegroup, information', async ({ page }) => { + await appendElementTo(page, '#container', 'div', 'chat'); + + const userFirst = createUser(1, getLongText()); + const userSecond = createUser(2, getLongText()); + + const items = generateMessages(2, userFirst, userSecond, false, false, 2); + + await createWidget(page, 'dxChat', { + width: 400, + height: 600, + user: userSecond, + items, + }, '#chat'); + + await testScreenshot(page, 'Information row with long user name.png', { element: '#chat' }); + }); + + test('Chat: messagegroup, bubbles', async ({ page }) => { + await appendElementTo(page, '#container', 'div', 'chat'); + await createWidget(page, 'dxChat', { + width: 400, + height: 600, + }, '#chat'); + + const chat = new Chat(page, '#chat'); + + const userFirst = createUser(1, 'First'); + const userSecond = createUser(2, 'Second'); + + let items = generateMessages(1, userFirst, userSecond, false, false, 4, 2); + + await chat.option({ items, user: userSecond }); + await testScreenshot(page, 'Messagegroup with 1 bubble.png', { element: '#chat' }); + + items = generateMessages(2, userFirst, userSecond, false, false, 4, 2); + + await chat.option({ items }); + await testScreenshot(page, 'Messagegroup with 2 bubbles.png', { element: '#chat' }); + + items = generateMessages(3, userFirst, userSecond, false, false, 4, 2); + + await chat.option({ items }); + await testScreenshot(page, 'Messagegroup with 3 bubbles.png', { element: '#chat' }); + + items = generateMessages(4, userFirst, userSecond, false, false, 4, 2); + + await chat.option({ items }); + await testScreenshot(page, 'Messagegroup with 4 bubbles.png', { element: '#chat' }); + }); + + test('Messagegroup scenarios in disabled state', async ({ page }) => { + await renderChatsWithBubbleCounts(page, { disabled: true }); + + await testScreenshot(page, 'Messagegroup appearance in disabled state.png', { element: '#chat-wrapper' }); + }); + + test('Messagegroup scenarios in RTL mode', async ({ page }) => { + await renderChatsWithBubbleCounts(page, { rtlEnabled: true }); + + await testScreenshot(page, 'Messagegroup appearance in RTL mode.png', { element: '#chat-wrapper' }); + }); + + test('MessageGroup with edited messages', async ({ page }) => { + await appendElementTo(page, '#container', 'div', 'chat'); + + const userFirst = createUser(1, 'First'); + const userSecond = createUser(2, 'Second'); + const items = generateMessages(2, userFirst, userSecond, false, false, 2, 2, true); + + await createWidget(page, 'dxChat', { + width: 400, + height: 600, + user: userSecond, + items, + }, '#chat'); + + await testScreenshot(page, 'MessageGroup with edited messages.png', { element: '#chat' }); + }); +}); diff --git a/e2e/playwright/tests/editors/chat/messageList.spec.ts b/e2e/playwright/tests/editors/chat/messageList.spec.ts new file mode 100644 index 000000000000..6e00bc94995f --- /dev/null +++ b/e2e/playwright/tests/editors/chat/messageList.spec.ts @@ -0,0 +1,332 @@ +import { test } from '../../../fixtures'; +import { createWidget } from '../../../helpers/createWidget'; +import { mockDate } from '../../../helpers/mockDate'; +import { testScreenshot } from '../../../helpers/screenshots'; +import Chat from '../../../models/chat'; +import TabPanel from '../../../models/tabPanel'; +import { createUser, generateMessages, getLongText } from './data'; + +test.describe('ChatMessageList', () => { + test('Messagelist empty view scenarios', async ({ page }) => { + await createWidget(page, 'dxChat', { + width: 400, + height: 600, + }); + + const chat = new Chat(page, '#container'); + + await testScreenshot(page, 'Messagelist empty state.png', { element: '#container' }); + + await chat.option('rtlEnabled', true); + + await testScreenshot(page, 'Messagelist empty in RTL mode.png', { element: '#container' }); + + await chat.option({ + disabled: true, + rtlEnabled: false, + }); + + await testScreenshot(page, 'Messagelist empty in disabled state.png', { element: '#container' }); + + await chat.option({ + width: 200, + height: 400, + disabled: false, + }); + + await testScreenshot(page, 'Messagelist empty with limited dimensions.png', { element: '#container' }); + }); + + test('Messagelist appearance with scrollbar', async ({ page }) => { + const userFirst = createUser(1, 'First'); + const userSecond = createUser(2, 'Second'); + + const items = generateMessages(17, userFirst, userSecond, true, false, 2); + + await createWidget(page, 'dxChat', (options) => ({ + ...options, + width: 400, + height: 600, + showDayHeaders: false, + onMessageEntered: (e) => { + const { component, message } = e; + + component.renderMessage(message); + }, + }), undefined, { arg: { items, user: userSecond } }); + + const chat = new Chat(page, '#container'); + const input = chat.getInput(); + + await chat.messageList.hover(); + + await testScreenshot(page, 'Messagelist with a lot of messages.png', { element: '#container' }); + + await chat.element.evaluate((element) => { + const instance = ($(element) as any).dxChat('instance'); + + instance.renderMessage({ + author: instance.option('user'), + text: 'Lorem ipsum dolor sit amet, \nconsectetur adipiscing elit. Sed do eiusmod tempor \nincididunt ut labore et dolore magna aliqua. Ut enim ad minim \nveniam, quis nostrud exercitation ullamco laboris nisi ut aliquip \nnex ea commodo consequat.', + }); + }); + + await testScreenshot(page, 'Messagelist scrollbar position after call renderMessage().png', { element: '#container' }); + + await input.click(); + await input.pressSequentially(getLongText()); + await page.keyboard.press('Shift+Enter'); + + await testScreenshot(page, 'Messagelist scrollbar position after typing in textarea.png', { element: '#container' }); + + await page.keyboard.press('Enter'); + + await testScreenshot(page, 'Messagelist scrollbar position after send.png', { element: '#container' }); + + const scrollable = chat.getScrollable(); + const { top } = await scrollable.scrollOffset(); + + await scrollable.scrollTo({ top: top - 100 }); + + await input.click(); + await input.pressSequentially(getLongText()); + + await testScreenshot(page, 'Messagelist scrollbar middle position after typing in textarea.png', { element: '#container' }); + }); + + test('Messagelist should scrolled to the latest messages after being rendered inside an invisible element', async ({ page }) => { + const userFirst = createUser(1, 'First'); + const userSecond = createUser(2, 'Second'); + + const items = generateMessages(17, userFirst, userSecond, true, false, 2); + + await createWidget(page, 'dxTabPanel', ({ chatItems, user }) => ({ + width: 400, + height: 600, + deferRendering: true, + templatesRenderAsynchronously: true, + dataSource: [{ + title: 'Tab_1', + collapsible: true, + text: 'Tab_1 content', + }, { + title: 'Tab_2', + collapsible: true, + template: () => ($('
') as any).dxChat({ + items: chatItems, + user, + }), + }], + }), undefined, { arg: { chatItems: items, user: userSecond } }); + + const tabPanel = new TabPanel(page, '#container'); + + await tabPanel.getTab(1).click(); + + await testScreenshot(page, 'Messagelist scroll position after rendering in invisible container.png', { element: '#container' }); + }); + + test('Messagelist with deleted items', async ({ page }) => { + const userFirst = createUser(1, 'First'); + const userSecond = createUser(2, 'Second'); + const items = [{ + author: userFirst, + text: 'AAA', + }, { + author: userFirst, + text: 'BBB', + isDeleted: true, + }, { + author: userSecond, + text: 'CCC', + isDeleted: true, + }]; + + await createWidget(page, 'dxChat', { + items, + user: userFirst, + width: 400, + height: 600, + showDayHeaders: false, + }); + + await testScreenshot(page, 'Messagelist without message template and with deleted messages.png', { element: '#container' }); + }); + + test('Messagelist with deleted items and custom template', async ({ page }) => { + const userFirst = createUser(1, 'First'); + const userSecond = createUser(2, 'Second'); + const items = [{ + author: userFirst, + text: 'AAA', + }, { + author: userFirst, + text: 'BBB', + isDeleted: true, + }, { + author: userSecond, + text: 'CCC', + isDeleted: true, + }]; + + await createWidget(page, 'dxChat', (options) => ({ + ...options, + width: 400, + height: 600, + showDayHeaders: false, + messageTemplate: ({ message }, container) => { + if (message.isDeleted) { + $('
').text(`${message.author.name} deleted this message`).appendTo(container); + return; + } + $('
').text(message.text).appendTo(container); + }, + }), undefined, { arg: { items, user: userFirst } }); + + await testScreenshot(page, 'Messagelist with message template and deleted messages.png', { element: '#container' }); + }); + + test('Messagelist with messageTemplate', async ({ page }) => { + const userFirst = createUser(1, 'First'); + const userSecond = createUser(2, 'Second'); + const items = [{ + author: userFirst, + text: 'AAA', + }, { + author: userFirst, + text: 'BBB', + }, { + author: userSecond, + text: 'CCC', + }]; + + await createWidget(page, 'dxChat', (options) => ({ + ...options, + width: 400, + height: 600, + showDayHeaders: false, + onMessageEntered: ({ component, message }) => { + component.renderMessage({ ...message, timestamp: undefined }); + }, + messageTemplate: ({ message }, container) => { + $('
').text(`${message.author.name} says: ${message.text}`).appendTo(container); + }, + }), undefined, { arg: { items, user: userFirst } }); + + const chat = new Chat(page, '#container'); + const input = chat.getInput(); + + await testScreenshot(page, 'Messagelist with message template.png', { element: '#container' }); + + await input.click(); + await input.pressSequentially('New last message'); + await page.keyboard.press('Enter'); + + await testScreenshot(page, 'Messagelist with message template after new message add.png', { element: '#container' }); + }); + + test('Messagelist options showDayHeaders, showUserName and showMessageTimestamp set to false work', async ({ page }) => { + const userFirst = createUser(1, 'First'); + const userSecond = createUser(2, 'Second'); + const items = [{ + author: userFirst, + text: 'AAA', + }, { + author: userFirst, + text: 'BBB', + }, { + author: userSecond, + text: 'CCC', + }]; + + await createWidget(page, 'dxChat', { + items, + user: userFirst, + width: 400, + height: 600, + showDayHeaders: false, + showUserName: false, + showMessageTimestamp: false, + }); + + await testScreenshot( + page, + 'Messagelist with showDayHeaders, showUserName and showMessageTimestamp options set to false.png', + { element: '#container' }, + ); + }); + + test('Message list with editing context menu', async ({ page }) => { + const userFirst = createUser(1, 'First'); + const userSecond = createUser(2, 'Second'); + + const items = [ + { author: userFirst, text: 'AAA' }, + { author: userFirst, text: 'BBB' }, + { author: userSecond, text: 'CCC' }, + ]; + + await createWidget(page, 'dxChat', { + items, + editing: { + allowUpdating: true, + allowDeleting: true, + }, + user: userSecond, + width: 400, + height: 600, + showDayHeaders: false, + }); + + const chat = new Chat(page, '#container'); + + await chat.getMessage(2).click({ button: 'right' }); + await page.keyboard.press('ArrowDown'); + await page.keyboard.press('ArrowDown'); + + await testScreenshot(page, 'Messagelist with editing context menu.png', { element: '#container' }); + }); +}); + +test.describe('ChatMessageList: dayHeaders', () => { + test('Messagelist with date headers', async ({ page }) => { + await mockDate(page, '2024/10/27'); + + const userFirst = createUser(1, 'First'); + const userSecond = createUser(2, 'Second'); + const msInDay = 86400000; + const today = new Date('2024/10/27').setHours(7, 22, 0, 0); + const yesterday = today - msInDay; + + const items = [{ + timestamp: new Date('05.01.2024'), + author: userFirst, + text: 'AAA', + }, { + timestamp: new Date('06.01.2024'), + author: userFirst, + text: 'BBB', + }, { + timestamp: new Date('06.01.2024'), + author: userSecond, + text: 'CCC', + }, { + timestamp: yesterday, + author: userSecond, + text: 'DDD', + }, { + timestamp: today, + author: userFirst, + text: 'EEE', + }]; + + await createWidget(page, 'dxChat', { + items, + user: userSecond, + width: 400, + height: 600, + }); + + await testScreenshot(page, 'Messagelist with date headers.png', { element: '#container' }); + }); +}); diff --git a/e2e/playwright/tests/editors/chat/suggestions.spec.ts b/e2e/playwright/tests/editors/chat/suggestions.spec.ts new file mode 100644 index 000000000000..f91a4eeec5c7 --- /dev/null +++ b/e2e/playwright/tests/editors/chat/suggestions.spec.ts @@ -0,0 +1,39 @@ +import type { Page } from '@playwright/test'; +import { test } from '../../../fixtures'; +import { createWidget } from '../../../helpers/createWidget'; +import { testScreenshot } from '../../../helpers/screenshots'; + +const CHAT_SUGGESTIONS_CLASS = 'dx-chat-suggestions'; + +const render = (page: Page, markup: string): Promise => page.evaluate((html) => { + const container = document.querySelector('#container'); + + if (container) container.innerHTML = html; +}, markup); + +const createSuggestions = (page: Page, selector: string): Promise => createWidget(page, 'dxButtonGroup', { + items: [ + { text: 'Summary' }, + { text: 'Ideal Buyer' }, + { text: 'Competitors' }, + ], + stylingMode: 'outlined', + selectionMode: 'none', + elementAttr: { class: CHAT_SUGGESTIONS_CLASS }, + width: 400, +}, selector); + +test.describe('ChatSuggestions', () => { + test.use({ theme: 'fluent-next.blue.light' }); + + test('Chat suggestions outside of a chat in light and dark modes', async ({ page }) => { + await render(page, ` +
+
+ `); + await createSuggestions(page, '#light'); + await createSuggestions(page, '#dark'); + + await testScreenshot(page, 'Chat suggestions outside of a chat.png', { element: '#container' }); + }); +}); diff --git a/e2e/playwright/tests/editors/chat/typingIndicator.spec.ts b/e2e/playwright/tests/editors/chat/typingIndicator.spec.ts new file mode 100644 index 000000000000..4f59777cac17 --- /dev/null +++ b/e2e/playwright/tests/editors/chat/typingIndicator.spec.ts @@ -0,0 +1,103 @@ +import type { Page } from '@playwright/test'; +import { test } from '../../../fixtures'; +import { createWidget } from '../../../helpers/createWidget'; +import { appendElementTo, insertStylesheetRulesToPage } from '../../../helpers/domUtils'; +import { testScreenshot } from '../../../helpers/screenshots'; +import Chat from '../../../models/chat'; +import { createUser, generateMessages } from './data'; + +const CHAT_TYPINGINDICATOR_CIRCLE_CLASS = 'dx-chat-typingindicator-circle'; + +const waitFont = (page: Page): Promise => page.evaluate( + () => (window as any).DevExpress.ui.themes.waitWebFont('Item123somevalu*op ', 400), +); + +test.describe('ChatTypingIndicator', () => { + test('Chat: typing indicator with emptyview', async ({ page }) => { + await insertStylesheetRulesToPage(page, `.${CHAT_TYPINGINDICATOR_CIRCLE_CLASS} { animation: none !important; }`); + + const typingUsers = [ + { name: 'Elodie Montclair' }, + ]; + + await waitFont(page); + + await createWidget(page, 'dxChat', { + width: 400, + height: 600, + typingUsers, + }); + + await testScreenshot(page, 'Typing indicator with emptyview.png', { element: '#container' }); + }); + + test('Chat: typing indicator with a lot of items', async ({ page }) => { + await appendElementTo(page, '#container', 'div', 'chat'); + await insertStylesheetRulesToPage(page, `.${CHAT_TYPINGINDICATOR_CIRCLE_CLASS} { animation: none !important; }`); + + const userFirst = createUser(1, 'Marie-Claire Dubois'); + const userSecond = createUser(2, 'Jean-Pierre Martin'); + + const items = generateMessages(27, userFirst, userSecond); + + const typingUsers = [userFirst]; + + await createWidget(page, 'dxChat', { + user: userSecond, + width: 400, + height: 600, + items, + typingUsers, + }, '#chat'); + + const chat = new Chat(page, '#chat'); + + await chat.repaint(); + + await testScreenshot(page, 'Typing indicator with a lot of items.png', { element: '#chat' }); + }); + + test('Chat: typing indicator', async ({ page }) => { + await appendElementTo(page, '#container', 'div', 'chat'); + await insertStylesheetRulesToPage(page, `.${CHAT_TYPINGINDICATOR_CIRCLE_CLASS} { animation: none !important; }`); + + const userElise = createUser(1, 'Elise Moreau'); + const userPierre = createUser(2, 'Pierre Martin'); + + const items = generateMessages(5, userElise, userPierre); + + await waitFont(page); + + await createWidget(page, 'dxChat', { + user: userPierre, + width: 400, + height: 600, + items, + typingUsers: [userElise], + }, '#chat'); + + await testScreenshot(page, 'Typing indicator with 1 user.png', { element: '#chat' }); + + const chat = new Chat(page, '#chat'); + + const userFirst = createUser(1, 'Camille'); + const userSecond = createUser(2, 'Sophie'); + const userThird = createUser(3, 'Antoine'); + const userFourth = createUser(4, 'Julien'); + + await chat.option('typingUsers', [userFirst, userSecond]); + await testScreenshot(page, 'Typing indicator with 2 users.png', { element: '#chat' }); + + await chat.option('typingUsers', [userFirst, userSecond, userThird]); + await testScreenshot(page, 'Typing indicator with 3 users.png', { element: '#chat' }); + + await chat.option('typingUsers', [userFirst, userSecond, userThird, userFourth]); + await testScreenshot(page, 'Typing indicator with 4 users.png', { element: '#chat' }); + + await chat.option('typingUsers', [{ name: 'Marie-Francoise Isabelle Antoinette de La Rochefoucauld' }]); + await testScreenshot(page, 'Typing indicator with long name.png', { element: '#chat' }); + + await chat.option('typingUsers', [{}]); + await testScreenshot(page, 'Typing indicator without name.png', { element: '#chat' }); + }); +}); diff --git a/e2e/playwright/tests/editors/chat/utils.ts b/e2e/playwright/tests/editors/chat/utils.ts new file mode 100644 index 000000000000..a0981e5806ac --- /dev/null +++ b/e2e/playwright/tests/editors/chat/utils.ts @@ -0,0 +1,10 @@ +import type { Locator } from '@playwright/test'; +import { expect } from '../../../fixtures'; + +export const expectImagesLoaded = async (container: Locator, count: number): Promise => { + const images = container.locator('img'); + + await expect(images).toHaveCount(count); + await expect.poll(() => images.evaluateAll((elements: HTMLImageElement[]) => elements + .every((image) => image.complete && image.naturalWidth > 0))).toBe(true); +}; diff --git a/e2e/playwright/tests/editors/overlays/dialog.spec.ts b/e2e/playwright/tests/editors/overlays/dialog.spec.ts new file mode 100644 index 000000000000..6de58b2911e9 --- /dev/null +++ b/e2e/playwright/tests/editors/overlays/dialog.spec.ts @@ -0,0 +1,30 @@ +import { expect, test } from '../../../fixtures'; +import { testScreenshot } from '../../../helpers/screenshots'; + +test.describe('Dialog', () => { + [ + 'alert', + 'confirm', + 'custom', + ].forEach((dialogType) => { + test(`Dialog appearance (${dialogType})`, async ({ page }) => { + const dialogArgs = dialogType === 'custom' + ? { title: 'custom', messageHtml: 'message', buttons: [{ text: 'Custom button' }] } + : dialogType; + + await page.evaluate(({ type, args }) => { + const dialogFunction = (window as any).DevExpress.ui.dialog[type]; + + if (type === 'custom') { + dialogFunction(args).show(); + } else { + dialogFunction(args); + } + }, { type: dialogType, args: dialogArgs }); + + await expect(page.locator('.dx-dialog-button').first()).toBeFocused(); + + await testScreenshot(page, `Dialog appearance (${dialogType}).png`); + }); + }); +}); diff --git a/e2e/playwright/tests/editors/overlays/etalons/Dialog appearance (alert) (fluent-next.blue.light).png b/e2e/playwright/tests/editors/overlays/etalons/Dialog appearance (alert) (fluent-next.blue.light).png new file mode 100644 index 000000000000..e4543d2f32d7 Binary files /dev/null and b/e2e/playwright/tests/editors/overlays/etalons/Dialog appearance (alert) (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/overlays/etalons/Dialog appearance (alert) (fluent.blue.light).png b/e2e/playwright/tests/editors/overlays/etalons/Dialog appearance (alert) (fluent.blue.light).png new file mode 100644 index 000000000000..6e83706ce7ef Binary files /dev/null and b/e2e/playwright/tests/editors/overlays/etalons/Dialog appearance (alert) (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/overlays/etalons/Dialog appearance (confirm) (fluent-next.blue.light).png b/e2e/playwright/tests/editors/overlays/etalons/Dialog appearance (confirm) (fluent-next.blue.light).png new file mode 100644 index 000000000000..1296d816d84d Binary files /dev/null and b/e2e/playwright/tests/editors/overlays/etalons/Dialog appearance (confirm) (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/overlays/etalons/Dialog appearance (confirm) (fluent.blue.light).png b/e2e/playwright/tests/editors/overlays/etalons/Dialog appearance (confirm) (fluent.blue.light).png new file mode 100644 index 000000000000..b6d633f0a001 Binary files /dev/null and b/e2e/playwright/tests/editors/overlays/etalons/Dialog appearance (confirm) (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/overlays/etalons/Dialog appearance (custom) (fluent-next.blue.light).png b/e2e/playwright/tests/editors/overlays/etalons/Dialog appearance (custom) (fluent-next.blue.light).png new file mode 100644 index 000000000000..af91554f4e75 Binary files /dev/null and b/e2e/playwright/tests/editors/overlays/etalons/Dialog appearance (custom) (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/overlays/etalons/Dialog appearance (custom) (fluent.blue.light).png b/e2e/playwright/tests/editors/overlays/etalons/Dialog appearance (custom) (fluent.blue.light).png new file mode 100644 index 000000000000..4f66ee7d356c Binary files /dev/null and b/e2e/playwright/tests/editors/overlays/etalons/Dialog appearance (custom) (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/overlays/etalons/Popover_bottom_toolbar_menu,rtlEnabled=false (fluent-next.blue.light).png b/e2e/playwright/tests/editors/overlays/etalons/Popover_bottom_toolbar_menu,rtlEnabled=false (fluent-next.blue.light).png new file mode 100644 index 000000000000..f8d602c823c8 Binary files /dev/null and b/e2e/playwright/tests/editors/overlays/etalons/Popover_bottom_toolbar_menu,rtlEnabled=false (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/overlays/etalons/Popover_bottom_toolbar_menu,rtlEnabled=false (fluent.blue.light).png b/e2e/playwright/tests/editors/overlays/etalons/Popover_bottom_toolbar_menu,rtlEnabled=false (fluent.blue.light).png new file mode 100644 index 000000000000..bbbadff57bc3 Binary files /dev/null and b/e2e/playwright/tests/editors/overlays/etalons/Popover_bottom_toolbar_menu,rtlEnabled=false (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/overlays/etalons/Popover_bottom_toolbar_menu,rtlEnabled=true (fluent-next.blue.light).png b/e2e/playwright/tests/editors/overlays/etalons/Popover_bottom_toolbar_menu,rtlEnabled=true (fluent-next.blue.light).png new file mode 100644 index 000000000000..2ee709a8bd44 Binary files /dev/null and b/e2e/playwright/tests/editors/overlays/etalons/Popover_bottom_toolbar_menu,rtlEnabled=true (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/overlays/etalons/Popover_bottom_toolbar_menu,rtlEnabled=true (fluent.blue.light).png b/e2e/playwright/tests/editors/overlays/etalons/Popover_bottom_toolbar_menu,rtlEnabled=true (fluent.blue.light).png new file mode 100644 index 000000000000..fcbc99b3dc6b Binary files /dev/null and b/e2e/playwright/tests/editors/overlays/etalons/Popover_bottom_toolbar_menu,rtlEnabled=true (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/overlays/etalons/Popover_top_toolbar_menu,rtlEnabled=false (fluent-next.blue.light).png b/e2e/playwright/tests/editors/overlays/etalons/Popover_top_toolbar_menu,rtlEnabled=false (fluent-next.blue.light).png new file mode 100644 index 000000000000..59c3a765f064 Binary files /dev/null and b/e2e/playwright/tests/editors/overlays/etalons/Popover_top_toolbar_menu,rtlEnabled=false (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/overlays/etalons/Popover_top_toolbar_menu,rtlEnabled=false (fluent.blue.light).png b/e2e/playwright/tests/editors/overlays/etalons/Popover_top_toolbar_menu,rtlEnabled=false (fluent.blue.light).png new file mode 100644 index 000000000000..9d11f485e218 Binary files /dev/null and b/e2e/playwright/tests/editors/overlays/etalons/Popover_top_toolbar_menu,rtlEnabled=false (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/overlays/etalons/Popover_top_toolbar_menu,rtlEnabled=true (fluent-next.blue.light).png b/e2e/playwright/tests/editors/overlays/etalons/Popover_top_toolbar_menu,rtlEnabled=true (fluent-next.blue.light).png new file mode 100644 index 000000000000..05fe5b271b45 Binary files /dev/null and b/e2e/playwright/tests/editors/overlays/etalons/Popover_top_toolbar_menu,rtlEnabled=true (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/overlays/etalons/Popover_top_toolbar_menu,rtlEnabled=true (fluent.blue.light).png b/e2e/playwright/tests/editors/overlays/etalons/Popover_top_toolbar_menu,rtlEnabled=true (fluent.blue.light).png new file mode 100644 index 000000000000..c1ee8d607366 Binary files /dev/null and b/e2e/playwright/tests/editors/overlays/etalons/Popover_top_toolbar_menu,rtlEnabled=true (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/overlays/etalons/Popup toolbars with wide elements and overflow menu after items rebinding (fluent-next.blue.light).png b/e2e/playwright/tests/editors/overlays/etalons/Popup toolbars with wide elements and overflow menu after items rebinding (fluent-next.blue.light).png new file mode 100644 index 000000000000..61f0500b8433 Binary files /dev/null and b/e2e/playwright/tests/editors/overlays/etalons/Popup toolbars with wide elements and overflow menu after items rebinding (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/overlays/etalons/Popup toolbars with wide elements and overflow menu after items rebinding (fluent.blue.light).png b/e2e/playwright/tests/editors/overlays/etalons/Popup toolbars with wide elements and overflow menu after items rebinding (fluent.blue.light).png new file mode 100644 index 000000000000..b1f21fa403b5 Binary files /dev/null and b/e2e/playwright/tests/editors/overlays/etalons/Popup toolbars with wide elements and overflow menu after items rebinding (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/overlays/etalons/Popup toolbars with wide elements and overflow menu before items rebinding (fluent-next.blue.light).png b/e2e/playwright/tests/editors/overlays/etalons/Popup toolbars with wide elements and overflow menu before items rebinding (fluent-next.blue.light).png new file mode 100644 index 000000000000..db2442ecf4c7 Binary files /dev/null and b/e2e/playwright/tests/editors/overlays/etalons/Popup toolbars with wide elements and overflow menu before items rebinding (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/overlays/etalons/Popup toolbars with wide elements and overflow menu before items rebinding (fluent.blue.light).png b/e2e/playwright/tests/editors/overlays/etalons/Popup toolbars with wide elements and overflow menu before items rebinding (fluent.blue.light).png new file mode 100644 index 000000000000..6ffc325a4f10 Binary files /dev/null and b/e2e/playwright/tests/editors/overlays/etalons/Popup toolbars with wide elements and overflow menu before items rebinding (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/overlays/etalons/Popup_bottom_toolbar_menu,rtlEnabled=false (fluent-next.blue.light).png b/e2e/playwright/tests/editors/overlays/etalons/Popup_bottom_toolbar_menu,rtlEnabled=false (fluent-next.blue.light).png new file mode 100644 index 000000000000..5a57a769e735 Binary files /dev/null and b/e2e/playwright/tests/editors/overlays/etalons/Popup_bottom_toolbar_menu,rtlEnabled=false (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/overlays/etalons/Popup_bottom_toolbar_menu,rtlEnabled=false (fluent.blue.light).png b/e2e/playwright/tests/editors/overlays/etalons/Popup_bottom_toolbar_menu,rtlEnabled=false (fluent.blue.light).png new file mode 100644 index 000000000000..71a8a7e9cbce Binary files /dev/null and b/e2e/playwright/tests/editors/overlays/etalons/Popup_bottom_toolbar_menu,rtlEnabled=false (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/overlays/etalons/Popup_bottom_toolbar_menu,rtlEnabled=true (fluent-next.blue.light).png b/e2e/playwright/tests/editors/overlays/etalons/Popup_bottom_toolbar_menu,rtlEnabled=true (fluent-next.blue.light).png new file mode 100644 index 000000000000..30fe6771983c Binary files /dev/null and b/e2e/playwright/tests/editors/overlays/etalons/Popup_bottom_toolbar_menu,rtlEnabled=true (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/overlays/etalons/Popup_bottom_toolbar_menu,rtlEnabled=true (fluent.blue.light).png b/e2e/playwright/tests/editors/overlays/etalons/Popup_bottom_toolbar_menu,rtlEnabled=true (fluent.blue.light).png new file mode 100644 index 000000000000..afa46c08c898 Binary files /dev/null and b/e2e/playwright/tests/editors/overlays/etalons/Popup_bottom_toolbar_menu,rtlEnabled=true (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/overlays/etalons/Popup_top_toolbar_menu,rtlEnabled=false (fluent-next.blue.light).png b/e2e/playwright/tests/editors/overlays/etalons/Popup_top_toolbar_menu,rtlEnabled=false (fluent-next.blue.light).png new file mode 100644 index 000000000000..193fe729f24c Binary files /dev/null and b/e2e/playwright/tests/editors/overlays/etalons/Popup_top_toolbar_menu,rtlEnabled=false (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/overlays/etalons/Popup_top_toolbar_menu,rtlEnabled=false (fluent.blue.light).png b/e2e/playwright/tests/editors/overlays/etalons/Popup_top_toolbar_menu,rtlEnabled=false (fluent.blue.light).png new file mode 100644 index 000000000000..7263dc0e7c9e Binary files /dev/null and b/e2e/playwright/tests/editors/overlays/etalons/Popup_top_toolbar_menu,rtlEnabled=false (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/overlays/etalons/Popup_top_toolbar_menu,rtlEnabled=true (fluent-next.blue.light).png b/e2e/playwright/tests/editors/overlays/etalons/Popup_top_toolbar_menu,rtlEnabled=true (fluent-next.blue.light).png new file mode 100644 index 000000000000..96ba00308e11 Binary files /dev/null and b/e2e/playwright/tests/editors/overlays/etalons/Popup_top_toolbar_menu,rtlEnabled=true (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/overlays/etalons/Popup_top_toolbar_menu,rtlEnabled=true (fluent.blue.light).png b/e2e/playwright/tests/editors/overlays/etalons/Popup_top_toolbar_menu,rtlEnabled=true (fluent.blue.light).png new file mode 100644 index 000000000000..6ae5de5dcc20 Binary files /dev/null and b/e2e/playwright/tests/editors/overlays/etalons/Popup_top_toolbar_menu,rtlEnabled=true (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/overlays/etalons/Toasts (fluent-next.blue.light).png b/e2e/playwright/tests/editors/overlays/etalons/Toasts (fluent-next.blue.light).png new file mode 100644 index 000000000000..def7bf682b90 Binary files /dev/null and b/e2e/playwright/tests/editors/overlays/etalons/Toasts (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/overlays/etalons/Toasts (fluent.blue.light).png b/e2e/playwright/tests/editors/overlays/etalons/Toasts (fluent.blue.light).png new file mode 100644 index 000000000000..c0a7666c67a4 Binary files /dev/null and b/e2e/playwright/tests/editors/overlays/etalons/Toasts (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/overlays/etalons/Toolbar after items rebinding if it was hidden without items on init (fluent-next.blue.light).png b/e2e/playwright/tests/editors/overlays/etalons/Toolbar after items rebinding if it was hidden without items on init (fluent-next.blue.light).png new file mode 100644 index 000000000000..61f0500b8433 Binary files /dev/null and b/e2e/playwright/tests/editors/overlays/etalons/Toolbar after items rebinding if it was hidden without items on init (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/overlays/etalons/Toolbar after items rebinding if it was hidden without items on init (fluent.blue.light).png b/e2e/playwright/tests/editors/overlays/etalons/Toolbar after items rebinding if it was hidden without items on init (fluent.blue.light).png new file mode 100644 index 000000000000..b1f21fa403b5 Binary files /dev/null and b/e2e/playwright/tests/editors/overlays/etalons/Toolbar after items rebinding if it was hidden without items on init (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/overlays/etalons/Toolbar after items rebinding if it was visible with items on init (fluent-next.blue.light).png b/e2e/playwright/tests/editors/overlays/etalons/Toolbar after items rebinding if it was visible with items on init (fluent-next.blue.light).png new file mode 100644 index 000000000000..61f0500b8433 Binary files /dev/null and b/e2e/playwright/tests/editors/overlays/etalons/Toolbar after items rebinding if it was visible with items on init (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/overlays/etalons/Toolbar after items rebinding if it was visible with items on init (fluent.blue.light).png b/e2e/playwright/tests/editors/overlays/etalons/Toolbar after items rebinding if it was visible with items on init (fluent.blue.light).png new file mode 100644 index 000000000000..b1f21fa403b5 Binary files /dev/null and b/e2e/playwright/tests/editors/overlays/etalons/Toolbar after items rebinding if it was visible with items on init (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/overlays/etalons/Toolbar before items rebinding if it was hidden without items on init (fluent-next.blue.light).png b/e2e/playwright/tests/editors/overlays/etalons/Toolbar before items rebinding if it was hidden without items on init (fluent-next.blue.light).png new file mode 100644 index 000000000000..db2442ecf4c7 Binary files /dev/null and b/e2e/playwright/tests/editors/overlays/etalons/Toolbar before items rebinding if it was hidden without items on init (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/overlays/etalons/Toolbar before items rebinding if it was hidden without items on init (fluent.blue.light).png b/e2e/playwright/tests/editors/overlays/etalons/Toolbar before items rebinding if it was hidden without items on init (fluent.blue.light).png new file mode 100644 index 000000000000..6ffc325a4f10 Binary files /dev/null and b/e2e/playwright/tests/editors/overlays/etalons/Toolbar before items rebinding if it was hidden without items on init (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/overlays/etalons/Toolbar before items rebinding if it was visible with items on init (fluent-next.blue.light).png b/e2e/playwright/tests/editors/overlays/etalons/Toolbar before items rebinding if it was visible with items on init (fluent-next.blue.light).png new file mode 100644 index 000000000000..db2442ecf4c7 Binary files /dev/null and b/e2e/playwright/tests/editors/overlays/etalons/Toolbar before items rebinding if it was visible with items on init (fluent-next.blue.light).png differ diff --git a/e2e/playwright/tests/editors/overlays/etalons/Toolbar before items rebinding if it was visible with items on init (fluent.blue.light).png b/e2e/playwright/tests/editors/overlays/etalons/Toolbar before items rebinding if it was visible with items on init (fluent.blue.light).png new file mode 100644 index 000000000000..6ffc325a4f10 Binary files /dev/null and b/e2e/playwright/tests/editors/overlays/etalons/Toolbar before items rebinding if it was visible with items on init (fluent.blue.light).png differ diff --git a/e2e/playwright/tests/editors/overlays/popup.drag.spec.ts b/e2e/playwright/tests/editors/overlays/popup.drag.spec.ts new file mode 100644 index 000000000000..397a2d87d5c5 --- /dev/null +++ b/e2e/playwright/tests/editors/overlays/popup.drag.spec.ts @@ -0,0 +1,116 @@ +import type { Page } from '@playwright/test'; +import { expect, test } from '../../../fixtures'; +import { createWidget } from '../../../helpers/createWidget'; +import { appendElementTo } from '../../../helpers/domUtils'; +import { dragToOffset } from '../../../helpers/dragUtils'; +import Popup from '../../../models/popup'; +import { getRect } from './utils'; + +const renderSwatchScope = (page: Page): Promise => page.evaluate(() => { + const host = document.createElement('div'); + + host.id = 'swatchHost'; + host.innerHTML = '
' + + '
' + + '
'; + + document.body.appendChild(host); + + (window as any).DevExpress.viewPort('#swatchViewPort'); +}); + +test.describe('Popup', () => { + test.describe(() => { + test.use({ browserSize: [700, 700] }); + + test('Popup can not be dragged outside of the container (window)', async ({ page }) => { + await createWidget(page, 'dxPopup', { + width: 100, + height: 100, + visible: true, + dragEnabled: true, + animation: undefined, + }); + + const popup = new Popup(page, '#container'); + const content = popup.getContent(); + const toolbar = popup.getToolbar(); + + await dragToOffset(page, toolbar, -10000, -10000); + + await expect.poll(async () => (await getRect(content)).top).toBe(0); + await expect.poll(async () => (await getRect(content)).left).toBe(0); + + await dragToOffset(page, toolbar, 10000, 10000); + + await expect.poll(async () => (await getRect(content)).bottom).toBe(700); + await expect.poll(async () => (await getRect(content)).right).toBe(700); + }); + }); + + test('Popup can not be dragged if content bigger than container', async ({ page }) => { + await appendElementTo(page, '#container', 'div', 'popup'); + await appendElementTo(page, '#container', 'div', 'popupContainer', { width: '99px', height: '99px' }); + await createWidget(page, 'dxPopup', { + position: { of: '#popupContainer' }, + container: '#popupContainer', + visible: true, + width: 100, + height: 100, + animation: undefined, + }, '#popup'); + + const popup = new Popup(page, '#popup'); + const content = popup.getContent(); + const { top, left } = await getRect(content); + + await dragToOffset(page, popup.getToolbar(), 50, 50); + + await expect.poll(async () => (await getRect(content)).top).toBe(top); + await expect.poll(async () => (await getRect(content)).left).toBe(left); + }); + + test('Popup can be dragged outside of the container if dragOutsideBoundary is enabled', async ({ page }) => { + await createWidget(page, 'dxPopup', { + width: 100, + height: 100, + visible: true, + dragEnabled: true, + dragOutsideBoundary: true, + animation: undefined, + }); + + const popup = new Popup(page, '#container'); + const content = popup.getContent(); + + await dragToOffset(page, popup.getToolbar(), -10000, -10000); + + await expect.poll(async () => (await getRect(content)).top).toBeLessThan(0); + await expect.poll(async () => (await getRect(content)).left).toBeLessThan(0); + }); + + test.describe(() => { + test.use({ browserSize: [700, 700] }); + + test('Popup inside a swatch can be dragged', async ({ page }) => { + await renderSwatchScope(page); + await createWidget(page, 'dxPopup', { + width: 100, + height: 100, + visible: true, + dragEnabled: true, + animation: undefined, + position: { of: '#swatchViewPort' }, + wrapperAttr: { class: 'swatch-popup' }, + }, '#swatchPopup'); + + const popup = new Popup(page, '.swatch-popup'); + const { top, left } = await getRect(popup.content); + + await dragToOffset(page, popup.getToolbar(), 50, 50); + + await expect.poll(async () => (await getRect(popup.content)).top).toBe(top + 50); + await expect.poll(async () => (await getRect(popup.content)).left).toBe(left + 50); + }); + }); +}); diff --git a/e2e/playwright/tests/editors/overlays/popup.spec.ts b/e2e/playwright/tests/editors/overlays/popup.spec.ts new file mode 100644 index 000000000000..71ae5bcabdff --- /dev/null +++ b/e2e/playwright/tests/editors/overlays/popup.spec.ts @@ -0,0 +1,103 @@ +import type { Page } from '@playwright/test'; +import { expect, test } from '../../../fixtures'; +import { createWidget } from '../../../helpers/createWidget'; +import { appendElementTo, setStyleAttribute } from '../../../helpers/domUtils'; +import Popup from '../../../models/popup'; +import { expectCentered, expectCenteredInWindow, getRect } from './utils'; + +const waitForShownPopups = (page: Page, count: number): Promise => page.waitForFunction( + (expected) => (window as any).shownPopups === expected, + count, +); + +const createPopupInAnimatedContainer = async (page: Page): Promise => { + await appendElementTo(page, '#container', 'div', 'content'); + await setStyleAttribute(page, '#content', 'width: 100%; height: 100%;'); + await createWidget(page, 'dxPopup', () => ({ + width: 600, + height: 400, + visible: true, + onShown: () => { + (window as any).shownPopups = ((window as any).shownPopups ?? 0) + 1; + }, + }), undefined, { disableFxAnimation: false }); + + await appendElementTo(page, '#container', 'div', 'innerContainer'); + await waitForShownPopups(page, 1); + + await createWidget(page, 'dxPopup', () => ({ + position: { of: '#content' }, + container: '#content', + visible: true, + width: 100, + height: 100, + onShown: () => { + (window as any).shownPopups = ((window as any).shownPopups ?? 0) + 1; + }, + }), '#innerContainer', { disableFxAnimation: false }); +}; + +test.describe('Popup', () => { + test('Popup should be centered regarding the container even if container is animated (T920408)', async ({ page }) => { + await createPopupInAnimatedContainer(page); + await waitForShownPopups(page, 2); + + const wrapper = page.locator('#content .dx-overlay-wrapper'); + const content = wrapper.locator('.dx-overlay-content'); + + await expectCentered(wrapper, content); + }); + + test('Popup wrapper left top corner should be the same as the container right left corner even if container is animated', async ({ page }) => { + await createPopupInAnimatedContainer(page); + await waitForShownPopups(page, 2); + + const wrapper = page.locator('#content .dx-overlay-wrapper'); + const container = wrapper.locator('..'); + + const getCornerOffset = async (): Promise<{ top: number; left: number }> => { + const wrapperRect = await getRect(wrapper); + const containerRect = await getRect(container); + + return { + top: Math.abs(wrapperRect.top - containerRect.top), + left: Math.abs(wrapperRect.left - containerRect.left), + }; + }; + + await expect.poll(async () => (await getCornerOffset()).top).toBeLessThanOrEqual(0.5); + await expect.poll(async () => (await getCornerOffset()).left).toBeLessThanOrEqual(0.5); + }); + + test('There should not be any errors when position.of is html (T946851)', async ({ page }) => { + await createWidget(page, 'dxPopup', { + position: { of: 'html' }, + visible: true, + }); + }); + + test('Popup should be centered regarding the window after position.boundary is set to window', async ({ page }) => { + await createWidget(page, 'dxPopup', { + width: 300, + height: 200, + visible: true, + animation: undefined, + position: { + boundary: '#otherContainer', + collision: 'fit', + }, + }, undefined, { disableFxAnimation: false }); + + const popup = new Popup(page, '#container'); + const content = popup.getContent(); + const boundaryRect = await getRect(page.locator('#otherContainer')); + + await expect.poll(async () => (await getRect(content)).top).toBe(boundaryRect.top); + + await popup.element.evaluate((element) => { + ($(element) as any).dxPopup('instance').option('position.boundary', window); + }); + + await expectCenteredInWindow(content); + }); +}); diff --git a/e2e/playwright/tests/editors/overlays/resizeObserverIntegration.spec.ts b/e2e/playwright/tests/editors/overlays/resizeObserverIntegration.spec.ts new file mode 100644 index 000000000000..d2a15fc9b207 --- /dev/null +++ b/e2e/playwright/tests/editors/overlays/resizeObserverIntegration.spec.ts @@ -0,0 +1,130 @@ +import type { Page } from '@playwright/test'; +import { expect, test } from '../../../fixtures'; +import { createWidget } from '../../../helpers/createWidget'; +import { setStyleAttribute } from '../../../helpers/domUtils'; +import Popup from '../../../models/popup'; +import { expectCentered, getRect } from './utils'; + +const createAutoSizedPopup = ( + page: Page, + extraOptions: Record = {}, +): Promise => createWidget( + page, + 'dxPopup', + (options) => ({ + width: 'auto', + height: 'auto', + contentTemplate: () => $('
').attr({ id: 'content' }).css({ width: '100px', height: '100px' }), + ...options, + }), + undefined, + { disableFxAnimation: false, arg: extraOptions }, +); + +test.describe('Popup', () => { + test('Popup should be centered regarding the container even if content dimension is changed during animation', async ({ page }) => { + await createAutoSizedPopup(page); + + const popup = new Popup(page, '#container'); + + await popup.show(); + await setStyleAttribute(page, '#content', 'width: 300px; height: 300px;'); + + await expectCentered(popup.getWrapper(), popup.getContent()); + }); + + test('Popup should be centered regarding the container even if popup dimension option is changed during animation', async ({ page }) => { + await createAutoSizedPopup(page); + + const popup = new Popup(page, '#container'); + + await popup.show(); + await setStyleAttribute(page, '#content', 'width: 300px; height: 300px;'); + + await expectCentered(popup.getWrapper(), popup.getContent()); + }); + + test('Popup should be centered regarding the container even if content dimension is changed', async ({ page }) => { + await createAutoSizedPopup(page, { animation: null }); + + const popup = new Popup(page, '#container'); + + await popup.show(); + await setStyleAttribute(page, '#content', 'width: 300px; height: 300px;'); + + await expectCentered(popup.getWrapper(), popup.getContent()); + }); + + test.describe(() => { + test.use({ browserSize: [200, 200] }); + + test('popup should be repositioned after window resize', async ({ page }) => { + await createWidget(page, 'dxPopup', { + animation: null, + visible: true, + width: 100, + height: 100, + }, undefined, { disableFxAnimation: false }); + + const popup = new Popup(page, '#container'); + + await expectCentered(popup.getWrapper(), popup.getContent()); + }); + }); + + test('Popup dimensions should be correct after width or height animation', async ({ page }) => { + await createWidget(page, 'dxPopup', () => ({ + visible: true, + animation: { + show: { + from: { width: '10px', height: '10px' }, + to: { width: '300px', height: '300px' }, + }, + }, + onShown: () => { + (window as any).popupShown = true; + }, + }), undefined, { disableFxAnimation: false }); + + const popup = new Popup(page, '#container'); + const content = popup.getContent(); + + await page.waitForFunction(() => (window as any).popupShown === true); + + await expect.poll(async () => (await getRect(content)).width).toBe(300); + await expect.poll(async () => (await getRect(content)).height).toBe(300); + }); + + test('Showing and shown events should be raised only once even after resize during animation', async ({ page }) => { + await createAutoSizedPopup(page); + + const popup = new Popup(page, '#container'); + + await page.evaluate(() => { + (window as any).shownCallCount = 0; + (window as any).showingCallCount = 0; + }); + + await popup.element.evaluate((element) => { + ($(element) as any).dxPopup('instance').option({ + onShown: () => { (window as any).shownCallCount += 1; }, + onShowing: () => { (window as any).showingCallCount += 1; }, + }); + }); + + const shownCallCountAtResize = await popup.element.evaluate((element) => { + ($(element) as any).dxPopup('instance').show(); + $('#content').css({ width: '300px', height: '300px' }); + + return (window as any).shownCallCount; + }); + + expect(shownCallCountAtResize).toBe(0); + + await page.waitForFunction(() => (window as any).shownCallCount > 0 + && !(window as any).DevExpress.fx.isAnimating(document.querySelector('.dx-overlay-content'))); + + await expect.poll(() => page.evaluate(() => (window as any).shownCallCount)).toBe(1); + await expect.poll(() => page.evaluate(() => (window as any).showingCallCount)).toBe(1); + }); +}); diff --git a/e2e/playwright/tests/editors/overlays/scrolling.spec.ts b/e2e/playwright/tests/editors/overlays/scrolling.spec.ts new file mode 100644 index 000000000000..db05871b5fd9 --- /dev/null +++ b/e2e/playwright/tests/editors/overlays/scrolling.spec.ts @@ -0,0 +1,132 @@ +/* eslint-disable no-multi-str */ +import type { Page } from '@playwright/test'; +import { expect, test } from '../../../fixtures'; +import { createWidget } from '../../../helpers/createWidget'; +import { + appendElementTo, + getDocumentScrollTop, + insertStylesheetRulesToPage, +} from '../../../helpers/domUtils'; +import Popup from '../../../models/popup'; + +const POPUP_CONTENT_CLASS = 'dx-popup-content'; + +const checkBodyStyles = async ( + page: Page, + { paddingRight, overflow }: { paddingRight: string; overflow: string }, +): Promise => { + const body = page.locator('body'); + + await expect(body).toHaveCSS('padding-right', paddingRight); + await expect(body).toHaveCSS('overflow', overflow); + await expect(body).toHaveCSS('position', 'static'); + await expect(body).toHaveCSS('top', 'auto'); + await expect(body).toHaveCSS('left', 'auto'); +}; + +const checkPopupStyles = async ( + page: Page, + { overflow, overScrollBehavior }: { overflow: string; overScrollBehavior: string }, +): Promise => { + const content = page.locator(`.${POPUP_CONTENT_CLASS}`); + + await expect(content).toHaveCSS('overflow', overflow); + await expect(content).toHaveCSS('overscroll-behavior', overScrollBehavior); +}; + +test.describe('Popup scrolling', () => { + test.use({ theme: 'generic.light' }); + + [false, true].forEach((shading) => { + [false, true].forEach((enableBodyScroll) => { + [false, true].forEach((fullScreen) => { + test(`Popup native scrolling, shading: ${shading}, enableBodyScroll: ${enableBodyScroll}, fullScreen: ${fullScreen}`, async ({ page }) => { + await appendElementTo(page, '#container', 'div', 'scrollable-container', { height: '2000px', overflowY: 'auto' }); + await appendElementTo(page, '#scrollable-container', 'div', 'scrollable-content', { height: '3000px' }); + await appendElementTo(page, '#scrollable-content', 'div', 'inner-container', { + width: '500px', height: '500px', border: '1px solid black', overflow: 'auto', + }); + + await page.evaluate(() => { + const $content = $('
'); + + for (let i = 0; i < 100; i += 1) { + $content.append(`
${i}
`); + } + + $('#scrollable-content').append($content); + }); + + await appendElementTo(page, '#inner-container', 'div', 'inner-content', { width: '2000px', height: '2000px' }); + await appendElementTo(page, '#scrollable-container', 'div', 'popup'); + + await createWidget(page, 'dxPopup', (options) => ({ + ...options, + width: 400, + height: 400, + contentTemplate: ($content) => { + const popupContent = '\ +
Description
\ +
In the heart of LA\'s business district, the Downtown Inn has a welcoming staff and award winning restaurants that remain open 24 hours a day. Use our conference room facilities to conduct meetings and have a drink at our beautiful rooftop bar.
\ +
\ +
\ +
\ +
Features
\ +
\ +
Concierge
\ +
Restaurant
\ +
Valet Parking
\ +
Fitness Center
\ +
Sauna
\ +
Airport Shuttle
\ +
\ +
\ +
\ +
\ +
Rooms
\ +
\ +
Climate control
\ +
Air conditioning
\ +
Coffee/tea maker
\ +
Iron/ironing
\ +
\ +
\ +
\ +
\ +
In the heart of LA\'s business district, the Downtown Inn has a welcoming staff and award winning restaurants that remain open 24 hours a day. Use our conference room facilities to conduct meetings and have a drink at our beautiful rooftop bar.
\ + '; + + $content.html(popupContent); + }, + }), '#popup', { arg: { shading, enableBodyScroll, fullScreen } }); + + const popup = new Popup(page, '#popup'); + + await checkBodyStyles(page, { paddingRight: '0px', overflow: 'visible' }); + + await insertStylesheetRulesToPage(page, 'body { padding-right: 10px; overflow: auto; }'); + + await page.evaluate(() => { + window.scrollTo(0, 300); + }); + + await expect.poll(() => getDocumentScrollTop(page)).toBe(300); + + await checkBodyStyles(page, { paddingRight: '10px', overflow: 'auto' }); + await expect.poll(() => getDocumentScrollTop(page)).toBe(300); + + await popup.show(); + + await checkPopupStyles(page, { overflow: 'auto', overScrollBehavior: 'contain' }); + await checkBodyStyles(page, { paddingRight: enableBodyScroll ? '10px' : '25px', overflow: enableBodyScroll ? 'auto' : 'hidden' }); + await expect.poll(() => getDocumentScrollTop(page)).toBe(300); + + await popup.hide(); + + await checkBodyStyles(page, { paddingRight: '10px', overflow: 'auto' }); + await expect.poll(() => getDocumentScrollTop(page)).toBe(300); + }); + }); + }); + }); +}); diff --git a/e2e/playwright/tests/editors/overlays/toast.spec.ts b/e2e/playwright/tests/editors/overlays/toast.spec.ts new file mode 100644 index 000000000000..d88bca149bea --- /dev/null +++ b/e2e/playwright/tests/editors/overlays/toast.spec.ts @@ -0,0 +1,38 @@ +import { test } from '../../../fixtures'; +import { insertStylesheetRulesToPage, setClassAttribute } from '../../../helpers/domUtils'; +import { testScreenshot } from '../../../helpers/screenshots'; +import { getThemeName } from '../../../helpers/themeUtils'; + +const types = ['info', 'warning', 'error', 'success']; +const STACK_CONTAINER_SELECTOR = '.dx-toast-stack'; + +test.describe('Toast', () => { + test('Toasts', async ({ page, theme }) => { + for (const type of types) { + await page.evaluate((toastType) => { + (window as any).DevExpress.ui.notify( + { + message: `Toast ${toastType}`, + type: toastType, + displayTime: 35000000, + animation: { + show: { + type: 'fade', duration: 0, + }, + hide: { type: 'fade', duration: 0 }, + }, + }, + { + position: 'top center', + direction: 'down-push', + }, + ); + }, type); + } + + await insertStylesheetRulesToPage(page, `${STACK_CONTAINER_SELECTOR} { padding: 20px; }`); + await setClassAttribute(page, STACK_CONTAINER_SELECTOR, `dx-theme-${getThemeName(theme)}-typography`); + + await testScreenshot(page, 'Toasts.png', { element: STACK_CONTAINER_SELECTOR }); + }); +}); diff --git a/e2e/playwright/tests/editors/overlays/toolbarIntegration.spec.ts b/e2e/playwright/tests/editors/overlays/toolbarIntegration.spec.ts new file mode 100644 index 000000000000..26573f418991 --- /dev/null +++ b/e2e/playwright/tests/editors/overlays/toolbarIntegration.spec.ts @@ -0,0 +1,231 @@ +import { test } from '../../../fixtures'; +import { createWidget } from '../../../helpers/createWidget'; +import { insertStylesheetRulesToPage } from '../../../helpers/domUtils'; +import { testScreenshot } from '../../../helpers/screenshots'; +import { isMaterial } from '../../../helpers/themeUtils'; +import Popover from '../../../models/popover'; +import Popup from '../../../models/popup'; +import Toolbar from '../../../models/toolbar'; + +const COMPONENT_SELECTOR = '#container'; +const CLOSE_BUTTON_SELECTOR = '.dx-closebutton'; + +test.describe('Popup_toolbar', () => { + test.describe(() => { + test.use({ browserSize: [600, 400] }); + + [ + { name: 'dxPopup' as const, Model: Popup }, + { name: 'dxPopover' as const, Model: Popover }, + ].forEach(({ name, Model }) => { + ['bottom', 'top'].forEach((toolbar) => { + [true, false].forEach((rtlEnabled) => { + test(`Extended toolbar should be used in ${name},rtlEnabled=${rtlEnabled},toolbar=${toolbar}`, async ({ page, theme }) => { + if (isMaterial(theme)) { + await insertStylesheetRulesToPage(page, '.dx-overlay-content, .dx-overlay-content input { font-family: sans-serif !important; }'); + } + + await createWidget(page, name, ({ target, toolbarName, rtl }) => ({ + showCloseButton: true, + // eslint-disable-next-line no-multi-str + contentTemplate: () => $('
').text('\ + Lorem Ipsum is simply dummy text of the printing and typesetting industry.\ + Lorem Ipsum has been the industrys standard dummy text ever since the 1500s,\ + when an unknown printer took a galley of type and scrambled it to make a type specimen book.\ + '), + width: '60%', + height: 300, + showTitle: true, + rtlEnabled: rtl, + visible: true, + animation: undefined, + target, + hideOnOutsideClick: true, + toolbarItems: [{ + location: 'before', + widget: 'dxButton', + options: { + icon: 'back', + }, + toolbar: toolbarName, + }, { + location: 'before', + widget: 'dxButton', + locateInMenu: 'auto', + options: { + icon: 'refresh', + }, + toolbar: toolbarName, + }, { + location: 'center', + locateInMenu: 'never', + template() { + return $('
Popup\'s title
'); + }, + toolbar: toolbarName, + }, { + location: 'after', + widget: 'dxSelectBox', + locateInMenu: 'auto', + options: { + width: 140, + items: [1, 2, 3, 4, 5], + value: 3, + }, + toolbar: toolbarName, + }, { + location: 'after', + widget: 'dxButton', + locateInMenu: 'auto', + options: { + icon: 'plus', + }, + toolbar: toolbarName, + }, { + locateInMenu: 'always', + widget: 'dxButton', + options: { + icon: 'save', + text: 'Save', + }, + toolbar: toolbarName, + }, { + widget: 'dxButton', + toolbar: toolbarName === 'top' + ? 'bottom' + : 'top', + location: 'before', + options: { + icon: 'email', + }, + }, { + widget: 'dxButton', + toolbar: toolbarName === 'top' + ? 'bottom' + : 'top', + location: 'after', + options: { + text: 'Close', + }, + }], + }), COMPONENT_SELECTOR, { + arg: { target: COMPONENT_SELECTOR, toolbarName: toolbar, rtl: rtlEnabled }, + }); + + const instance = new Model(page, COMPONENT_SELECTOR); + const menuToolbar = new Toolbar( + page, + toolbar === 'top' ? instance.getToolbar() : instance.getBottomToolbar(), + ); + + await menuToolbar.option('overflowMenuVisible', true); + + await page.locator(CLOSE_BUTTON_SELECTOR).hover(); + + await testScreenshot(page, `${name.replace('dx', '')}_${toolbar}_toolbar_menu,rtlEnabled=${rtlEnabled}.png`); + }); + }); + }); + }); + }); + + test.describe(() => { + test.use({ browserSize: [600, 600] }); + + const getItemConfig = ( + text: string, + toolbar: 'top' | 'bottom' = 'top', + location: 'before' | 'center' | 'after' = 'after', + locateInMenu: 'auto' | 'none' = 'none', + ): Record => ({ + text, + toolbar, + locateInMenu, + location, + }); + + const toolbarItems = [ + getItemConfig('First Item'), + getItemConfig('Second Item', 'top', 'after', 'auto'), + getItemConfig('Third Item', 'top', 'after', 'auto'), + getItemConfig('!@#$%^&*()-+=[]{}<>|:;.,!?~^*_(){}<>[]:-=+', 'bottom', 'before'), + getItemConfig('First Item', 'bottom'), + getItemConfig('Second Item', 'bottom', 'after', 'auto'), + getItemConfig('Third Item', 'bottom', 'after', 'auto'), + ]; + + const createPopup = ( + page: Parameters[0], + items: Record[], + visible: boolean, + ): Promise => createWidget(page, 'dxPopup', (options) => ({ + title: '!@#$%^&*()-+=[]{}<>|:;.,!?~^*_(){}<>[]:-=+', + width: 'auto', + height: 'auto', + showCloseButton: false, + contentTemplate: () => $('
') + .width(300) + .height(300), + ...options, + }), COMPONENT_SELECTOR, { arg: { toolbarItems: items, visible } }); + + const hideThirdItem = async (instance: Popup): Promise => { + const items = await instance.option('toolbarItems'); + + items[2].visible = false; + await instance.option('toolbarItems', [...items]); + }; + + test('Popup toolbars with wide elements and overflow menu if hidden on init with toolbar items', async ({ page }) => { + await createPopup(page, toolbarItems, false); + + const instance = new Popup(page, COMPONENT_SELECTOR); + + await instance.option({ visible: true }); + + await instance.getOverflowButton().element.click(); + + await testScreenshot(page, 'Popup toolbars with wide elements and overflow menu before items rebinding.png'); + + await hideThirdItem(instance); + + await instance.getOverflowButton().element.click(); + + await testScreenshot(page, 'Popup toolbars with wide elements and overflow menu after items rebinding.png'); + }); + + test('Popup toolbars with wide elements and overflow menu if hidden on init with no toolbar items', async ({ page }) => { + await createPopup(page, [], false); + + const instance = new Popup(page, COMPONENT_SELECTOR); + + await instance.option({ visible: true, toolbarItems }); + + await instance.getOverflowButton().element.click(); + + await testScreenshot(page, 'Toolbar before items rebinding if it was hidden without items on init.png'); + + await hideThirdItem(instance); + + await instance.getOverflowButton().element.click(); + + await testScreenshot(page, 'Toolbar after items rebinding if it was hidden without items on init.png'); + }); + + test('Popup toolbars with wide elements and overflow menu if shown on init with toolbar items', async ({ page }) => { + await createPopup(page, toolbarItems, true); + + const instance = new Popup(page, COMPONENT_SELECTOR); + + await instance.getOverflowButton().element.click(); + + await testScreenshot(page, 'Toolbar before items rebinding if it was visible with items on init.png'); + + await hideThirdItem(instance); + + await instance.getOverflowButton().element.click(); + + await testScreenshot(page, 'Toolbar after items rebinding if it was visible with items on init.png'); + }); + }); +}); diff --git a/e2e/playwright/tests/editors/overlays/utils.ts b/e2e/playwright/tests/editors/overlays/utils.ts new file mode 100644 index 000000000000..00abba56d5e0 --- /dev/null +++ b/e2e/playwright/tests/editors/overlays/utils.ts @@ -0,0 +1,68 @@ +import type { Locator } from '@playwright/test'; +import { expect } from '../../../fixtures'; + +export interface Rect { + top: number; + right: number; + bottom: number; + left: number; + width: number; + height: number; +} + +export const getRect = (locator: Locator): Promise => locator.evaluate((element) => { + const { + top, right, bottom, left, width, height, + } = element.getBoundingClientRect(); + + return { + top, right, bottom, left, width, height, + }; +}); + +interface CenterOffset { + vertical: number; + horizontal: number; +} + +const centerOf = (rect: Rect): { x: number; y: number } => ({ + x: (rect.left + rect.right) / 2, + y: (rect.top + rect.bottom) / 2, +}); + +const getCenterOffset = async (outer: Locator, inner: Locator): Promise => { + const outerCenter = centerOf(await getRect(outer)); + const innerCenter = centerOf(await getRect(inner)); + + return { + vertical: Math.abs(outerCenter.y - innerCenter.y), + horizontal: Math.abs(outerCenter.x - innerCenter.x), + }; +}; + +const getWindowCenterOffset = async (locator: Locator): Promise => { + const center = centerOf(await getRect(locator)); + const { innerWidth, innerHeight } = await locator.page().evaluate( + () => ({ innerWidth: window.innerWidth, innerHeight: window.innerHeight }), + ); + + return { + vertical: Math.abs(innerHeight / 2 - center.y), + horizontal: Math.abs(innerWidth / 2 - center.x), + }; +}; + +const expectCenterOffsetWithinHalfPixel = async ( + getOffset: () => Promise, +): Promise => { + await expect.poll(async () => (await getOffset()).vertical).toBeLessThanOrEqual(0.5); + await expect.poll(async () => (await getOffset()).horizontal).toBeLessThanOrEqual(0.5); +}; + +export const expectCentered = (outer: Locator, inner: Locator): Promise => ( + expectCenterOffsetWithinHalfPixel(() => getCenterOffset(outer, inner)) +); + +export const expectCenteredInWindow = (locator: Locator): Promise => ( + expectCenterOffsetWithinHalfPixel(() => getWindowCenterOffset(locator)) +); diff --git a/e2e/testcafe-devextreme/tests/editors/chat/alertList.ts b/e2e/testcafe-devextreme/tests/editors/chat/alertList.ts deleted file mode 100644 index 2eaca4d23b96..000000000000 --- a/e2e/testcafe-devextreme/tests/editors/chat/alertList.ts +++ /dev/null @@ -1,78 +0,0 @@ -import { createScreenshotsComparer } from 'devextreme-screenshot-comparer'; -import Chat from 'devextreme-testcafe-models/chat'; -import { ClientFunction } from 'testcafe'; -import { createUser } from './data'; -import url from '../../../helpers/getPageUrl'; -import { createWidget } from '../../../helpers/createWidget'; -import { testScreenshot } from '../../../helpers/themeUtils'; - -fixture`ChatAlertList` - .page(url(__dirname, '../../container.html')); - -test.clientScripts([ - { module: 'mockdate' }, - { content: 'window.MockDate = MockDate;' }, -])('Alertlist appearance', async (t) => { - const { takeScreenshot, compareResults } = createScreenshotsComparer(t); - const chat = new Chat('#container'); - - await testScreenshot(t, takeScreenshot, 'Alertlist with one error.png', { element: '#container' }); - - await chat.option('alerts', [ - { id: 1, message: 'Error Message 1. Error Description...' }, - { id: 2, message: 'Error Message 2. Message was not sent' }, - { id: 3, message: 'Error Message 3. An unexpected issue occurred while processing your request. Please check your internet connection or contact support for further assistance.' }, - ]); - - await testScreenshot(t, takeScreenshot, 'Alertlist with long text in error.png', { - element: '#container', - }); - - await chat.option('rtlEnabled', true); - - await testScreenshot(t, takeScreenshot, 'Alertlist appearance in RTL mode.png', { element: '#container' }); - - await t - .expect(compareResults.isValid()) - .ok(compareResults.errorMessages()); -}).before(async () => { - await ClientFunction(() => { - (window as any).MockDate.set('2024/10/18'); - })(); - - const userFirst = createUser(1, 'First'); - const userSecond = createUser(2, 'Second'); - const msInDay = 86400000; - const today = new Date('2024/10/18').setHours(7, 22, 0, 0); - const yesterday = today - msInDay; - - const items = [{ - timestamp: yesterday, - author: userSecond, - text: 'Message text 1', - }, { - timestamp: yesterday, - author: userSecond, - text: 'Message text 2', - }, { - timestamp: today, - author: userFirst, - text: 'Message text 3', - }, { - timestamp: today, - author: userFirst, - text: 'Message text 4', - }]; - - return createWidget('dxChat', { - items, - user: userFirst, - width: 400, - height: 600, - alerts: [{ id: 1, message: 'Error Message 1. Error Description...' }], - }); -}).after(async () => { - await ClientFunction(() => { - (window as any).MockDate.reset(); - })(); -}); diff --git a/e2e/testcafe-devextreme/tests/editors/chat/avatar.ts b/e2e/testcafe-devextreme/tests/editors/chat/avatar.ts deleted file mode 100644 index 72a7bd84b118..000000000000 --- a/e2e/testcafe-devextreme/tests/editors/chat/avatar.ts +++ /dev/null @@ -1,69 +0,0 @@ -import { createScreenshotsComparer } from 'devextreme-screenshot-comparer'; -import Chat from 'devextreme-testcafe-models/chat'; -import { createUser, generateMessages, avatarUrl } from './data'; -import url from '../../../helpers/getPageUrl'; -import { createWidget } from '../../../helpers/createWidget'; -import { testScreenshot } from '../../../helpers/themeUtils'; -import { appendElementTo } from '../../../helpers/domUtils'; - -fixture.disablePageReloads`ChatAvatar` - .page(url(__dirname, '../../container.html')); - -test('Chat: avatar', async (t) => { - const { takeScreenshot, compareResults } = createScreenshotsComparer(t); - await testScreenshot(t, takeScreenshot, 'Avatar with two word initials.png', { element: '#chat' }); - - const chat = new Chat('#chat'); - - const userFirst = createUser(1, 'First', avatarUrl); - const userSecond = createUser(2, 'Second', avatarUrl); - - const items = generateMessages(2, userFirst, userSecond, false, false, 2); - - await chat.option('items', items); - - await testScreenshot(t, takeScreenshot, 'Avatar with image.png', { element: '#chat' }); - - await t - .expect(compareResults.isValid()) - .ok(compareResults.errorMessages()); -}).before(async () => { - await appendElementTo('#container', 'div', 'chat'); - - const userFirst = createUser(1, 'First User'); - const userSecond = createUser(2, 'Second User'); - - const items = generateMessages(2, userFirst, userSecond, false, false, 2); - - return createWidget('dxChat', { - width: 400, - height: 600, - user: userSecond, - items, - }, '#chat'); -}); - -test('Chat: showAvatar set to false', async (t) => { - const { takeScreenshot, compareResults } = createScreenshotsComparer(t); - - await testScreenshot(t, takeScreenshot, 'Avatar with showAvatar set to false.png', { element: '#chat' }); - - await t - .expect(compareResults.isValid()) - .ok(compareResults.errorMessages()); -}).before(async () => { - await appendElementTo('#container', 'div', 'chat'); - - const userFirst = createUser(1, 'First User'); - const userSecond = createUser(2, 'Second User'); - - const items = generateMessages(2, userFirst, userSecond, false, false, 2); - - return createWidget('dxChat', { - width: 400, - height: 600, - user: userSecond, - items, - showAvatar: false, - }, '#chat'); -}); diff --git a/e2e/testcafe-devextreme/tests/editors/chat/confirmationPopup.ts b/e2e/testcafe-devextreme/tests/editors/chat/confirmationPopup.ts deleted file mode 100644 index b94af3b675a3..000000000000 --- a/e2e/testcafe-devextreme/tests/editors/chat/confirmationPopup.ts +++ /dev/null @@ -1,44 +0,0 @@ -import { createScreenshotsComparer } from 'devextreme-screenshot-comparer'; -import Chat from 'devextreme-testcafe-models/chat'; -import { createUser } from './data'; -import url from '../../../helpers/getPageUrl'; -import { createWidget } from '../../../helpers/createWidget'; -import { testScreenshot } from '../../../helpers/themeUtils'; - -fixture.disablePageReloads`ChatConfirmationPopup`.page( - url(__dirname, '../../container.html'), -); - -test('Chat: confirmation popup', async (t) => { - const { takeScreenshot, compareResults } = createScreenshotsComparer(t); - const chat = new Chat('#container'); - - await t.rightClick(chat.getMessage(2)).pressKey('down').pressKey('enter'); - - await testScreenshot(t, takeScreenshot, 'Confirmation popup is shown.png', { - element: '#container', - }); - - await t.expect(compareResults.isValid()).ok(compareResults.errorMessages()); -}).before(async () => { - const userFirst = createUser(1, 'First'); - const userSecond = createUser(2, 'Second'); - - const items = [ - { author: userFirst, text: 'AAA' }, - { author: userFirst, text: 'BBB' }, - { author: userSecond, text: 'CCC' }, - ]; - - return createWidget('dxChat', { - items, - editing: { - allowDeleting: true, - }, - user: userSecond, - width: 400, - height: 600, - showDayHeaders: false, - rtlEnabled: true, - }); -}); diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Alertlist appearance in RTL mode (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Alertlist appearance in RTL mode (fluent-next.blue.light).png deleted file mode 100644 index 512ce32d7ec2..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Alertlist appearance in RTL mode (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Alertlist appearance in RTL mode (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Alertlist appearance in RTL mode (fluent.blue.light).png deleted file mode 100644 index 135d588d6ed2..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Alertlist appearance in RTL mode (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Alertlist with long text in error (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Alertlist with long text in error (fluent-next.blue.light).png deleted file mode 100644 index 90bad2911a69..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Alertlist with long text in error (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Alertlist with long text in error (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Alertlist with long text in error (fluent.blue.light).png deleted file mode 100644 index 4863e0b31b64..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Alertlist with long text in error (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Alertlist with one error (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Alertlist with one error (fluent-next.blue.light).png deleted file mode 100644 index e9920c87568e..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Alertlist with one error (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Alertlist with one error (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Alertlist with one error (fluent.blue.light).png deleted file mode 100644 index 678dcb9ab83b..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Alertlist with one error (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Avatar has correct position (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Avatar has correct position (fluent-next.blue.light).png deleted file mode 100644 index 78dbdde96f9a..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Avatar has correct position (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Avatar has correct position (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Avatar has correct position (fluent.blue.light).png deleted file mode 100644 index b30d76e0a760..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Avatar has correct position (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Avatar sizes do not affect indentation between bubbles (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Avatar sizes do not affect indentation between bubbles (fluent-next.blue.light).png deleted file mode 100644 index 74328856582b..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Avatar sizes do not affect indentation between bubbles (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Avatar sizes do not affect indentation between bubbles (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Avatar sizes do not affect indentation between bubbles (fluent.blue.light).png deleted file mode 100644 index c051cc58ed5f..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Avatar sizes do not affect indentation between bubbles (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Avatar with image (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Avatar with image (fluent-next.blue.light).png deleted file mode 100644 index 3ce2f8158be5..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Avatar with image (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Avatar with image (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Avatar with image (fluent.blue.light).png deleted file mode 100644 index 74780537d461..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Avatar with image (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Avatar with showAvatar set to false (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Avatar with showAvatar set to false (fluent-next.blue.light).png deleted file mode 100644 index 3eeb812331ab..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Avatar with showAvatar set to false (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Avatar with showAvatar set to false (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Avatar with showAvatar set to false (fluent.blue.light).png deleted file mode 100644 index 7b97daed1c0d..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Avatar with showAvatar set to false (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Avatar with two word initials (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Avatar with two word initials (fluent-next.blue.light).png deleted file mode 100644 index 8f669f55d3a1..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Avatar with two word initials (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Avatar with two word initials (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Avatar with two word initials (fluent.blue.light).png deleted file mode 100644 index 3074065578c2..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Avatar with two word initials (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Bubble with files without text (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Bubble with files without text (fluent-next.blue.light).png deleted file mode 100644 index 1ba11fc729de..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Bubble with files without text (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Bubble with files without text (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Bubble with files without text (fluent.blue.light).png deleted file mode 100644 index 50323ee170bc..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Bubble with files without text (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Bubbles with files (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Bubbles with files (fluent-next.blue.light).png deleted file mode 100644 index a3fd84630187..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Bubbles with files (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Bubbles with files (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Bubbles with files (fluent.blue.light).png deleted file mode 100644 index 5cd4c390bb8e..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Bubbles with files (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Bubbles with images (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Bubbles with images (fluent-next.blue.light).png deleted file mode 100644 index cf1467759325..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Bubbles with images (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Bubbles with images (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Bubbles with images (fluent.blue.light).png deleted file mode 100644 index bdf0c07dc555..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Bubbles with images (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Bubbles with long text (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Bubbles with long text (fluent-next.blue.light).png deleted file mode 100644 index e0bb06a9f862..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Bubbles with long text (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Bubbles with long text (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Bubbles with long text (fluent.blue.light).png deleted file mode 100644 index 473eea7170d5..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Bubbles with long text (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Bubbles with long text with line breaks (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Bubbles with long text with line breaks (fluent-next.blue.light).png deleted file mode 100644 index 9f0b6ebdf08a..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Bubbles with long text with line breaks (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Bubbles with long text with line breaks (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Bubbles with long text with line breaks (fluent.blue.light).png deleted file mode 100644 index 729e434d2a55..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Bubbles with long text with line breaks (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Chat suggestions outside of a chat (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Chat suggestions outside of a chat (fluent-next.blue.light).png deleted file mode 100644 index 20a0759fde79..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Chat suggestions outside of a chat (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Confirmation popup is shown (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Confirmation popup is shown (fluent-next.blue.light).png deleted file mode 100644 index 6805a64882ac..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Confirmation popup is shown (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Confirmation popup is shown (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Confirmation popup is shown (fluent.blue.light).png deleted file mode 100644 index 595aaa412d62..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Confirmation popup is shown (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Information row with long user name (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Information row with long user name (fluent-next.blue.light).png deleted file mode 100644 index d11f246eee1c..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Information row with long user name (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Information row with long user name (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Information row with long user name (fluent.blue.light).png deleted file mode 100644 index f9bb626e841e..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Information row with long user name (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/MessageGroup with edited messages (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/MessageGroup with edited messages (fluent-next.blue.light).png deleted file mode 100644 index 7c56e36657d3..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/MessageGroup with edited messages (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/MessageGroup with edited messages (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/MessageGroup with edited messages (fluent.blue.light).png deleted file mode 100644 index 60f93323698d..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/MessageGroup with edited messages (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagebox when chat has focus (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagebox when chat has focus (fluent-next.blue.light).png deleted file mode 100644 index e11ab8f6afc3..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagebox when chat has focus (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagebox when chat has focus (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagebox when chat has focus (fluent.blue.light).png deleted file mode 100644 index 3290d6366e24..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagebox when chat has focus (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagebox when input contains long text (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagebox when input contains long text (fluent-next.blue.light).png deleted file mode 100644 index 644c47e8918c..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagebox when input contains long text (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagebox when input contains long text (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagebox when input contains long text (fluent.blue.light).png deleted file mode 100644 index a7609341cf18..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagebox when input contains long text (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagebox when input contains short text (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagebox when input contains short text (fluent-next.blue.light).png deleted file mode 100644 index 8a74ee6135b6..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagebox when input contains short text (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagebox when input contains short text (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagebox when input contains short text (fluent.blue.light).png deleted file mode 100644 index 31aa9a7e0ab5..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagebox when input contains short text (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagebox when send button has focus (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagebox when send button has focus (fluent-next.blue.light).png deleted file mode 100644 index 5c11ad6eef3a..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagebox when send button has focus (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagebox when send button has focus (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagebox when send button has focus (fluent.blue.light).png deleted file mode 100644 index f3495eebf482..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagebox when send button has focus (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagebox with attachments and informer (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagebox with attachments and informer (fluent-next.blue.light).png deleted file mode 100644 index 4dc8a475145c..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagebox with attachments and informer (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagebox with attachments and informer (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagebox with attachments and informer (fluent.blue.light).png deleted file mode 100644 index f15982a7e6d5..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagebox with attachments and informer (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagebox with editing preview (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagebox with editing preview (fluent-next.blue.light).png deleted file mode 100644 index 150ac762d409..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagebox with editing preview (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagebox with editing preview (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagebox with editing preview (fluent.blue.light).png deleted file mode 100644 index 7bdfdad79a10..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagebox with editing preview (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagegroup appearance in RTL mode (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagegroup appearance in RTL mode (fluent-next.blue.light).png deleted file mode 100644 index b6c788d8d54c..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagegroup appearance in RTL mode (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagegroup appearance in RTL mode (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagegroup appearance in RTL mode (fluent.blue.light).png deleted file mode 100644 index 2d1b96595b2d..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagegroup appearance in RTL mode (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagegroup appearance in disabled state (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagegroup appearance in disabled state (fluent-next.blue.light).png deleted file mode 100644 index 6ca6857da439..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagegroup appearance in disabled state (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagegroup appearance in disabled state (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagegroup appearance in disabled state (fluent.blue.light).png deleted file mode 100644 index 2f93330049a3..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagegroup appearance in disabled state (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagegroup with 1 bubble (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagegroup with 1 bubble (fluent-next.blue.light).png deleted file mode 100644 index 39a53b4d555f..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagegroup with 1 bubble (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagegroup with 1 bubble (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagegroup with 1 bubble (fluent.blue.light).png deleted file mode 100644 index d919681062c3..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagegroup with 1 bubble (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagegroup with 2 bubbles (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagegroup with 2 bubbles (fluent-next.blue.light).png deleted file mode 100644 index eced13b0ccc7..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagegroup with 2 bubbles (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagegroup with 2 bubbles (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagegroup with 2 bubbles (fluent.blue.light).png deleted file mode 100644 index 3d8f12fa1a1f..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagegroup with 2 bubbles (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagegroup with 3 bubbles (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagegroup with 3 bubbles (fluent-next.blue.light).png deleted file mode 100644 index ec6a5fefa147..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagegroup with 3 bubbles (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagegroup with 3 bubbles (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagegroup with 3 bubbles (fluent.blue.light).png deleted file mode 100644 index 7db16ef0c7c6..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagegroup with 3 bubbles (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagegroup with 4 bubbles (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagegroup with 4 bubbles (fluent-next.blue.light).png deleted file mode 100644 index 1edf0db4dcd5..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagegroup with 4 bubbles (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagegroup with 4 bubbles (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagegroup with 4 bubbles (fluent.blue.light).png deleted file mode 100644 index 15f1119b1670..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagegroup with 4 bubbles (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist empty in RTL mode (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist empty in RTL mode (fluent-next.blue.light).png deleted file mode 100644 index ab18075a0e6c..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist empty in RTL mode (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist empty in RTL mode (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist empty in RTL mode (fluent.blue.light).png deleted file mode 100644 index edf3ecd5ad49..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist empty in RTL mode (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist empty in disabled state (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist empty in disabled state (fluent-next.blue.light).png deleted file mode 100644 index 08ef97069a9e..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist empty in disabled state (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist empty in disabled state (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist empty in disabled state (fluent.blue.light).png deleted file mode 100644 index ef4dc3a555d0..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist empty in disabled state (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist empty state (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist empty state (fluent-next.blue.light).png deleted file mode 100644 index d7690b3681ec..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist empty state (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist empty state (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist empty state (fluent.blue.light).png deleted file mode 100644 index 05bb2b542c86..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist empty state (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist empty with limited dimensions (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist empty with limited dimensions (fluent-next.blue.light).png deleted file mode 100644 index 0361cee26efc..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist empty with limited dimensions (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist empty with limited dimensions (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist empty with limited dimensions (fluent.blue.light).png deleted file mode 100644 index cfca43caf2c8..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist empty with limited dimensions (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist scroll position after rendering in invisible container (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist scroll position after rendering in invisible container (fluent-next.blue.light).png deleted file mode 100644 index 3e0bfcdf54ee..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist scroll position after rendering in invisible container (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist scroll position after rendering in invisible container (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist scroll position after rendering in invisible container (fluent.blue.light).png deleted file mode 100644 index a46f138249e4..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist scroll position after rendering in invisible container (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist scrollbar middle position after typing in textarea (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist scrollbar middle position after typing in textarea (fluent-next.blue.light).png deleted file mode 100644 index 37a062add848..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist scrollbar middle position after typing in textarea (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist scrollbar middle position after typing in textarea (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist scrollbar middle position after typing in textarea (fluent.blue.light).png deleted file mode 100644 index 6d17ec177e5b..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist scrollbar middle position after typing in textarea (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist scrollbar position after call renderMessage() (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist scrollbar position after call renderMessage() (fluent-next.blue.light).png deleted file mode 100644 index 111a138cb2db..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist scrollbar position after call renderMessage() (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist scrollbar position after call renderMessage() (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist scrollbar position after call renderMessage() (fluent.blue.light).png deleted file mode 100644 index 4b7957c26a24..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist scrollbar position after call renderMessage() (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist scrollbar position after send (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist scrollbar position after send (fluent-next.blue.light).png deleted file mode 100644 index 0c0485babef7..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist scrollbar position after send (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist scrollbar position after send (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist scrollbar position after send (fluent.blue.light).png deleted file mode 100644 index 5dfade640acd..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist scrollbar position after send (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist scrollbar position after typing in textarea (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist scrollbar position after typing in textarea (fluent-next.blue.light).png deleted file mode 100644 index 4fa7738e2d02..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist scrollbar position after typing in textarea (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist scrollbar position after typing in textarea (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist scrollbar position after typing in textarea (fluent.blue.light).png deleted file mode 100644 index 6479dd753958..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist scrollbar position after typing in textarea (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist scrollbar position after typing in textarea (fluent.blue.light)_mask.png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist scrollbar position after typing in textarea (fluent.blue.light)_mask.png deleted file mode 100644 index fb572bd17ab6..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist scrollbar position after typing in textarea (fluent.blue.light)_mask.png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist with a lot of messages (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist with a lot of messages (fluent-next.blue.light).png deleted file mode 100644 index f7fe459f0137..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist with a lot of messages (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist with a lot of messages (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist with a lot of messages (fluent.blue.light).png deleted file mode 100644 index d36159f68030..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist with a lot of messages (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist with date headers (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist with date headers (fluent-next.blue.light).png deleted file mode 100644 index fb5151de92ed..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist with date headers (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist with date headers (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist with date headers (fluent.blue.light).png deleted file mode 100644 index 3de02a0029b5..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist with date headers (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist with editing context menu (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist with editing context menu (fluent-next.blue.light).png deleted file mode 100644 index 3d629abd31fe..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist with editing context menu (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist with editing context menu (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist with editing context menu (fluent.blue.light).png deleted file mode 100644 index 245c5d6f4e53..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist with editing context menu (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist with message template (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist with message template (fluent-next.blue.light).png deleted file mode 100644 index b116a74b1cf3..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist with message template (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist with message template (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist with message template (fluent.blue.light).png deleted file mode 100644 index 29993db380a7..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist with message template (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist with message template after new message add (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist with message template after new message add (fluent-next.blue.light).png deleted file mode 100644 index d5ec71ea68b4..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist with message template after new message add (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist with message template after new message add (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist with message template after new message add (fluent.blue.light).png deleted file mode 100644 index 9c63e6aea7cd..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist with message template after new message add (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist with message template and deleted messages (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist with message template and deleted messages (fluent-next.blue.light).png deleted file mode 100644 index 02a27e9a22b6..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist with message template and deleted messages (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist with message template and deleted messages (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist with message template and deleted messages (fluent.blue.light).png deleted file mode 100644 index 4c442cc99b3b..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist with message template and deleted messages (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist with showDayHeaders, showUserName and showMessageTimestamp options set to false (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist with showDayHeaders, showUserName and showMessageTimestamp options set to false (fluent-next.blue.light).png deleted file mode 100644 index 7587a4d05abd..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist with showDayHeaders, showUserName and showMessageTimestamp options set to false (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist with showDayHeaders, showUserName and showMessageTimestamp options set to false (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist with showDayHeaders, showUserName and showMessageTimestamp options set to false (fluent.blue.light).png deleted file mode 100644 index 9108bc3318e9..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist with showDayHeaders, showUserName and showMessageTimestamp options set to false (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist without message template and with deleted messages (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist without message template and with deleted messages (fluent-next.blue.light).png deleted file mode 100644 index 5d4e3d0ad788..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist without message template and with deleted messages (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist without message template and with deleted messages (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist without message template and with deleted messages (fluent.blue.light).png deleted file mode 100644 index 1c79e4a5358d..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Messagelist without message template and with deleted messages (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Typing indicator with 1 user (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Typing indicator with 1 user (fluent-next.blue.light).png deleted file mode 100644 index a267bf17308b..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Typing indicator with 1 user (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Typing indicator with 1 user (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Typing indicator with 1 user (fluent.blue.light).png deleted file mode 100644 index 934d87ec25f1..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Typing indicator with 1 user (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Typing indicator with 2 users (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Typing indicator with 2 users (fluent-next.blue.light).png deleted file mode 100644 index 0172478cb2f4..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Typing indicator with 2 users (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Typing indicator with 2 users (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Typing indicator with 2 users (fluent.blue.light).png deleted file mode 100644 index ddb99563b295..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Typing indicator with 2 users (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Typing indicator with 3 users (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Typing indicator with 3 users (fluent-next.blue.light).png deleted file mode 100644 index 8505511de369..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Typing indicator with 3 users (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Typing indicator with 3 users (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Typing indicator with 3 users (fluent.blue.light).png deleted file mode 100644 index ea7036a2d8e2..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Typing indicator with 3 users (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Typing indicator with 4 users (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Typing indicator with 4 users (fluent-next.blue.light).png deleted file mode 100644 index 2216f378166b..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Typing indicator with 4 users (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Typing indicator with 4 users (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Typing indicator with 4 users (fluent.blue.light).png deleted file mode 100644 index 4ea2873904ab..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Typing indicator with 4 users (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Typing indicator with a lot of items (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Typing indicator with a lot of items (fluent-next.blue.light).png deleted file mode 100644 index a321e4d7be60..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Typing indicator with a lot of items (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Typing indicator with a lot of items (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Typing indicator with a lot of items (fluent.blue.light).png deleted file mode 100644 index 33f4d95b9069..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Typing indicator with a lot of items (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Typing indicator with emptyview (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Typing indicator with emptyview (fluent-next.blue.light).png deleted file mode 100644 index a45217dcd405..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Typing indicator with emptyview (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Typing indicator with emptyview (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Typing indicator with emptyview (fluent.blue.light).png deleted file mode 100644 index 700726ea3e45..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Typing indicator with emptyview (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Typing indicator with long name (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Typing indicator with long name (fluent-next.blue.light).png deleted file mode 100644 index a0d87f2b21e6..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Typing indicator with long name (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Typing indicator with long name (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Typing indicator with long name (fluent.blue.light).png deleted file mode 100644 index ca1e671194bb..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Typing indicator with long name (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Typing indicator without name (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Typing indicator without name (fluent-next.blue.light).png deleted file mode 100644 index 6d0dfac557ab..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Typing indicator without name (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Typing indicator without name (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/chat/etalons/Typing indicator without name (fluent.blue.light).png deleted file mode 100644 index 13f6dd2b03e9..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/chat/etalons/Typing indicator without name (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/chat/messageBox.ts b/e2e/testcafe-devextreme/tests/editors/chat/messageBox.ts deleted file mode 100644 index cde1975d8e0e..000000000000 --- a/e2e/testcafe-devextreme/tests/editors/chat/messageBox.ts +++ /dev/null @@ -1,115 +0,0 @@ -import { createScreenshotsComparer } from 'devextreme-screenshot-comparer'; -import Chat from 'devextreme-testcafe-models/chat'; -import { - getShortText, getLongText, createUser, attachments, -} from './data'; -import url from '../../../helpers/getPageUrl'; -import { createWidget } from '../../../helpers/createWidget'; -import { testScreenshot } from '../../../helpers/themeUtils'; -import { appendElementTo } from '../../../helpers/domUtils'; - -fixture.disablePageReloads`ChatMessageBox` - .page(url(__dirname, '../../container.html')); - -test('Chat: messagebox', async (t) => { - const { takeScreenshot, compareResults } = createScreenshotsComparer(t); - - const chat = new Chat('#chat'); - - const shortText = getShortText(); - const longText = getLongText(false, 5); - - await chat.focus(); - await testScreenshot(t, takeScreenshot, 'Messagebox when chat has focus.png', { element: '#chat' }); - - await t.typeText(chat.getInput(), shortText); - await testScreenshot(t, takeScreenshot, 'Messagebox when input contains short text.png', { element: '#chat' }); - - await t.typeText(chat.getInput(), longText); - await testScreenshot(t, takeScreenshot, 'Messagebox when input contains long text.png', { element: '#chat' }); - - await t.pressKey('tab'); - await testScreenshot(t, takeScreenshot, 'Messagebox when send button has focus.png', { element: '#chat' }); - - await t - .expect(compareResults.isValid()) - .ok(compareResults.errorMessages()); -}).before(async () => { - await appendElementTo('#container', 'div', 'chat'); - - return createWidget('dxChat', { - width: 400, - height: 600, - }, '#chat'); -}); - -test('Chat: messagebox with editing preview', async (t) => { - const { takeScreenshot, compareResults } = createScreenshotsComparer(t); - - const chat = new Chat('#chat'); - - await t.rightClick(chat.getMessage(0)); - await t.click(chat.getContextMenuItem(0)); - - await testScreenshot(t, takeScreenshot, 'Messagebox with editing preview.png', { - element: '#chat', - }); - - await t - .expect(compareResults.isValid()) - .ok(compareResults.errorMessages()); -}).before(async () => { - await appendElementTo('#container', 'div', 'chat'); - - const userFirst = createUser(1, 'First'); - const userSecond = createUser(2, 'Second'); - - const items = [{ - author: userFirst, - text: 'Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.', - }, { - author: userSecond, - text: 'Short message', - }]; - - return createWidget('dxChat', { - items, - user: userFirst, - editing: { - allowUpdating: true, - }, - width: 400, - height: 600, - }, '#chat'); -}); - -test('Chat: messagebox with attachments and informer', async (t) => { - const { takeScreenshot, compareResults } = createScreenshotsComparer(t); - - const chat = new Chat('#chat'); - - await t.typeText(chat.getInput(), getLongText(false, 4)); - await chat.option({ - fileUploaderOptions: { - value: [ - ...attachments, - ...attachments, - ...attachments, - ], - }, - }); - - await chat.focus(); - await testScreenshot(t, takeScreenshot, 'Messagebox with attachments and informer.png', { element: '#chat' }); - - await t - .expect(compareResults.isValid()) - .ok(compareResults.errorMessages()); -}).before(async () => { - await appendElementTo('#container', 'div', 'chat'); - - return createWidget('dxChat', { - width: 812, - height: 600, - }, '#chat'); -}); diff --git a/e2e/testcafe-devextreme/tests/editors/chat/messageBubble.ts b/e2e/testcafe-devextreme/tests/editors/chat/messageBubble.ts deleted file mode 100644 index 0572cd01fdae..000000000000 --- a/e2e/testcafe-devextreme/tests/editors/chat/messageBubble.ts +++ /dev/null @@ -1,89 +0,0 @@ -import { createScreenshotsComparer } from 'devextreme-screenshot-comparer'; -import Chat from 'devextreme-testcafe-models/chat'; -import { - createUser, - generateImageMessage, - generateMessages, - generateFileMessage, - generateFileMessageWithoutText, -} from './data'; -import url from '../../../helpers/getPageUrl'; -import { createWidget } from '../../../helpers/createWidget'; -import { testScreenshot } from '../../../helpers/themeUtils'; -import { appendElementTo } from '../../../helpers/domUtils'; - -fixture.disablePageReloads`ChatMessageBubble` - .page(url(__dirname, '../../container.html')); - -test('Chat: messagebubble', async (t) => { - const { takeScreenshot, compareResults } = createScreenshotsComparer(t); - - const chat = new Chat('#chat'); - - const userFirst = createUser(1, 'First'); - const userSecond = createUser(2, 'Second'); - - let items = generateMessages(2, userFirst, userSecond, true, false, 2); - - await chat.option({ items, user: userSecond }); - await testScreenshot(t, takeScreenshot, 'Bubbles with long text.png', { element: '#chat' }); - - items = generateMessages(2, userFirst, userSecond, true, true, 2); - - await chat.option({ items }); - await testScreenshot(t, takeScreenshot, 'Bubbles with long text with line breaks.png', { element: '#chat' }); - - await t - .expect(compareResults.isValid()) - .ok(compareResults.errorMessages()); -}).before(async () => { - await appendElementTo('#container', 'div', 'chat'); - - return createWidget('dxChat', { - width: 400, - height: 650, - }, '#chat'); -}); - -test('Chat: messagebubble with images and files', async (t) => { - const { takeScreenshot, compareResults } = createScreenshotsComparer(t); - const chat = new Chat('#chat'); - - const user = createUser(1, 'ImageUser'); - - const imageMessages = [ - generateImageMessage(user, '../../../apps/demos/images/products/1.png'), - generateImageMessage(user, '../../../apps/demos/images/products/1-small.png'), - ]; - - await chat.option({ items: imageMessages }); - await testScreenshot(t, takeScreenshot, 'Bubbles with images.png', { element: '#chat' }); - - const fileMessages = [ - generateFileMessage(user), - generateFileMessage(user, true), - ]; - - await chat.option({ - width: 700, - height: 720, - items: fileMessages, - }); - await testScreenshot(t, takeScreenshot, 'Bubbles with files.png', { element: '#chat' }); - - await chat.option({ - width: 600, - height: 600, - items: [generateFileMessageWithoutText(user)], - }); - await testScreenshot(t, takeScreenshot, 'Bubble with files without text.png', { element: '#chat' }); - - await t.expect(compareResults.isValid()).ok(compareResults.errorMessages()); -}).before(async () => { - await appendElementTo('#container', 'div', 'chat'); - - return createWidget('dxChat', { - width: 600, - height: 650, - }, '#chat'); -}); diff --git a/e2e/testcafe-devextreme/tests/editors/chat/messageGroup.ts b/e2e/testcafe-devextreme/tests/editors/chat/messageGroup.ts deleted file mode 100644 index 8085cfa173d4..000000000000 --- a/e2e/testcafe-devextreme/tests/editors/chat/messageGroup.ts +++ /dev/null @@ -1,198 +0,0 @@ -import { Selector } from 'testcafe'; -import { createScreenshotsComparer } from 'devextreme-screenshot-comparer'; -import Chat from 'devextreme-testcafe-models/chat'; -import { - createUser, - generateMessages, - getLongText, -} from './data'; -import url from '../../../helpers/getPageUrl'; -import { createWidget } from '../../../helpers/createWidget'; -import { testScreenshot } from '../../../helpers/themeUtils'; -import { appendElementTo, setStyleAttribute } from '../../../helpers/domUtils'; -import asyncForEach from '../../../helpers/asyncForEach'; - -const AVATAR_SELECTOR = '.dx-avatar'; -const CHAT_WRAPPER_STYLES = 'display: flex; flex-wrap: wrap; gap: 2px; width: 1270px; padding: 20px; transform: scale(0.9);'; - -fixture.disablePageReloads`ChatMessageGroup` - .page(url(__dirname, '../../container.html')); - -test('Chat: messagegroup, avatar rendering', async (t) => { - const { takeScreenshot, compareResults } = createScreenshotsComparer(t); - - await testScreenshot(t, takeScreenshot, 'Avatar has correct position.png', { element: '#chat' }); - - await setStyleAttribute(Selector(AVATAR_SELECTOR), 'width: 64px; height: 64px'); - await testScreenshot(t, takeScreenshot, 'Avatar sizes do not affect indentation between bubbles.png', { element: '#chat' }); - - await t - .expect(compareResults.isValid()) - .ok(compareResults.errorMessages()); -}).before(async () => { - await appendElementTo('#container', 'div', 'chat'); - - const userFirst = createUser(1, 'First'); - const items = generateMessages(3, userFirst); - - return createWidget('dxChat', { - width: 400, - height: 600, - items, - }, '#chat'); -}); - -test('Chat: messagegroup, information', async (t) => { - const { takeScreenshot, compareResults } = createScreenshotsComparer(t); - - await testScreenshot(t, takeScreenshot, 'Information row with long user name.png', { element: '#chat' }); - - await t - .expect(compareResults.isValid()) - .ok(compareResults.errorMessages()); -}).before(async () => { - await appendElementTo('#container', 'div', 'chat'); - - const userFirst = createUser(1, getLongText()); - const userSecond = createUser(2, getLongText()); - - const items = generateMessages(2, userFirst, userSecond, false, false, 2); - - return createWidget('dxChat', { - width: 400, - height: 600, - user: userSecond, - items, - }, '#chat'); -}); - -test('Chat: messagegroup, bubbles', async (t) => { - const { takeScreenshot, compareResults } = createScreenshotsComparer(t); - - const chat = new Chat('#chat'); - - const userFirst = createUser(1, 'First'); - const userSecond = createUser(2, 'Second'); - - let items = generateMessages(1, userFirst, userSecond, false, false, 4, 2); - - await chat.option({ items, user: userSecond }); - await testScreenshot(t, takeScreenshot, 'Messagegroup with 1 bubble.png', { element: '#chat' }); - - items = generateMessages(2, userFirst, userSecond, false, false, 4, 2); - - await chat.option({ items }); - await testScreenshot(t, takeScreenshot, 'Messagegroup with 2 bubbles.png', { element: '#chat' }); - - items = generateMessages(3, userFirst, userSecond, false, false, 4, 2); - - await chat.option({ items }); - await testScreenshot(t, takeScreenshot, 'Messagegroup with 3 bubbles.png', { element: '#chat' }); - - items = generateMessages(4, userFirst, userSecond, false, false, 4, 2); - - await chat.option({ items }); - await testScreenshot(t, takeScreenshot, 'Messagegroup with 4 bubbles.png', { element: '#chat' }); - - await t - .expect(compareResults.isValid()) - .ok(compareResults.errorMessages()); -}).before(async () => { - await appendElementTo('#container', 'div', 'chat'); - - return createWidget('dxChat', { - width: 400, - height: 600, - }, '#chat'); -}); - -test('Messagegroup scenarios in disabled state', async (t) => { - const { takeScreenshot, compareResults } = createScreenshotsComparer(t); - - const userFirst = createUser(1, 'First'); - const userSecond = createUser(2, 'Second'); - - await asyncForEach([1, 2, 3, 4], async (bubbleCount, idx) => { - const chatId = `#chat_${idx}`; - await appendElementTo('#chat-wrapper', 'div', `chat_${idx}`); - - const items = generateMessages(bubbleCount, userFirst, userSecond, false, false, 4, 2); - - await createWidget('dxChat', { - items, - disabled: true, - user: userSecond, - width: 250, - height: 400, - }, chatId); - - const chat = new Chat(chatId); - await chat.repaint(); - }); - - await testScreenshot(t, takeScreenshot, 'Messagegroup appearance in disabled state.png', { element: '#chat-wrapper' }); - - await t - .expect(compareResults.isValid()) - .ok(compareResults.errorMessages()); -}).before(async () => { - await appendElementTo('#container', 'div', 'chat-wrapper'); - await setStyleAttribute(Selector('#chat-wrapper'), CHAT_WRAPPER_STYLES); -}); - -test('Messagegroup scenarios in RTL mode', async (t) => { - const { takeScreenshot, compareResults } = createScreenshotsComparer(t); - - const userFirst = createUser(1, 'First'); - const userSecond = createUser(2, 'Second'); - - await asyncForEach([1, 2, 3, 4], async (bubbleCount, idx) => { - const chatId = `#chat_${idx}`; - await appendElementTo('#chat-wrapper', 'div', `chat_${idx}`); - - const items = generateMessages(bubbleCount, userFirst, userSecond, false, false, 4, 2); - - await createWidget('dxChat', { - items, - rtlEnabled: true, - user: userSecond, - width: 250, - height: 400, - }, chatId); - - const chat = new Chat(chatId); - await chat.repaint(); // NOTE: WA to make it stable in Material theme. - }); - - await testScreenshot(t, takeScreenshot, 'Messagegroup appearance in RTL mode.png', { element: '#chat-wrapper' }); - - await t - .expect(compareResults.isValid()) - .ok(compareResults.errorMessages()); -}).before(async () => { - await appendElementTo('#container', 'div', 'chat-wrapper'); - await setStyleAttribute(Selector('#chat-wrapper'), CHAT_WRAPPER_STYLES); -}); - -test('MessageGroup with edited messages', async (t) => { - const { takeScreenshot, compareResults } = createScreenshotsComparer(t); - - await testScreenshot(t, takeScreenshot, 'MessageGroup with edited messages.png', { element: '#chat' }); - - await t - .expect(compareResults.isValid()) - .ok(compareResults.errorMessages()); -}).before(async () => { - await appendElementTo('#container', 'div', 'chat'); - - const userFirst = createUser(1, 'First'); - const userSecond = createUser(2, 'Second'); - const items = generateMessages(2, userFirst, userSecond, false, false, 2, 2, true); - - return createWidget('dxChat', { - width: 400, - height: 600, - user: userSecond, - items, - }, '#chat'); -}); diff --git a/e2e/testcafe-devextreme/tests/editors/chat/messageList.ts b/e2e/testcafe-devextreme/tests/editors/chat/messageList.ts deleted file mode 100644 index 7c255d0c2e43..000000000000 --- a/e2e/testcafe-devextreme/tests/editors/chat/messageList.ts +++ /dev/null @@ -1,404 +0,0 @@ -import { createScreenshotsComparer } from 'devextreme-screenshot-comparer'; -import Chat from 'devextreme-testcafe-models/chat'; -import { ClientFunction } from 'testcafe'; -import { User } from 'devextreme/ui/chat'; -import TabPanel from 'devextreme-testcafe-models/tabPanel'; -import { createUser, generateMessages, getLongText } from './data'; -import url from '../../../helpers/getPageUrl'; -import { createWidget } from '../../../helpers/createWidget'; -import { testScreenshot } from '../../../helpers/themeUtils'; - -fixture.disablePageReloads`ChatMessageList` - .page(url(__dirname, '../../container.html')); - -test('Messagelist empty view scenarios', async (t) => { - const { takeScreenshot, compareResults } = createScreenshotsComparer(t); - - const chat = new Chat('#container'); - - await testScreenshot(t, takeScreenshot, 'Messagelist empty state.png', { element: '#container' }); - - await chat.option('rtlEnabled', true); - - await testScreenshot(t, takeScreenshot, 'Messagelist empty in RTL mode.png', { element: '#container' }); - - await chat.option({ - disabled: true, - rtlEnabled: false, - }); - - await testScreenshot(t, takeScreenshot, 'Messagelist empty in disabled state.png', { element: '#container' }); - - await chat.option({ - width: 200, - height: 400, - disabled: false, - }); - - await testScreenshot(t, takeScreenshot, 'Messagelist empty with limited dimensions.png', { element: '#container' }); - - await t - .expect(compareResults.isValid()) - .ok(compareResults.errorMessages()); -}).before(async () => createWidget('dxChat', { - width: 400, - height: 600, -})); - -test('Messagelist appearance with scrollbar', async (t) => { - const { takeScreenshot, compareResults } = createScreenshotsComparer(t); - - const chat = new Chat('#container'); - - await t - .hover(chat.messageList); - - await testScreenshot(t, takeScreenshot, 'Messagelist with a lot of messages.png', { element: '#container' }); - - await ClientFunction( - () => { - const instance = chat.getInstance(); - instance.renderMessage({ - author: instance.option('user') as User, - text: 'Lorem ipsum dolor sit amet, \nconsectetur adipiscing elit. Sed do eiusmod tempor \nincididunt ut labore et dolore magna aliqua. Ut enim ad minim \nveniam, quis nostrud exercitation ullamco laboris nisi ut aliquip \nnex ea commodo consequat.', - }); - }, - { dependencies: { chat } }, - )(); - - await testScreenshot(t, takeScreenshot, 'Messagelist scrollbar position after call renderMessage().png', { element: '#container' }); - - await t - .typeText(chat.getInput(), getLongText()) - .pressKey('shift+enter'); - - await testScreenshot(t, takeScreenshot, 'Messagelist scrollbar position after typing in textarea.png', { element: '#container' }); - - await t - .pressKey('enter'); - - await testScreenshot(t, takeScreenshot, 'Messagelist scrollbar position after send.png', { element: '#container' }); - - const scrollable = chat.getScrollable(); - const topOffset = (await scrollable.scrollOffset()).top; - - await scrollable.scrollTo({ top: topOffset - 100 }); - - await t - .typeText(chat.getInput(), getLongText()); - - await testScreenshot(t, takeScreenshot, 'Messagelist scrollbar middle position after typing in textarea.png', { element: '#container' }); - - await t - .expect(compareResults.isValid()) - .ok(compareResults.errorMessages()); -}).before(async () => { - const userFirst = createUser(1, 'First'); - const userSecond = createUser(2, 'Second'); - - const items = generateMessages(17, userFirst, userSecond, true, false, 2); - - return createWidget('dxChat', { - items, - user: userSecond, - width: 400, - height: 600, - showDayHeaders: false, - onMessageEntered: (e) => { - const { component, message } = e; - - component.renderMessage(message); - }, - }); -}); - -test('Messagelist should scrolled to the latest messages after being rendered inside an invisible element', async (t) => { - const { takeScreenshot, compareResults } = createScreenshotsComparer(t); - const tabPanel = new TabPanel('#container'); - - await t - .click(tabPanel.tabs.getItem(1).element); - - await testScreenshot(t, takeScreenshot, 'Messagelist scroll position after rendering in invisible container.png', { element: '#container' }); - - await t - .expect(compareResults.isValid()) - .ok(compareResults.errorMessages()); -}).before(async () => { - const userFirst = createUser(1, 'First'); - const userSecond = createUser(2, 'Second'); - - const items = generateMessages(17, userFirst, userSecond, true, false, 2); - - return createWidget('dxTabPanel', { - width: 400, - height: 600, - deferRendering: true, - templatesRenderAsynchronously: true, - dataSource: [{ - title: 'Tab_1', - collapsible: true, - text: 'Tab_1 content', - }, { - title: 'Tab_2', - collapsible: true, - template: ClientFunction(() => ($('
') as any).dxChat({ - items, - user: userSecond, - }), { dependencies: { items, userSecond } }), - }], - }); -}); - -test('Messagelist with deleted items', async (t) => { - const { takeScreenshot, compareResults } = createScreenshotsComparer(t); - - await testScreenshot(t, takeScreenshot, 'Messagelist without message template and with deleted messages.png', { element: '#container' }); - - await t - .expect(compareResults.isValid()) - .ok(compareResults.errorMessages()); -}).before(async () => { - const userFirst = createUser(1, 'First'); - const userSecond = createUser(2, 'Second'); - const items = [{ - author: userFirst, - text: 'AAA', - }, { - author: userFirst, - text: 'BBB', - isDeleted: true, - }, { - author: userSecond, - text: 'CCC', - isDeleted: true, - }]; - - return createWidget('dxChat', { - items, - user: userFirst, - width: 400, - height: 600, - showDayHeaders: false, - }); -}); - -test('Messagelist with deleted items and custom template', async (t) => { - const { takeScreenshot, compareResults } = createScreenshotsComparer(t); - - await testScreenshot(t, takeScreenshot, 'Messagelist with message template and deleted messages.png', { element: '#container' }); - - await t - .expect(compareResults.isValid()) - .ok(compareResults.errorMessages()); -}).before(async () => { - const userFirst = createUser(1, 'First'); - const userSecond = createUser(2, 'Second'); - const items = [{ - author: userFirst, - text: 'AAA', - }, { - author: userFirst, - text: 'BBB', - isDeleted: true, - }, { - author: userSecond, - text: 'CCC', - isDeleted: true, - }]; - - return createWidget('dxChat', { - items, - user: userFirst, - width: 400, - height: 600, - showDayHeaders: false, - messageTemplate: ({ message }, container) => { - if (message.isDeleted) { - $('
').text(`${message.author.name} deleted this message`).appendTo(container); - return; - } - $('
').text(message.text).appendTo(container); - }, - }); -}); - -test('Messagelist with messageTemplate', async (t) => { - const { takeScreenshot, compareResults } = createScreenshotsComparer(t); - const chat = new Chat('#container'); - - await testScreenshot(t, takeScreenshot, 'Messagelist with message template.png', { element: '#container' }); - - await t - .typeText(chat.getInput(), 'New last message') - .pressKey('enter'); - - await testScreenshot(t, takeScreenshot, 'Messagelist with message template after new message add.png', { element: '#container' }); - - await t - .expect(compareResults.isValid()) - .ok(compareResults.errorMessages()); -}).before(async () => { - const userFirst = createUser(1, 'First'); - const userSecond = createUser(2, 'Second'); - const items = [{ - author: userFirst, - text: 'AAA', - }, { - author: userFirst, - text: 'BBB', - }, { - author: userSecond, - text: 'CCC', - }]; - - return createWidget('dxChat', { - items, - user: userFirst, - width: 400, - height: 600, - showDayHeaders: false, - onMessageEntered: ({ component, message }) => { - message.timestamp = undefined; - component.renderMessage(message); - }, - messageTemplate: ({ message }, container) => { - $('
').text(`${message.author.name} says: ${message.text}`).appendTo(container); - }, - }); -}); - -test('Messagelist options showDayHeaders, showUserName and showMessageTimestamp set to false work', async (t) => { - const { takeScreenshot, compareResults } = createScreenshotsComparer(t); - - await testScreenshot( - t, - takeScreenshot, - 'Messagelist with showDayHeaders, showUserName and showMessageTimestamp options set to false.png', - { element: '#container' }, - ); - - await t - .expect(compareResults.isValid()) - .ok(compareResults.errorMessages()); -}).before(async () => { - const userFirst = createUser(1, 'First'); - const userSecond = createUser(2, 'Second'); - const items = [{ - author: userFirst, - text: 'AAA', - }, { - author: userFirst, - text: 'BBB', - }, { - author: userSecond, - text: 'CCC', - }]; - - return createWidget('dxChat', { - items, - user: userFirst, - width: 400, - height: 600, - showDayHeaders: false, - showUserName: false, - showMessageTimestamp: false, - }); -}); - -test('Message list with editing context menu', async (t) => { - const { takeScreenshot, compareResults } = createScreenshotsComparer(t); - const chat = new Chat('#container'); - - await t - .rightClick(chat.getMessage(2)) - .pressKey('down') - .pressKey('down'); - - await testScreenshot(t, takeScreenshot, 'Messagelist with editing context menu.png', { element: '#container' }); - - await t - .expect(compareResults.isValid()) - .ok(compareResults.errorMessages()); -}).before(async () => { - const userFirst = createUser(1, 'First'); - const userSecond = createUser(2, 'Second'); - - const items = [ - { author: userFirst, text: 'AAA' }, - { author: userFirst, text: 'BBB' }, - { author: userSecond, text: 'CCC' }, - ]; - - return createWidget('dxChat', { - items, - editing: { - allowUpdating: true, - allowDeleting: true, - }, - user: userSecond, - width: 400, - height: 600, - showDayHeaders: false, - }); -}); - -fixture`ChatMessageList: dayHeaders` - .page(url(__dirname, '../../container.html')); - -test.clientScripts([ - { module: 'mockdate' }, - { content: 'window.MockDate = MockDate;' }, -])('Messagelist with date headers', async (t) => { - const { takeScreenshot, compareResults } = createScreenshotsComparer(t); - - await testScreenshot(t, takeScreenshot, 'Messagelist with date headers.png', { element: '#container' }); - - await t - .expect(compareResults.isValid()) - .ok(compareResults.errorMessages()); -}).before(async () => { - await ClientFunction(() => { - (window as any).MockDate.set('2024/10/27'); - })(); - - const userFirst = createUser(1, 'First'); - const userSecond = createUser(2, 'Second'); - const msInDay = 86400000; - const today = new Date('2024/10/27').setHours(7, 22, 0, 0); - const yesterday = today - msInDay; - - const items = [{ - timestamp: new Date('05.01.2024'), - author: userFirst, - text: 'AAA', - }, { - timestamp: new Date('06.01.2024'), - author: userFirst, - text: 'BBB', - }, { - timestamp: new Date('06.01.2024'), - author: userSecond, - text: 'CCC', - }, { - timestamp: yesterday, - author: userSecond, - text: 'DDD', - }, { - timestamp: today, - author: userFirst, - text: 'EEE', - }]; - - return createWidget('dxChat', { - items, - user: userSecond, - width: 400, - height: 600, - }); -}).after(async () => { - await ClientFunction(() => { - (window as any).MockDate.reset(); - delete (window as any).MockDate; - })(); -}); diff --git a/e2e/testcafe-devextreme/tests/editors/chat/suggestions.ts b/e2e/testcafe-devextreme/tests/editors/chat/suggestions.ts deleted file mode 100644 index 1261cb610b7c..000000000000 --- a/e2e/testcafe-devextreme/tests/editors/chat/suggestions.ts +++ /dev/null @@ -1,48 +0,0 @@ -import { createScreenshotsComparer } from 'devextreme-screenshot-comparer'; -import { ClientFunction } from 'testcafe'; -import url from '../../../helpers/getPageUrl'; -import { createWidget } from '../../../helpers/createWidget'; -import { getThemeName, testScreenshot } from '../../../helpers/themeUtils'; - -const CHAT_SUGGESTIONS_CLASS = 'dx-chat-suggestions'; - -const render = ClientFunction((markup: string) => { - const container = document.querySelector('#container'); - - if (container) container.innerHTML = markup; -}); - -const createSuggestions = (selector: string) => createWidget('dxButtonGroup', { - items: [ - { text: 'Summary' }, - { text: 'Ideal Buyer' }, - { text: 'Competitors' }, - ], - stylingMode: 'outlined', - selectionMode: 'none', - elementAttr: { class: CHAT_SUGGESTIONS_CLASS }, - width: 400, -}, selector); - -if (getThemeName() === 'fluent-next') { - fixture.disablePageReloads`ChatSuggestions`.page( - url(__dirname, '../../container.html'), - ); - - test('Chat suggestions outside of a chat in light and dark modes', async (t) => { - const { takeScreenshot, compareResults } = createScreenshotsComparer(t); - - await testScreenshot(t, takeScreenshot, 'Chat suggestions outside of a chat.png', { - element: '#container', - }); - - await t.expect(compareResults.isValid()).ok(compareResults.errorMessages()); - }).before(async () => { - await render(` -
-
- `); - await createSuggestions('#light'); - await createSuggestions('#dark'); - }); -} diff --git a/e2e/testcafe-devextreme/tests/editors/chat/typingIndicator.ts b/e2e/testcafe-devextreme/tests/editors/chat/typingIndicator.ts deleted file mode 100644 index 8fe2343ecded..000000000000 --- a/e2e/testcafe-devextreme/tests/editors/chat/typingIndicator.ts +++ /dev/null @@ -1,123 +0,0 @@ -import { createScreenshotsComparer } from 'devextreme-screenshot-comparer'; -import Chat from 'devextreme-testcafe-models/chat'; -import { ClientFunction } from 'testcafe'; -import { createUser, generateMessages } from './data'; -import url from '../../../helpers/getPageUrl'; -import { createWidget } from '../../../helpers/createWidget'; -import { testScreenshot } from '../../../helpers/themeUtils'; -import { appendElementTo, insertStylesheetRulesToPage } from '../../../helpers/domUtils'; - -const CHAT_TYPINGINDICATOR_CIRCLE_CLASS = 'dx-chat-typingindicator-circle'; -const waitFont = ClientFunction(() => (window as any).DevExpress.ui.themes.waitWebFont('Item123somevalu*op ', 400)); - -fixture.disablePageReloads`ChatTypingIndicator` - .page(url(__dirname, '../../container.html')); - -test('Chat: typing indicator with emptyview', async (t) => { - const { takeScreenshot, compareResults } = createScreenshotsComparer(t); - - await testScreenshot(t, takeScreenshot, 'Typing indicator with emptyview.png', { - element: '#container', - }); - - await t - .expect(compareResults.isValid()) - .ok(compareResults.errorMessages()); -}).before(async () => { - await insertStylesheetRulesToPage(`.${CHAT_TYPINGINDICATOR_CIRCLE_CLASS} { animation: none !important; }`); - - const typingUsers = [ - { name: 'Elodie Montclair' }, - ]; - - await waitFont(); - - return createWidget('dxChat', { - width: 400, - height: 600, - typingUsers, - }); -}); - -test('Chat: typing indicator with a lot of items', async (t) => { - const { takeScreenshot, compareResults } = createScreenshotsComparer(t); - const chat = new Chat('#chat'); - - await chat.repaint(); - - await testScreenshot(t, takeScreenshot, 'Typing indicator with a lot of items.png', { element: '#chat' }); - - await t - .expect(compareResults.isValid()) - .ok(compareResults.errorMessages()); -}).before(async () => { - await appendElementTo('#container', 'div', 'chat'); - await insertStylesheetRulesToPage(`.${CHAT_TYPINGINDICATOR_CIRCLE_CLASS} { animation: none !important; }`); - - const userFirst = createUser(1, 'Marie-Claire Dubois'); - const userSecond = createUser(2, 'Jean-Pierre Martin'); - - const items = generateMessages(27, userFirst, userSecond); - - const typingUsers = [userFirst]; - - return createWidget('dxChat', { - user: userSecond, - width: 400, - height: 600, - items, - typingUsers, - }, '#chat'); -}); - -test('Chat: typing indicator', async (t) => { - const { takeScreenshot, compareResults } = createScreenshotsComparer(t); - - await testScreenshot(t, takeScreenshot, 'Typing indicator with 1 user.png', { element: '#chat' }); - - const chat = new Chat('#chat'); - - const userFirst = createUser(1, 'Camille'); - const userSecond = createUser(2, 'Sophie'); - const userThird = createUser(3, 'Antoine'); - const userFourth = createUser(4, 'Julien'); - - await chat.option('typingUsers', [userFirst, userSecond]); - await testScreenshot(t, takeScreenshot, 'Typing indicator with 2 users.png', { element: '#chat' }); - - await chat.option('typingUsers', [userFirst, userSecond, userThird]); - await testScreenshot(t, takeScreenshot, 'Typing indicator with 3 users.png', { element: '#chat' }); - - await chat.option('typingUsers', [userFirst, userSecond, userThird, userFourth]); - await testScreenshot(t, takeScreenshot, 'Typing indicator with 4 users.png', { element: '#chat' }); - - await chat.option('typingUsers', [{ name: 'Marie-Francoise Isabelle Antoinette de La Rochefoucauld' }]); - await testScreenshot(t, takeScreenshot, 'Typing indicator with long name.png', { element: '#chat' }); - - await chat.option('typingUsers', [{}]); - await testScreenshot(t, takeScreenshot, 'Typing indicator without name.png', { element: '#chat' }); - - await t - .expect(compareResults.isValid()) - .ok(compareResults.errorMessages()); -}).before(async () => { - await appendElementTo('#container', 'div', 'chat'); - await insertStylesheetRulesToPage(`.${CHAT_TYPINGINDICATOR_CIRCLE_CLASS} { animation: none !important; }`); - - const userFirst = createUser(1, 'Elise Moreau'); - const userSecond = createUser(2, 'Pierre Martin'); - - const items = generateMessages(5, userFirst, userSecond); - - const typingUsers = [userFirst]; - - await waitFont(); - - return createWidget('dxChat', { - user: userSecond, - width: 400, - height: 600, - items, - typingUsers, - }, '#chat'); -}); diff --git a/e2e/testcafe-devextreme/tests/editors/overlays/dialog.ts b/e2e/testcafe-devextreme/tests/editors/overlays/dialog.ts deleted file mode 100644 index 94496c09dc60..000000000000 --- a/e2e/testcafe-devextreme/tests/editors/overlays/dialog.ts +++ /dev/null @@ -1,50 +0,0 @@ -import { createScreenshotsComparer } from 'devextreme-screenshot-comparer'; -import { ClientFunction } from 'testcafe'; -import { testScreenshot } from '../../../helpers/themeUtils'; -import url from '../../../helpers/getPageUrl'; - -const DX_DIALOG_CLASS = 'dx-dialog'; - -fixture.disablePageReloads`Dialog` - .page(url(__dirname, '../../container.html')); - -[ - 'alert', - 'confirm', - 'custom', -].forEach((dialogType) => { - test(`Dialog appearance (${dialogType})`, async (t) => { - const { takeScreenshot, compareResults } = createScreenshotsComparer(t); - - await testScreenshot(t, takeScreenshot, `Dialog appearance (${dialogType}).png`); - - await ClientFunction(() => { - $(`.${DX_DIALOG_CLASS}`).remove(); - }, { - dependencies: { DX_DIALOG_CLASS }, - })(); - - await t - .expect(compareResults.isValid()) - .ok(compareResults.errorMessages()); - }).before(async () => { - const dialogArgs = dialogType === 'custom' - ? { title: 'custom', messageHtml: 'message', buttons: [{ text: 'Custom button' }] } - : dialogType; - - await ClientFunction(() => { - const dialogFunction = (window as any).DevExpress.ui.dialog[dialogType]; - - if (dialogType === 'custom') { - dialogFunction(dialogArgs).show(); - } else { - dialogFunction(dialogArgs); - } - }, { - dependencies: { - dialogType, - dialogArgs, - }, - })(); - }); -}); diff --git a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Dialog appearance (alert) (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Dialog appearance (alert) (fluent-next.blue.light).png deleted file mode 100644 index d4c5b5fd4014..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Dialog appearance (alert) (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Dialog appearance (alert) (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Dialog appearance (alert) (fluent.blue.light).png deleted file mode 100644 index b0437bf670b7..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Dialog appearance (alert) (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Dialog appearance (confirm) (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Dialog appearance (confirm) (fluent-next.blue.light).png deleted file mode 100644 index 46136fcbc769..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Dialog appearance (confirm) (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Dialog appearance (confirm) (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Dialog appearance (confirm) (fluent.blue.light).png deleted file mode 100644 index 7014824d485b..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Dialog appearance (confirm) (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Dialog appearance (custom) (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Dialog appearance (custom) (fluent-next.blue.light).png deleted file mode 100644 index 7504a3a21ea5..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Dialog appearance (custom) (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Dialog appearance (custom) (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Dialog appearance (custom) (fluent.blue.light).png deleted file mode 100644 index b8ba0b0221fd..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Dialog appearance (custom) (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popover_bottom_toolbar_menu,rtlEnabled=false (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popover_bottom_toolbar_menu,rtlEnabled=false (fluent-next.blue.light).png deleted file mode 100644 index a7634a07dad3..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popover_bottom_toolbar_menu,rtlEnabled=false (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popover_bottom_toolbar_menu,rtlEnabled=false (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popover_bottom_toolbar_menu,rtlEnabled=false (fluent.blue.light).png deleted file mode 100644 index dde414638ebf..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popover_bottom_toolbar_menu,rtlEnabled=false (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popover_bottom_toolbar_menu,rtlEnabled=true (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popover_bottom_toolbar_menu,rtlEnabled=true (fluent-next.blue.light).png deleted file mode 100644 index dcdb9d816fe0..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popover_bottom_toolbar_menu,rtlEnabled=true (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popover_bottom_toolbar_menu,rtlEnabled=true (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popover_bottom_toolbar_menu,rtlEnabled=true (fluent.blue.light).png deleted file mode 100644 index 701dc7ab7ad7..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popover_bottom_toolbar_menu,rtlEnabled=true (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popover_top_toolbar_menu,rtlEnabled=false (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popover_top_toolbar_menu,rtlEnabled=false (fluent-next.blue.light).png deleted file mode 100644 index fcd389e7a1be..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popover_top_toolbar_menu,rtlEnabled=false (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popover_top_toolbar_menu,rtlEnabled=false (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popover_top_toolbar_menu,rtlEnabled=false (fluent.blue.light).png deleted file mode 100644 index 7cb490c18583..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popover_top_toolbar_menu,rtlEnabled=false (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popover_top_toolbar_menu,rtlEnabled=true (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popover_top_toolbar_menu,rtlEnabled=true (fluent-next.blue.light).png deleted file mode 100644 index eaa839149fb7..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popover_top_toolbar_menu,rtlEnabled=true (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popover_top_toolbar_menu,rtlEnabled=true (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popover_top_toolbar_menu,rtlEnabled=true (fluent.blue.light).png deleted file mode 100644 index cabddd21fb1a..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popover_top_toolbar_menu,rtlEnabled=true (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popup toolbars with wide elements and overflow menu after items rebinding (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popup toolbars with wide elements and overflow menu after items rebinding (fluent-next.blue.light).png deleted file mode 100644 index 504c4b234e70..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popup toolbars with wide elements and overflow menu after items rebinding (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popup toolbars with wide elements and overflow menu after items rebinding (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popup toolbars with wide elements and overflow menu after items rebinding (fluent.blue.light).png deleted file mode 100644 index 42e811f5953b..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popup toolbars with wide elements and overflow menu after items rebinding (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popup toolbars with wide elements and overflow menu before items rebinding (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popup toolbars with wide elements and overflow menu before items rebinding (fluent-next.blue.light).png deleted file mode 100644 index dbe05a0ab25d..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popup toolbars with wide elements and overflow menu before items rebinding (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popup toolbars with wide elements and overflow menu before items rebinding (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popup toolbars with wide elements and overflow menu before items rebinding (fluent.blue.light).png deleted file mode 100644 index 658724e0f5e8..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popup toolbars with wide elements and overflow menu before items rebinding (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popup_bottom_toolbar_menu,rtlEnabled=false (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popup_bottom_toolbar_menu,rtlEnabled=false (fluent-next.blue.light).png deleted file mode 100644 index f39284a346c9..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popup_bottom_toolbar_menu,rtlEnabled=false (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popup_bottom_toolbar_menu,rtlEnabled=false (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popup_bottom_toolbar_menu,rtlEnabled=false (fluent.blue.light).png deleted file mode 100644 index 6ce761444424..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popup_bottom_toolbar_menu,rtlEnabled=false (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popup_bottom_toolbar_menu,rtlEnabled=true (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popup_bottom_toolbar_menu,rtlEnabled=true (fluent-next.blue.light).png deleted file mode 100644 index ab4b9dd09e72..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popup_bottom_toolbar_menu,rtlEnabled=true (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popup_bottom_toolbar_menu,rtlEnabled=true (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popup_bottom_toolbar_menu,rtlEnabled=true (fluent.blue.light).png deleted file mode 100644 index 2c5cb296cae6..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popup_bottom_toolbar_menu,rtlEnabled=true (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popup_top_toolbar_menu,rtlEnabled=false (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popup_top_toolbar_menu,rtlEnabled=false (fluent-next.blue.light).png deleted file mode 100644 index 4f9cd1984ffa..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popup_top_toolbar_menu,rtlEnabled=false (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popup_top_toolbar_menu,rtlEnabled=false (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popup_top_toolbar_menu,rtlEnabled=false (fluent.blue.light).png deleted file mode 100644 index ebdd501e855c..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popup_top_toolbar_menu,rtlEnabled=false (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popup_top_toolbar_menu,rtlEnabled=true (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popup_top_toolbar_menu,rtlEnabled=true (fluent-next.blue.light).png deleted file mode 100644 index 83bd8488b55f..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popup_top_toolbar_menu,rtlEnabled=true (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popup_top_toolbar_menu,rtlEnabled=true (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popup_top_toolbar_menu,rtlEnabled=true (fluent.blue.light).png deleted file mode 100644 index 46f4314a9d6e..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Popup_top_toolbar_menu,rtlEnabled=true (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Toasts (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Toasts (fluent-next.blue.light).png deleted file mode 100644 index babfc2151c88..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Toasts (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Toasts (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Toasts (fluent.blue.light).png deleted file mode 100644 index 11ddcb5785ea..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Toasts (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Toolbar after items rebinding if it was hidden without items on init (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Toolbar after items rebinding if it was hidden without items on init (fluent-next.blue.light).png deleted file mode 100644 index 504c4b234e70..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Toolbar after items rebinding if it was hidden without items on init (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Toolbar after items rebinding if it was hidden without items on init (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Toolbar after items rebinding if it was hidden without items on init (fluent.blue.light).png deleted file mode 100644 index 42e811f5953b..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Toolbar after items rebinding if it was hidden without items on init (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Toolbar after items rebinding if it was visible with items on init (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Toolbar after items rebinding if it was visible with items on init (fluent-next.blue.light).png deleted file mode 100644 index 504c4b234e70..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Toolbar after items rebinding if it was visible with items on init (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Toolbar after items rebinding if it was visible with items on init (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Toolbar after items rebinding if it was visible with items on init (fluent.blue.light).png deleted file mode 100644 index 42e811f5953b..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Toolbar after items rebinding if it was visible with items on init (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Toolbar before items rebinding if it was hidden without items on init (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Toolbar before items rebinding if it was hidden without items on init (fluent-next.blue.light).png deleted file mode 100644 index dbe05a0ab25d..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Toolbar before items rebinding if it was hidden without items on init (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Toolbar before items rebinding if it was hidden without items on init (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Toolbar before items rebinding if it was hidden without items on init (fluent.blue.light).png deleted file mode 100644 index 658724e0f5e8..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Toolbar before items rebinding if it was hidden without items on init (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Toolbar before items rebinding if it was visible with items on init (fluent-next.blue.light).png b/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Toolbar before items rebinding if it was visible with items on init (fluent-next.blue.light).png deleted file mode 100644 index dbe05a0ab25d..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Toolbar before items rebinding if it was visible with items on init (fluent-next.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Toolbar before items rebinding if it was visible with items on init (fluent.blue.light).png b/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Toolbar before items rebinding if it was visible with items on init (fluent.blue.light).png deleted file mode 100644 index 658724e0f5e8..000000000000 Binary files a/e2e/testcafe-devextreme/tests/editors/overlays/etalons/Toolbar before items rebinding if it was visible with items on init (fluent.blue.light).png and /dev/null differ diff --git a/e2e/testcafe-devextreme/tests/editors/overlays/popup.drag.ts b/e2e/testcafe-devextreme/tests/editors/overlays/popup.drag.ts deleted file mode 100644 index a9e9cb782610..000000000000 --- a/e2e/testcafe-devextreme/tests/editors/overlays/popup.drag.ts +++ /dev/null @@ -1,189 +0,0 @@ -import { ClientFunction, Selector } from 'testcafe'; -import Popup from 'devextreme-testcafe-models/popup'; -import url from '../../../helpers/getPageUrl'; -import asyncForEach from '../../../helpers/asyncForEach'; -import { createWidget } from '../../../helpers/createWidget'; -import { appendElementTo } from '../../../helpers/domUtils'; - -fixture.disablePageReloads`Popup` - .page(url(__dirname, '../../container.html')); - -test.meta({ browserSize: [700, 700] })('Popup can not be dragged outside of the container (window)', async (t) => { - const popup = new Popup('#container'); - - const content = popup.getContent(); - const toolbar = popup.getToolbar(); - - const popupRect: { bottom: number; top: number; left: number; right: number } = { - bottom: 0, top: 0, left: 0, right: 0, - }; - - await t - .drag(toolbar, -10000, -10000); - - await asyncForEach(['bottom', 'left', 'top', 'right'], async (prop) => { - popupRect[prop] = await content.getBoundingClientRectProperty(prop); - }); - - await t - .expect(popupRect.top) - .eql(0); - - await t - .expect(popupRect.left) - .eql(0); - - await t - .drag(toolbar, 10000, 10000); - - await asyncForEach(['bottom', 'left', 'top', 'right'], async (prop) => { - popupRect[prop] = await content.getBoundingClientRectProperty(prop); - }); - - await t - .expect(popupRect.bottom) - .eql(700); - - await t - .expect(popupRect.right) - .eql(700); -}).before(async () => createWidget('dxPopup', { - width: 100, - height: 100, - visible: true, - dragEnabled: true, - animation: undefined, -})); - -test('Popup can not be dragged if content bigger than container', async (t) => { - const popup = new Popup('#popup'); - - const content = popup.getContent(); - const toolbar = popup.getToolbar(); - - const popupPosition: { top: number; left: number } = { - top: 0, left: 0, - }; - - const newPopupPosition: { top: number; left: number } = { - top: 0, left: 0, - }; - - await asyncForEach(['left', 'top'], async (prop) => { - popupPosition[prop] = await content.getBoundingClientRectProperty(prop); - }); - - await t - .drag(toolbar, 50, 50); - - await asyncForEach(['left', 'top'], async (prop) => { - newPopupPosition[prop] = await content.getBoundingClientRectProperty(prop); - }); - - await t - .expect(popupPosition.top) - .eql(newPopupPosition.top); - - await t - .expect(popupPosition.left) - .eql(newPopupPosition.left); -}).before(async () => { - await appendElementTo('#container', 'div', 'popup', {}); - await appendElementTo('#container', 'div', 'popupContainer', { width: '99px', height: '99px' }); - - return createWidget('dxPopup', { - position: { of: '#popupContainer' }, - container: '#popupContainer', - visible: true, - width: 100, - height: 100, - animation: undefined, - }, '#popup'); -}); - -test('Popup can be dragged outside of the container if dragOutsideBoundary is enabled', async (t) => { - const popup = new Popup('#container'); - - const content = popup.getContent(); - const toolbar = popup.getToolbar(); - - const popupPosition: { top: number; left: number } = { - top: 0, left: 0, - }; - - await t - .drag(toolbar, -10000, -10000); - - await asyncForEach(['left', 'top'], async (prop) => { - popupPosition[prop] = await content.getBoundingClientRectProperty(prop); - }); - - await t - .expect(popupPosition.top) - .lt(0); - - await t - .expect(popupPosition.left) - .lt(0); -}).before(async () => createWidget('dxPopup', { - width: 100, - height: 100, - visible: true, - dragEnabled: true, - dragOutsideBoundary: true, - animation: undefined, -})); - -const renderSwatchScope = ClientFunction(() => { - const host = document.createElement('div'); - - host.id = 'swatchHost'; - host.innerHTML = '
' - + '
' - + '
'; - - document.body.appendChild(host); - - (window as any).swatchPreviousViewPort = (window as any).DevExpress.viewPort(); - (window as any).DevExpress.viewPort('#swatchViewPort'); -}); - -const clearSwatchScope = ClientFunction(() => { - (window as any).widget?.dispose(); - - document.querySelector('#swatchHost')?.remove(); - - (window as any).DevExpress.viewPort((window as any).swatchPreviousViewPort); -}); - -test.meta({ browserSize: [700, 700] })('Popup inside a swatch can be dragged', async (t) => { - const popup = new Popup(Selector('.swatch-popup')); - - const topBefore = await popup.content.getBoundingClientRectProperty('top'); - const leftBefore = await popup.content.getBoundingClientRectProperty('left'); - - await t - .drag(popup.topToolbar, 50, 50); - - await t - .expect(await popup.content.getBoundingClientRectProperty('top')) - .eql(topBefore + 50); - - await t - .expect(await popup.content.getBoundingClientRectProperty('left')) - .eql(leftBefore + 50); -}).before(async () => { - await renderSwatchScope(); - - return createWidget('dxPopup', { - width: 100, - height: 100, - visible: true, - dragEnabled: true, - animation: undefined, - position: { of: '#swatchViewPort' }, - wrapperAttr: { class: 'swatch-popup' }, - }, '#swatchPopup'); -}).after(async () => { - await clearSwatchScope(); -}); diff --git a/e2e/testcafe-devextreme/tests/editors/overlays/popup.ts b/e2e/testcafe-devextreme/tests/editors/overlays/popup.ts deleted file mode 100644 index 5848f87a2e33..000000000000 --- a/e2e/testcafe-devextreme/tests/editors/overlays/popup.ts +++ /dev/null @@ -1,158 +0,0 @@ -import { ClientFunction, Selector } from 'testcafe'; -import Popup from 'devextreme-testcafe-models/popup'; -import url from '../../../helpers/getPageUrl'; -import asyncForEach from '../../../helpers/asyncForEach'; -import { createWidget } from '../../../helpers/createWidget'; -import { appendElementTo, setStyleAttribute } from '../../../helpers/domUtils'; - -fixture.disablePageReloads`Popup` - .page(url(__dirname, '../../container.html')); - -test('Popup should be centered regarding the container even if container is animated (T920408)', async (t) => { - await t.wait(500); - - const wrapper = Selector('#content .dx-overlay-wrapper'); - const content = wrapper.find('.dx-overlay-content'); - - const wrapperRect: { bottom: number; top: number; left: number; right: number } = { - bottom: 0, top: 0, left: 0, right: 0, - }; - const contentRect: { bottom: number; top: number; left: number; right: number } = { - bottom: 0, top: 0, left: 0, right: 0, - }; - - await asyncForEach(['bottom', 'left', 'right', 'top'], async (prop) => { - wrapperRect[prop] = await wrapper.getBoundingClientRectProperty(prop); - contentRect[prop] = await content.getBoundingClientRectProperty(prop); - }); - - const wrapperVerticalCenter = (wrapperRect.bottom + wrapperRect.top) / 2; - const wrapperHorizontalCenter = (wrapperRect.left + wrapperRect.right) / 2; - const contentVerticalCenter = (contentRect.bottom + contentRect.top) / 2; - const contentHorizontalCenter = (contentRect.left + contentRect.right) / 2; - - await t - .expect(wrapperVerticalCenter) - .within(contentVerticalCenter - 0.5, contentVerticalCenter + 0.5); - - await t - .expect(wrapperHorizontalCenter) - .within(contentHorizontalCenter - 0.5, contentHorizontalCenter + 0.5); -}).before(async (t) => { - await appendElementTo('#container', 'div', 'content', {}); - await setStyleAttribute(Selector('#content'), 'width: 100%; height: 100%;'); - await createWidget('dxPopup', { - width: 600, - height: 400, - visible: true, - }, undefined, { disableFxAnimation: false }); - - await appendElementTo('#container', 'div', 'innerContainer', {}); - await t.wait(500); - - return createWidget('dxPopup', { - position: { of: '#content' }, - container: '#content', - visible: true, - width: 100, - height: 100, - }, '#innerContainer', { disableFxAnimation: false }); -}); - -test('Popup wrapper left top corner should be the same as the container right left corner even if container is animated', async (t) => { - await t.wait(500); - - const wrapper = Selector('#content .dx-overlay-wrapper'); - const container = wrapper.parent(); - - const wrapperRect: { top: number; left: number } = { top: 0, left: 0 }; - const containerRect: { top: number; left: number } = { top: 0, left: 0 }; - - await asyncForEach(['left', 'top'], async (prop) => { - wrapperRect[prop] = await wrapper.getBoundingClientRectProperty(prop); - containerRect[prop] = await container.getBoundingClientRectProperty(prop); - }); - - await t - .expect(wrapperRect.top) - .within(containerRect.top - 0.5, containerRect.top + 0.5); - - await t - .expect(wrapperRect.left) - .within(containerRect.left - 0.5, containerRect.left + 0.5); -}).before(async (t) => { - await appendElementTo('#container', 'div', 'content', {}); - await setStyleAttribute(Selector('#content'), 'width: 100%; height: 100%;'); - await createWidget('dxPopup', { - width: 600, - height: 400, - visible: true, - }, undefined, { disableFxAnimation: false }); - - await appendElementTo('#container', 'div', 'innerContainer', {}); - await t.wait(500); - - return createWidget('dxPopup', { - position: { of: '#content' }, - container: '#content', - visible: true, - width: 100, - height: 100, - }, '#innerContainer', { disableFxAnimation: false }); -}); - -test('There should not be any errors when position.of is html (T946851)', async (t) => { - await t.expect(true).ok(); -}).before(async () => createWidget('dxPopup', { - position: { of: 'html' }, - visible: true, -})); - -test('Popup should be centered regarding the window after position.boundary is set to window', async (t) => { - const popup = new Popup('#container'); - const initialRect: { - bottom: number; - top: number; - left: number; - right: number; - } = { - bottom: 0, - top: 0, - left: 0, - right: 0, - }; - const wrapperRect = initialRect; - const contentRect = initialRect; - - await asyncForEach(['bottom', 'left', 'right', 'top'], async (prop) => { - wrapperRect[prop] = await popup - .getWrapper() - .getBoundingClientRectProperty(prop); - contentRect[prop] = await popup.getContent() - .getBoundingClientRectProperty(prop); - }); - - const wrapperVerticalCenter = (wrapperRect.bottom + wrapperRect.top) / 2; - const wrapperHorizontalCenter = (wrapperRect.left + wrapperRect.right) / 2; - const contentVerticalCenter = (contentRect.bottom + contentRect.top) / 2; - const contentHorizontalCenter = (contentRect.left + contentRect.right) / 2; - - await t - .expect(wrapperVerticalCenter) - .within(contentVerticalCenter - 0.5, contentVerticalCenter + 0.5); - - await t - .expect(wrapperHorizontalCenter) - .within(contentHorizontalCenter - 0.5, contentHorizontalCenter + 0.5); -}).before(async () => createWidget('dxPopup', { - width: 300, - height: 200, - visible: true, - animation: undefined, - position: { - boundary: '#otherContainer', - }, - onShown: ClientFunction((e) => { - e.component.option('position.boundary', window); - }), -}, undefined, { disableFxAnimation: false })); diff --git a/e2e/testcafe-devextreme/tests/editors/overlays/resizeObserverIntegration.ts b/e2e/testcafe-devextreme/tests/editors/overlays/resizeObserverIntegration.ts deleted file mode 100644 index e63cb767165a..000000000000 --- a/e2e/testcafe-devextreme/tests/editors/overlays/resizeObserverIntegration.ts +++ /dev/null @@ -1,236 +0,0 @@ -import { Selector, ClientFunction } from 'testcafe'; -import Popup from 'devextreme-testcafe-models/popup'; -import url from '../../../helpers/getPageUrl'; -import asyncForEach from '../../../helpers/asyncForEach'; -import { createWidget } from '../../../helpers/createWidget'; -import { setStyleAttribute } from '../../../helpers/domUtils'; - -fixture.disablePageReloads`Popup` - .page(url(__dirname, '../../container.html')); - -test('Popup should be centered regarding the container even if content dimension is changed during animation', async (t) => { - const popup = new Popup('#container'); - - await popup.show(); - await setStyleAttribute(Selector('#content'), 'width: 300px; height: 300px;'); - await t.wait(100); - - const wrapper = popup.getWrapper(); - const content = popup.getContent(); - - const wrapperRect: { bottom: number; top: number; left: number; right: number } = { - bottom: 0, top: 0, left: 0, right: 0, - }; - const contentRect: { bottom: number; top: number; left: number; right: number } = { - bottom: 0, top: 0, left: 0, right: 0, - }; - - await asyncForEach(['bottom', 'left', 'right', 'top'], async (prop) => { - wrapperRect[prop] = await wrapper.getBoundingClientRectProperty(prop); - contentRect[prop] = await content.getBoundingClientRectProperty(prop); - }); - - const wrapperVerticalCenter = (wrapperRect.bottom + wrapperRect.top) / 2; - const wrapperHorizontalCenter = (wrapperRect.left + wrapperRect.right) / 2; - const contentVerticalCenter = (contentRect.bottom + contentRect.top) / 2; - const contentHorizontalCenter = (contentRect.left + contentRect.right) / 2; - - await t - .expect(wrapperVerticalCenter) - .within(contentVerticalCenter - 0.5, contentVerticalCenter + 0.5); - - await t - .expect(wrapperHorizontalCenter) - .within(contentHorizontalCenter - 0.5, contentHorizontalCenter + 0.5); -}).before(async () => createWidget('dxPopup', { - width: 'auto', - height: 'auto', - contentTemplate: () => $('
').attr({ id: 'content' }).css({ width: '100px', height: '100px' }), -}, undefined, { disableFxAnimation: false })); - -test('Popup should be centered regarding the container even if popup dimension option is changed during animation', async (t) => { - const popup = new Popup('#container'); - - await popup.show(); - await setStyleAttribute(Selector('#content'), 'width: 300px; height: 300px;'); - await t.wait(100); - - const wrapper = popup.getWrapper(); - const content = popup.getContent(); - - const wrapperRect: { bottom: number; top: number; left: number; right: number } = { - bottom: 0, top: 0, left: 0, right: 0, - }; - const contentRect: { bottom: number; top: number; left: number; right: number } = { - bottom: 0, top: 0, left: 0, right: 0, - }; - - await asyncForEach(['bottom', 'left', 'right', 'top'], async (prop) => { - wrapperRect[prop] = await wrapper.getBoundingClientRectProperty(prop); - contentRect[prop] = await content.getBoundingClientRectProperty(prop); - }); - - const wrapperVerticalCenter = (wrapperRect.bottom + wrapperRect.top) / 2; - const wrapperHorizontalCenter = (wrapperRect.left + wrapperRect.right) / 2; - const contentVerticalCenter = (contentRect.bottom + contentRect.top) / 2; - const contentHorizontalCenter = (contentRect.left + contentRect.right) / 2; - - await t - .expect(wrapperVerticalCenter) - .within(contentVerticalCenter - 0.5, contentVerticalCenter + 0.5); - - await t - .expect(wrapperHorizontalCenter) - .within(contentHorizontalCenter - 0.5, contentHorizontalCenter + 0.5); -}).before(async () => createWidget('dxPopup', { - width: 'auto', - height: 'auto', - contentTemplate: () => $('
').attr({ id: 'content' }).css({ width: '100px', height: '100px' }), -}, undefined, { disableFxAnimation: false })); - -test('Popup should be centered regarding the container even if content dimension is changed', async (t) => { - const popup = new Popup('#container'); - - await popup.show(); - await setStyleAttribute(Selector('#content'), 'width: 300px; height: 300px;'); - await t.wait(100); - - const wrapper = popup.getWrapper(); - const content = popup.getContent(); - - const wrapperRect: { bottom: number; top: number; left: number; right: number } = { - bottom: 0, top: 0, left: 0, right: 0, - }; - const contentRect: { bottom: number; top: number; left: number; right: number } = { - bottom: 0, top: 0, left: 0, right: 0, - }; - - await asyncForEach(['bottom', 'left', 'right', 'top'], async (prop) => { - wrapperRect[prop] = await wrapper.getBoundingClientRectProperty(prop); - contentRect[prop] = await content.getBoundingClientRectProperty(prop); - }); - - const wrapperVerticalCenter = (wrapperRect.bottom + wrapperRect.top) / 2; - const wrapperHorizontalCenter = (wrapperRect.left + wrapperRect.right) / 2; - const contentVerticalCenter = (contentRect.bottom + contentRect.top) / 2; - const contentHorizontalCenter = (contentRect.left + contentRect.right) / 2; - - await t - .expect(wrapperVerticalCenter) - .within(contentVerticalCenter - 0.5, contentVerticalCenter + 0.5); - - await t - .expect(wrapperHorizontalCenter) - .within(contentHorizontalCenter - 0.5, contentHorizontalCenter + 0.5); -}).before(async () => createWidget('dxPopup', { - width: 'auto', - height: 'auto', - contentTemplate: () => $('
').attr({ id: 'content' }).css({ width: '100px', height: '100px' }), - animation: null, -}, undefined, { disableFxAnimation: false })); - -test.meta({ browserSize: [200, 200] })('popup should be repositioned after window resize', async (t) => { - const popup = new Popup('#container'); - - const wrapper = popup.getWrapper(); - const content = popup.getContent(); - - const wrapperRect: { bottom: number; top: number; left: number; right: number } = { - bottom: 0, top: 0, left: 0, right: 0, - }; - const contentRect: { bottom: number; top: number; left: number; right: number } = { - bottom: 0, top: 0, left: 0, right: 0, - }; - - await asyncForEach(['bottom', 'left', 'right', 'top'], async (prop) => { - wrapperRect[prop] = await wrapper.getBoundingClientRectProperty(prop); - contentRect[prop] = await content.getBoundingClientRectProperty(prop); - }); - - const wrapperVerticalCenter = (wrapperRect.bottom + wrapperRect.top) / 2; - const wrapperHorizontalCenter = (wrapperRect.left + wrapperRect.right) / 2; - const contentVerticalCenter = (contentRect.bottom + contentRect.top) / 2; - const contentHorizontalCenter = (contentRect.left + contentRect.right) / 2; - - await t - .expect(wrapperVerticalCenter) - .within(contentVerticalCenter - 0.5, contentVerticalCenter + 0.5); - - await t - .expect(wrapperHorizontalCenter) - .within(contentHorizontalCenter - 0.5, contentHorizontalCenter + 0.5); -}).before(async () => createWidget('dxPopup', { - animation: null, - visible: true, - width: 100, - height: 100, -}, undefined, { disableFxAnimation: false })); - -test('Popup dimensions should be correct after width or height animation', async (t) => { - const popup = new Popup('#container'); - const content = popup.getContent(); - - await t.wait(500); - - const contentRect: { width: number; height: number } = { - width: 0, height: 0, - }; - - await asyncForEach(['width', 'height'], async (prop) => { - contentRect[prop] = await content.getBoundingClientRectProperty(prop); - }); - - await t - .expect(contentRect.width) - .eql(300); - - await t - .expect(contentRect.height) - .eql(300); -}).before(async () => createWidget('dxPopup', { - visible: true, - animation: { - show: { - from: { width: '10px', height: '10px' }, - to: { width: '300px', height: '300px' }, - }, - }, -}, undefined, { disableFxAnimation: false })); - -test('Showing and shown events should be raised only once even after resize during animation', async (t) => { - const popup = new Popup('#container'); - - await ClientFunction(() => { - (window as any).shownCallCount = 0; - (window as any).showingCallCount = 0; - })(); - - const incShown = ClientFunction(() => { ((window as any).shownCallCount as number) += 1; }); - const incShowing = ClientFunction(() => { ((window as any).showingCallCount as number) += 1; }); - - const getShownCounter = ClientFunction(() => (window as any).shownCallCount); - const getShowingCounter = ClientFunction(() => (window as any).shownCallCount); - - await popup.option({ - onShown: incShown, - onShowing: incShowing, - }); - - await popup.show(); - - await t - .expect(await getShownCounter()) - .eql(1); - await t - .expect(await getShowingCounter()) - .eql(1); -}).before(async () => createWidget('dxPopup', { - width: 'auto', - height: 'auto', - contentTemplate: () => $('
').attr({ id: 'content' }).css({ width: '100px', height: '100px' }), -}, undefined, { disableFxAnimation: false })).after(async () => { - await ClientFunction(() => { - delete (window as any).shownCallCount; - delete (window as any).showingCallCount; - })(); -}); diff --git a/e2e/testcafe-devextreme/tests/editors/overlays/scrolling.ts b/e2e/testcafe-devextreme/tests/editors/overlays/scrolling.ts deleted file mode 100644 index 932d3eb770b1..000000000000 --- a/e2e/testcafe-devextreme/tests/editors/overlays/scrolling.ts +++ /dev/null @@ -1,146 +0,0 @@ -/* eslint-disable no-multi-str */ -import { ClientFunction } from 'testcafe'; -import Popup from 'devextreme-testcafe-models/popup'; -import { Themes } from '../../../helpers/themes'; -import url from '../../../helpers/getPageUrl'; -import { createWidget } from '../../../helpers/createWidget'; -import { - appendElementTo, - getComputedPropertyValue, - getDocumentScrollTop, - insertStylesheetRulesToPage, - removeAttribute, -} from '../../../helpers/domUtils'; - -const POPUP_CONTENT_CLASS = 'dx-popup-content'; - -fixture.disablePageReloads`Popup scrolling` - .page(url(__dirname, '../../container.html')); - -[false, true].forEach((shading) => { - [false, true].forEach((enableBodyScroll) => { - [false, true].forEach((fullScreen) => { - test.meta({ runInTheme: Themes.genericLight })(`Popup native scrolling, shading: ${shading}, enableBodyScroll: ${enableBodyScroll}, fullScreen: ${fullScreen}`, async (t) => { - const popup = new Popup('#popup'); - - const checkBodyStyles = async ({ paddingRight, overflow }) => { - await t - .expect(getComputedPropertyValue('body', 'padding-right')) - .eql(paddingRight) - .expect(getComputedPropertyValue('body', 'overflow')) - .eql(overflow) - .expect(getComputedPropertyValue('body', 'position')) - .eql('static') - .expect(getComputedPropertyValue('body', 'top')) - .eql('auto') - .expect(getComputedPropertyValue('body', 'left')) - .eql('auto'); - }; - - const checkPopupStyles = async ({ overflow, overScrollBehavior }) => { - await t - .expect(getComputedPropertyValue(`.${POPUP_CONTENT_CLASS}`, 'overflow')) - .eql(overflow) - .expect(getComputedPropertyValue(`.${POPUP_CONTENT_CLASS}`, 'overscroll-behavior')) - .eql(overScrollBehavior); - }; - - await checkBodyStyles({ paddingRight: '0px', overflow: 'visible' }); - - await insertStylesheetRulesToPage('body { padding-right: 10px; overflow: auto; }'); - - await ClientFunction(() => { - window.scrollTo(0, 300); - })(); - - await t - .expect(getDocumentScrollTop()) - .eql(300); - - await checkBodyStyles({ paddingRight: '10px', overflow: 'auto' }); - await t - .expect(getDocumentScrollTop()) - .eql(300); - - await popup.show(); - - await checkPopupStyles({ overflow: 'auto', overScrollBehavior: 'contain' }); - await checkBodyStyles({ paddingRight: enableBodyScroll ? '10px' : '25px', overflow: enableBodyScroll ? 'auto' : 'hidden' }); - await t - .expect(getDocumentScrollTop()) - .eql(300); - - await popup.hide(); - - await checkBodyStyles({ paddingRight: '10px', overflow: 'auto' }); - await t - .expect(getDocumentScrollTop()) - .eql(300); - }).before(async () => { - await appendElementTo('#container', 'div', 'scrollable-container', { height: '2000px', overflowY: 'auto' }); - await appendElementTo('#scrollable-container', 'div', 'scrollable-content', { height: '3000px' }); - - await appendElementTo('#scrollable-content', 'div', 'inner-container', { - width: '500px', height: '500px', border: '1px solid black', overflow: 'auto', - }); - - await ClientFunction(() => { - const $content = $('
'); - - for (let i = 0; i < 100; i += 1) { - $content.append(`
${i}
`); - } - - $('#scrollable-content').append($content); - })(); - - await appendElementTo('#inner-container', 'div', 'inner-content', { width: '2000px', height: '2000px' }); - await appendElementTo('#scrollable-container', 'div', 'popup', {}); - - await createWidget('dxPopup', { - width: 400, - height: 400, - shading, - enableBodyScroll, - fullScreen, - contentTemplate: ($content) => { - const popupContent = '\ -
Description
\ -
In the heart of LA\'s business district, the Downtown Inn has a welcoming staff and award winning restaurants that remain open 24 hours a day. Use our conference room facilities to conduct meetings and have a drink at our beautiful rooftop bar.
\ -
\ -
\ -
\ -
Features
\ -
\ -
Concierge
\ -
Restaurant
\ -
Valet Parking
\ -
Fitness Center
\ -
Sauna
\ -
Airport Shuttle
\ -
\ -
\ -
\ -
\ -
Rooms
\ -
\ -
Climate control
\ -
Air conditioning
\ -
Coffee/tea maker
\ -
Iron/ironing
\ -
\ -
\ -
\ -
\ -
In the heart of LA\'s business district, the Downtown Inn has a welcoming staff and award winning restaurants that remain open 24 hours a day. Use our conference room facilities to conduct meetings and have a drink at our beautiful rooftop bar.
\ - '; - - $content.html(popupContent); - }, - }, '#popup'); - }).after(async () => { - await removeAttribute('body', 'style'); - }); - }); - }); -}); diff --git a/e2e/testcafe-devextreme/tests/editors/overlays/toast.ts b/e2e/testcafe-devextreme/tests/editors/overlays/toast.ts deleted file mode 100644 index 0236d3113753..000000000000 --- a/e2e/testcafe-devextreme/tests/editors/overlays/toast.ts +++ /dev/null @@ -1,60 +0,0 @@ -import { createScreenshotsComparer } from 'devextreme-screenshot-comparer'; -import { ClientFunction, Selector } from 'testcafe'; -import url from '../../../helpers/getPageUrl'; -import { getThemeName, testScreenshot } from '../../../helpers/themeUtils'; -import { insertStylesheetRulesToPage, setClassAttribute } from '../../../helpers/domUtils'; - -fixture.disablePageReloads`Toast` - .page(url(__dirname, '../../container.html')); - -const types = ['info', 'warning', 'error', 'success']; -const STACK_CONTAINER_SELECTOR = '.dx-toast-stack'; - -const showToast = ClientFunction( - (type) => { - (window as any).DevExpress.ui.notify( - { - message: `Toast ${type}`, - type, - displayTime: 35000000, - animation: { - show: { - type: 'fade', duration: 0, - }, - hide: { type: 'fade', duration: 0 }, - }, - }, - { - position: 'top center', - direction: 'down-push', - }, - ); - }, -); - -const hideAllToasts = ClientFunction(() => { - (window as any).DevExpress.ui.hideToasts(); -}); - -test('Toasts', async (t) => { - const { takeScreenshot, compareResults } = createScreenshotsComparer(t); - - await testScreenshot(t, takeScreenshot, 'Toasts.png', { element: STACK_CONTAINER_SELECTOR }); - - await t - .expect(compareResults.isValid()) - .ok(compareResults.errorMessages()); -}).before(async () => { - await Promise.all(types.map((type) => showToast(type))); - - await insertStylesheetRulesToPage(`${STACK_CONTAINER_SELECTOR} { padding: 20px; }`); - await setClassAttribute(Selector(STACK_CONTAINER_SELECTOR), `dx-theme-${getThemeName()}-typography`); -}).after(async () => { - await hideAllToasts(); - - await ClientFunction(() => { - $(STACK_CONTAINER_SELECTOR).remove(); - }, { - dependencies: { STACK_CONTAINER_SELECTOR }, - })(); -}); diff --git a/e2e/testcafe-devextreme/tests/editors/overlays/toolbarIntegration.ts b/e2e/testcafe-devextreme/tests/editors/overlays/toolbarIntegration.ts deleted file mode 100644 index 86cc45698952..000000000000 --- a/e2e/testcafe-devextreme/tests/editors/overlays/toolbarIntegration.ts +++ /dev/null @@ -1,249 +0,0 @@ -import { createScreenshotsComparer } from 'devextreme-screenshot-comparer'; -import Popup from 'devextreme-testcafe-models/popup'; -import Popover from 'devextreme-testcafe-models/popover'; -import Toolbar from 'devextreme-testcafe-models/toolbar/toolbar'; -import { Selector } from 'testcafe'; -import { isMaterial, testScreenshot } from '../../../helpers/themeUtils'; -import url from '../../../helpers/getPageUrl'; -import { createWidget } from '../../../helpers/createWidget'; -import { insertStylesheetRulesToPage } from '../../../helpers/domUtils'; - -fixture.disablePageReloads`Popup_toolbar` - .page(url(__dirname, '../../container.html')); - -const COMPONENT_SELECTOR = '#container'; -const CLOSE_BUTTON_SELECTOR = '.dx-closebutton'; -const ANIMATION_DELAY = 500; - -[ - { name: 'dxPopup', Class: Popup }, - { name: 'dxPopover', Class: Popover }, -].forEach(({ name, Class }) => { - ['bottom', 'top'].forEach((toolbar) => { - [true, false].forEach((rtlEnabled) => { - test.meta({ browserSize: [600, 400] })(`Extended toolbar should be used in ${name},rtlEnabled=${rtlEnabled},toolbar=${toolbar}`, async (t) => { - const { takeScreenshot, compareResults } = createScreenshotsComparer(t); - const instance = new Class(COMPONENT_SELECTOR); - - if (toolbar === 'top') { - const topToolbar = new Toolbar(instance.getToolbar()); - await topToolbar.option('overflowMenuVisible', true); - } else { - const bottomToolbar = new Toolbar(instance.getBottomToolbar()); - await bottomToolbar.option('overflowMenuVisible', true); - } - - await t.hover(Selector(CLOSE_BUTTON_SELECTOR)); - - await testScreenshot(t, takeScreenshot, `${name.replace('dx', '')}_${toolbar}_toolbar_menu,rtlEnabled=${rtlEnabled}.png`); - - await t - .expect(compareResults.isValid()) - .ok(compareResults.errorMessages()); - }).before(async () => { - if (isMaterial()) { - await insertStylesheetRulesToPage('.dx-overlay-content, .dx-overlay-content input { font-family: sans-serif !important; }'); - } - return createWidget(name as 'dxPopup' | 'dxPopover', { - showCloseButton: true, - // eslint-disable-next-line no-multi-str - contentTemplate: () => $('
').text('\ - Lorem Ipsum is simply dummy text of the printing and typesetting industry.\ - Lorem Ipsum has been the industrys standard dummy text ever since the 1500s,\ - when an unknown printer took a galley of type and scrambled it to make a type specimen book.\ - '), - width: '60%', - height: 300, - showTitle: true, - rtlEnabled, - visible: true, - animation: undefined, - target: COMPONENT_SELECTOR, - hideOnOutsideClick: true, - toolbarItems: [{ - location: 'before', - widget: 'dxButton', - options: { - icon: 'back', - }, - toolbar, - }, { - location: 'before', - widget: 'dxButton', - locateInMenu: 'auto', - options: { - icon: 'refresh', - }, - toolbar, - }, { - location: 'center', - locateInMenu: 'never', - template() { - return $('
Popup\'s title
'); - }, - toolbar, - }, { - location: 'after', - widget: 'dxSelectBox', - locateInMenu: 'auto', - options: { - width: 140, - items: [1, 2, 3, 4, 5], - value: 3, - }, - toolbar, - }, { - location: 'after', - widget: 'dxButton', - locateInMenu: 'auto', - options: { - icon: 'plus', - }, - toolbar, - }, { - locateInMenu: 'always', - widget: 'dxButton', - options: { - icon: 'save', - text: 'Save', - }, - toolbar, - }, { - widget: 'dxButton', - toolbar: toolbar === 'top' - ? 'bottom' - : 'top', - location: 'before', - options: { - icon: 'email', - }, - }, { - widget: 'dxButton', - toolbar: toolbar === 'top' - ? 'bottom' - : 'top', - location: 'after', - options: { - text: 'Close', - }, - }], - }); - }); - }); - }); -}); - -function getItemConfig( - text: string, - toolbar: 'top' | 'bottom' = 'top', - location: 'before' | 'center' | 'after' = 'after', - locateInMenu: 'auto' | 'none' = 'none', -) { - return { - text, - toolbar, - locateInMenu, - location, - }; -} - -const toolbarItems = [ - getItemConfig('First Item'), - getItemConfig('Second Item', 'top', 'after', 'auto'), - getItemConfig('Third Item', 'top', 'after', 'auto'), - getItemConfig('!@#$%^&*()-+=[]{}<>|:;.,!?~^*_(){}<>[]:-=+', 'bottom', 'before'), - getItemConfig('First Item', 'bottom'), - getItemConfig('Second Item', 'bottom', 'after', 'auto'), - getItemConfig('Third Item', 'bottom', 'after', 'auto'), -]; - -const baseConfiguration = { - title: '!@#$%^&*()-+=[]{}<>|:;.,!?~^*_(){}<>[]:-=+', - width: 'auto', - height: 'auto', - showCloseButton: false, - contentTemplate: () => $('
') - .width(300) - .height(300), -}; - -test.meta({ browserSize: [600, 600] })('Popup toolbars with wide elements and overflow menu if hidden on init with toolbar items', async (t) => { - const { takeScreenshot, compareResults } = createScreenshotsComparer(t); - const instance = new Popup(COMPONENT_SELECTOR); - await instance.option({ visible: true }); - - await t - .wait(ANIMATION_DELAY) - .click(instance.getOverflowButton().element); - - await testScreenshot(t, takeScreenshot, 'Popup toolbars with wide elements and overflow menu before items rebinding.png'); - - const items = await instance.option('toolbarItems'); - items[2].visible = false; - await instance.option('toolbarItems', [...items]); - - await t.click(instance.getOverflowButton().element); - - await testScreenshot(t, takeScreenshot, 'Popup toolbars with wide elements and overflow menu after items rebinding.png'); - - await t - .expect(compareResults.isValid()) - .ok(compareResults.errorMessages()); -}).before(async () => createWidget('dxPopup', { - ...baseConfiguration, - toolbarItems, - visible: false, -})); - -test.meta({ browserSize: [600, 600] })('Popup toolbars with wide elements and overflow menu if hidden on init with no toolbar items', async (t) => { - const { takeScreenshot, compareResults } = createScreenshotsComparer(t); - const instance = new Popup(COMPONENT_SELECTOR); - await instance.option({ visible: true, toolbarItems }); - - await t - .wait(ANIMATION_DELAY) - .click(instance.getOverflowButton().element); - - await testScreenshot(t, takeScreenshot, 'Toolbar before items rebinding if it was hidden without items on init.png'); - - const items = await instance.option('toolbarItems'); - items[2].visible = false; - await instance.option('toolbarItems', [...items]); - - await t.click(instance.getOverflowButton().element); - - await testScreenshot(t, takeScreenshot, 'Toolbar after items rebinding if it was hidden without items on init.png'); - - await t - .expect(compareResults.isValid()) - .ok(compareResults.errorMessages()); -}).before(async () => createWidget('dxPopup', { - ...baseConfiguration, - toolbarItems: [], - visible: false, -})); - -test.meta({ browserSize: [600, 600] })('Popup toolbars with wide elements and overflow menu if shown on init with toolbar items', async (t) => { - const { takeScreenshot, compareResults } = createScreenshotsComparer(t); - const instance = new Popup(COMPONENT_SELECTOR); - - await t.click(instance.getOverflowButton().element); - - await testScreenshot(t, takeScreenshot, 'Toolbar before items rebinding if it was visible with items on init.png'); - - const items = await instance.option('toolbarItems'); - items[2].visible = false; - await instance.option('toolbarItems', [...items]); - - await t.click(instance.getOverflowButton().element); - - await testScreenshot(t, takeScreenshot, 'Toolbar after items rebinding if it was visible with items on init.png'); - - await t - .expect(compareResults.isValid()) - .ok(compareResults.errorMessages()); -}).before(async () => createWidget('dxPopup', { - ...baseConfiguration, - toolbarItems, - visible: true, -}));