refactor: standardize formatting and enhance DocumentSchema
- Updated compose.yaml to use consistent quotation marks for port and labels. - Refactored package.json to improve readability of Jest configuration. - Enhanced DocumentSchema by adding a new event type for cursor movement and improving formatting for better clarity. - Consolidated import statements in document.schema.ts for consistency and readability. - Improved error handling and validation across various methods in DocumentSchema to enhance user experience. These changes improve code maintainability and readability, ensuring a more consistent and user-friendly experience in the Document management features.
This commit is contained in:
12
compose.yaml
12
compose.yaml
@@ -6,7 +6,7 @@ services:
|
|||||||
dockerfile: Dockerfile
|
dockerfile: Dockerfile
|
||||||
pull_policy: always
|
pull_policy: always
|
||||||
ports:
|
ports:
|
||||||
- '8888:3069'
|
- "8888:3069"
|
||||||
environment:
|
environment:
|
||||||
- NODE_ENV=development
|
- NODE_ENV=development
|
||||||
- DISABLE_AUTH=false
|
- DISABLE_AUTH=false
|
||||||
@@ -51,11 +51,11 @@ services:
|
|||||||
- LIVEKIT_CERT_FILE=/path/to/turn.crt
|
- LIVEKIT_CERT_FILE=/path/to/turn.crt
|
||||||
- LIVEKIT_KEY_FILE=/path/to/turn.key
|
- LIVEKIT_KEY_FILE=/path/to/turn.key
|
||||||
labels:
|
labels:
|
||||||
- 'traefik.enable=true'
|
- "traefik.enable=true"
|
||||||
- 'traefik.http.routers.api.rule=Host(`api.epess.org`)'
|
- "traefik.http.routers.api.rule=Host(`api.epess.org`)"
|
||||||
- 'traefik.http.routers.api.entrypoints=web'
|
- "traefik.http.routers.api.entrypoints=web"
|
||||||
- 'traefik.http.routers.api.service=api'
|
- "traefik.http.routers.api.service=api"
|
||||||
- 'traefik.http.services.api.loadbalancer.server.port=3069'
|
- "traefik.http.services.api.loadbalancer.server.port=3069"
|
||||||
networks:
|
networks:
|
||||||
- epess-net
|
- epess-net
|
||||||
restart: always
|
restart: always
|
||||||
|
|||||||
10
package.json
10
package.json
@@ -140,13 +140,19 @@
|
|||||||
"@css-inline/css-inline-linux-x64-musl": "^0.14.3"
|
"@css-inline/css-inline-linux-x64-musl": "^0.14.3"
|
||||||
},
|
},
|
||||||
"jest": {
|
"jest": {
|
||||||
"moduleFileExtensions": ["js", "json", "ts"],
|
"moduleFileExtensions": [
|
||||||
|
"js",
|
||||||
|
"json",
|
||||||
|
"ts"
|
||||||
|
],
|
||||||
"rootDir": "src",
|
"rootDir": "src",
|
||||||
"testRegex": ".*\\.spec\\.ts$",
|
"testRegex": ".*\\.spec\\.ts$",
|
||||||
"transform": {
|
"transform": {
|
||||||
"^.+\\.(t|j)s$": "ts-jest"
|
"^.+\\.(t|j)s$": "ts-jest"
|
||||||
},
|
},
|
||||||
"collectCoverageFrom": ["**/*.(t|j)s"],
|
"collectCoverageFrom": [
|
||||||
|
"**/*.(t|j)s"
|
||||||
|
],
|
||||||
"coverageDirectory": "../coverage",
|
"coverageDirectory": "../coverage",
|
||||||
"testEnvironment": "node"
|
"testEnvironment": "node"
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -7,5 +7,6 @@ export enum DocumentEvent {
|
|||||||
ACTIVE_DOCUMENT_ID_CHANGED = 'document_active_document_id_changed',
|
ACTIVE_DOCUMENT_ID_CHANGED = 'document_active_document_id_changed',
|
||||||
CLIENT_REQUEST_SYNC = 'document_client_request_sync',
|
CLIENT_REQUEST_SYNC = 'document_client_request_sync',
|
||||||
SERVER_REQUEST_SYNC = 'document_server_request_sync',
|
SERVER_REQUEST_SYNC = 'document_server_request_sync',
|
||||||
|
CURSOR_MOVED = 'document_cursor_moved',
|
||||||
AI_SUGGESTION = 'document_ai_suggestion',
|
AI_SUGGESTION = 'document_ai_suggestion',
|
||||||
}
|
}
|
||||||
|
|||||||
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user