From e08d03988f9d0cd44d20bc19fb85de335e88bb9a Mon Sep 17 00:00:00 2001 From: MF Date: Mon, 7 Nov 2022 15:54:36 +1100 Subject: [PATCH] fix CI error (#1045) * fix CI error * change the CI triggering event to pull_request --- .github/workflows/ci-cd.yml | 2 +- packages/rrweb-player/src/utils.ts | 2 +- packages/rrweb-player/typings/index.d.ts | 3 ++- packages/rrweb/tsconfig.json | 16 +++++++++++----- 4 files changed, 15 insertions(+), 8 deletions(-) mode change 100644 => 100755 packages/rrweb-player/typings/index.d.ts diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index 6f98b26d..4a0355b0 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -1,6 +1,6 @@ name: Tests -on: [push, pull_request_target] +on: [push, pull_request] concurrency: ${{ github.workflow }}-${{ github.ref }} diff --git a/packages/rrweb-player/src/utils.ts b/packages/rrweb-player/src/utils.ts index 796d1810..2a3f2921 100644 --- a/packages/rrweb-player/src/utils.ts +++ b/packages/rrweb-player/src/utils.ts @@ -16,7 +16,7 @@ declare global { } import { EventType, IncrementalSource } from 'rrweb'; -import type { eventWithTime } from 'rrweb/typings/types'; +import type { eventWithTime } from '@rrweb/types'; export function inlineCss(cssObj: Record): string { let style = ''; diff --git a/packages/rrweb-player/typings/index.d.ts b/packages/rrweb-player/typings/index.d.ts old mode 100644 new mode 100755 index b6d980b0..c3c3b802 --- a/packages/rrweb-player/typings/index.d.ts +++ b/packages/rrweb-player/typings/index.d.ts @@ -1,4 +1,5 @@ -import { eventWithTime, playerConfig } from 'rrweb/typings/types'; +import { playerConfig } from 'rrweb/typings/types'; +import type { eventWithTime } from '@rrweb/types'; import { Replayer, mirror } from 'rrweb'; import { SvelteComponent } from 'svelte'; diff --git a/packages/rrweb/tsconfig.json b/packages/rrweb/tsconfig.json index 268d008f..fb1b407a 100644 --- a/packages/rrweb/tsconfig.json +++ b/packages/rrweb/tsconfig.json @@ -9,24 +9,30 @@ "preserveConstEnums": true, "rootDir": "src", "outDir": "build", - "lib": ["es6", "dom"], + "lib": [ + "es6", + "dom" + ], "downlevelIteration": true, "importsNotUsedAsValues": "error", "strictBindCallApply": true, "composite": true }, "references": [ + { + "path": "../types" + }, { "path": "../rrdom" }, { "path": "../rrweb-snapshot" - }, - { - "path": "../types" } ], - "exclude": ["test", "scripts"], + "exclude": [ + "test", + "scripts" + ], "include": [ "src", "node_modules/@types/css-font-loading-module/index.d.ts",