@layers-app/editor 0.7.24-beta.1 → 0.7.24

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/README.md +4 -14
  2. package/package.json +4 -9
package/README.md CHANGED
@@ -153,7 +153,6 @@ Use **StylesProvider** to add styling to your HTML content.
153
153
 
154
154
  To start working with image uploads, use the **fetchUploadMedia** function, which takes three parameters: **file**, **success**, and **error**. After successfully uploading the image to your service, you should call the **success** function and pass two required arguments: the **URL** of the image and its **ID**.
155
155
  Optional: You can also pass two optional parameters: **signal** and **onProgress**. The **signal** allows you to cancel an ongoing upload using an AbortController, and **onProgress** provides the current upload progress in percent — useful for displaying a progress bar or loading state.
156
-
157
156
  ```
158
157
  const fetchUploadMedia = async (
159
158
  file: File,
@@ -371,9 +370,9 @@ For uploading a file or audio, you might need the third parameter "data".
371
370
  }
372
371
  };
373
372
  ```
374
-
375
373
  </details>
376
374
 
375
+
377
376
  <details>
378
377
  <summary>
379
378
  🤖 AI
@@ -381,6 +380,7 @@ For uploading a file or audio, you might need the third parameter "data".
381
380
 
382
381
  ## Connect AI
383
382
 
383
+
384
384
  ```
385
385
  const fetchPromptResult = async (
386
386
  prompt: string,
@@ -423,9 +423,9 @@ For uploading a file or audio, you might need the third parameter "data".
423
423
  fetchPromptResult={fetchPromptResult}
424
424
  />
425
425
  ```
426
-
427
426
  </details>
428
427
 
428
+
429
429
  <details>
430
430
  <summary>
431
431
  👥 Collaboration
@@ -512,7 +512,6 @@ npm run test-unit-watch
512
512
  ```
513
513
 
514
514
  ### Unit Test Files Location
515
-
516
515
  - `__tests__/unit/` - Unit test files
517
516
  - Test files follow the pattern: `*.test.ts` or `*.test.tsx`
518
517
 
@@ -537,13 +536,11 @@ npm run test:e2e:headed
537
536
  ```
538
537
 
539
538
  ### E2E Test Files Location
540
-
541
539
  - `__tests__/e2e/` - End-to-end test files
542
540
  - `__tests__/regression/` - Regression test files
543
541
  - Test files follow the pattern: `*.spec.js`, `*.spec.mjs`, or `*.spec.ts`
544
542
 
545
543
  ### Browser Support
546
-
547
544
  - **WebKit** (Safari) - Primary browser for CI/CD
548
545
  - **Chromium** and **Firefox** - Available for local testing
549
546
 
@@ -563,7 +560,6 @@ npm run start-test-server
563
560
  ## Test Configuration
564
561
 
565
562
  ### Playwright Configuration
566
-
567
563
  - **Config file**: `playwright.config.js`
568
564
  - **Test directory**: `./__tests__/e2e/`
569
565
  - **Browser**: WebKit (optimized for CI)
@@ -572,7 +568,6 @@ npm run start-test-server
572
568
  - **Retries**: 2 retries in CI, 0 locally
573
569
 
574
570
  ### Vitest Configuration
575
-
576
571
  - **Config file**: `vitest.config.mts`
577
572
  - **Environment**: jsdom
578
573
  - **Setup file**: `vitest.setup.mts`
@@ -581,13 +576,11 @@ npm run start-test-server
581
576
  ## CI/CD Testing
582
577
 
583
578
  Tests run automatically on:
584
-
585
579
  - **Push** to `main` or `dev` branches
586
580
  - **Pull requests** to `main` or `dev` branches
587
581
  - **Manual trigger** via GitHub Actions
588
582
 
589
583
  ### GitHub Actions Workflow
590
-
591
584
  - **File**: `.github/workflows/tests.yml`
592
585
  - **Runner**: Ubuntu Latest
593
586
  - **Node.js**: Version 20
@@ -600,8 +593,7 @@ Tests run automatically on:
600
593
 
601
594
  ```javascript
602
595
  // __tests__/e2e/example.spec.mjs
603
- import { expect, test } from '@playwright/test';
604
-
596
+ import { test, expect } from '@playwright/test';
605
597
  import { focusEditor } from '../utils/index.mjs';
606
598
 
607
599
  test('Can type text in editor', async ({ page }) => {
@@ -669,13 +661,11 @@ Common test utilities are available in `__tests__/utils/index.mjs`:
669
661
  ## Performance
670
662
 
671
663
  ### Test Execution Times
672
-
673
664
  - **Unit Tests**: ~10-30 seconds
674
665
  - **E2E Tests (first run)**: ~3-4 minutes (includes browser installation)
675
666
  - **E2E Tests (cached)**: ~1-2 minutes (uses cached browsers)
676
667
 
677
668
  ### Optimization Features
678
-
679
669
  - **Browser Caching**: Playwright browsers cached in CI
680
670
  - **Single Worker**: Prevents race conditions in CI
681
671
  - **WebKit Only**: Faster than multi-browser matrix
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@layers-app/editor",
3
3
  "private": false,
4
- "version": "0.7.24-beta.1",
4
+ "version": "0.7.24",
5
5
  "type": "module",
6
6
  "scripts": {
7
7
  "start": "VITE_LAYERS=true vite --mode full ",
@@ -14,18 +14,13 @@
14
14
  "generate-dts": "tsc --project tsconfig.lib.json",
15
15
  "dev:local": "cross-env NODE_ENV=development concurrently \"npm:server:ws\" \"vite --host\"",
16
16
  "server:ws": "concurrently \"cd server && npm start\"",
17
- "server:smart-paste": "cd server && npm start",
18
- "dev:full": "concurrently \"npm run start\" \"npm run server:smart-paste\"",
19
17
  "format": "prettier --write .",
20
18
  "format:check": "prettier --check .",
21
19
  "test:e2e": "playwright test",
22
20
  "test:e2e:ui": "playwright test --ui",
23
21
  "test:e2e:debug": "playwright test --debug",
24
22
  "test:e2e:headed": "playwright test --headed",
25
- "start-test-server": "VITE_LAYERS=true vite --mode full --port 3000 --strictPort --host localhost",
26
- "test": "vitest run",
27
- "test:watch": "vitest",
28
- "test:coverage": "vitest run --coverage"
23
+ "start-test-server": "VITE_LAYERS=true vite --mode full --port 3000 --strictPort --host localhost"
29
24
  },
30
25
  "publishConfig": {
31
26
  "access": "public"
@@ -38,6 +33,7 @@
38
33
  "dependencies": {
39
34
  "@excalidraw/excalidraw": "^0.18.0",
40
35
  "@floating-ui/react": "^0.27.16",
36
+ "@layers-app/editor-video": "^0.1.4",
41
37
  "@lexical/file": "^0.38.2",
42
38
  "@lexical/headless": "^0.38.2",
43
39
  "@lexical/markdown": "^0.38.2",
@@ -102,8 +98,7 @@
102
98
  "vite-plugin-css-injected-by-js": "^3.5.0",
103
99
  "vite-plugin-dts": "^4.0.0-beta.1",
104
100
  "vite-plugin-static-copy": "^2.3.2",
105
- "vite-plugin-svgr": "^4.2.0",
106
- "vitest": "^4.0.18"
101
+ "vite-plugin-svgr": "^4.2.0"
107
102
  },
108
103
  "overrides": {
109
104
  "nanoid": "^5.0.9",