2
0

refactor(editor): ♻️ Undo / Redo buttons + structure refacto

Yet another huge refacto... While implementing undo and redo features I understood that I updated the stored typebot too many times (i.e. on each key input) so I had to rethink it entirely. I also moved around some files.
This commit is contained in:
Baptiste Arnaud
2022-02-02 08:05:02 +01:00
parent fc1d654772
commit 8a350eee6c
153 changed files with 1512 additions and 1352 deletions

View File

@ -9,6 +9,7 @@ import {
VideoBubbleContentType,
} from 'models'
import { typebotViewer } from '../../services/selectorUtils'
import { generate } from 'short-uuid'
const videoSrc =
'http://commondatastorage.googleapis.com/gtv-videos-bucket/sample/ForBiggerEscapes.mp4'
@ -18,7 +19,7 @@ const vimeoVideoSrc = 'https://vimeo.com/649301125'
test.describe.parallel('Video bubble step', () => {
test.describe('Content settings', () => {
test('should import video url correctly', async ({ page }) => {
const typebotId = 'video-bubble-step-link'
const typebotId = generate()
await createTypebots([
{
id: typebotId,
@ -42,7 +43,7 @@ test.describe.parallel('Video bubble step', () => {
test.describe('Preview', () => {
test('should display video correctly', async ({ page }) => {
const typebotId = 'image-bubble-step-preview-video'
const typebotId = generate()
await createTypebots([
{
id: typebotId,
@ -64,7 +65,7 @@ test.describe.parallel('Video bubble step', () => {
})
test('should display youtube video correctly', async ({ page }) => {
const typebotId = 'image-bubble-step-preview-youtube'
const typebotId = generate()
await createTypebots([
{
id: typebotId,
@ -88,7 +89,7 @@ test.describe.parallel('Video bubble step', () => {
})
test('should display vimeo video correctly', async ({ page }) => {
const typebotId = 'image-bubble-step-preview-vimeo'
const typebotId = generate()
await createTypebots([
{
id: typebotId,