Skip to content

Commit

Permalink
fix(FEC-13614): Fix types and webpack settings (#690)
Browse files Browse the repository at this point in the history
Resolves FEC-13614
Related prs:
kaltura/playkit-js-ui#838

---------

Co-authored-by: JonathanTGold <jonathan.gold@[email protected]>
  • Loading branch information
JonathanTGold and JonathanTGold authored Jan 9, 2024
1 parent 0d3e00a commit 9fbc013
Show file tree
Hide file tree
Showing 9 changed files with 25 additions and 57 deletions.
25 changes: 12 additions & 13 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,36 +26,35 @@
"access": "public"
},
"scripts": {
"ovp:serve": "webpack serve --open --mode development --env playerType=ovp",
"ovp:watch": "webpack --watch --mode development --env playerType=ovp",
"ovp:build:dev": "webpack --mode development --env playerType=ovp",
"ovp:build:prod": "webpack --mode production --env playerType=ovp",
"serve:ovp": "webpack serve --open --mode development --env playerType=ovp",
"watch:ovp": "webpack --watch --mode development --env playerType=ovp",
"build:ovp": "webpack --mode production --env playerType=ovp",
"ott:serve": "webpack serve --open --mode development --env playerType=ott",
"ott:watch": "webpack --watch --mode development --env playerType=ott",
"ott:build:dev": "webpack --mode development --env playerType=ott",
"ott:build:prod": "webpack --mode production --env playerType=ott",
"build-dev:ovp": "webpack --mode development --env playerType=ovp",
"serve:ott": "webpack serve --open --mode development --env playerType=ott",
"watch:ott": "webpack --watch --mode development --env playerType=ott",
"build:ott": "webpack --mode production --env playerType=ott",
"clean": "rm -rf dist/*",
"build": "yarn run clean && yarn run ovp:build:prod && yarn run ott:build:prod && yarn run build:types",
"build-dev:ott": "webpack --mode development --env playerType=ott",
"build": "yarn run clean && yarn run build:ovp && yarn run build:ott && yarn run build:types",
"build:types": "tsc --build tsconfig-lib.json && mkdir -p lib && api-extractor run --local",
"type-check": "tsc --noEmit",
"type-check:watch": "yarn run type-check -- --watch",
"test": "karma start karma.conf.js",
"test:debug": "DEBUG_UNIT_TESTS=1 karma start karma.conf.js --auto-watch --no-single-run --browsers Chrome",
"test:watch": "karma start karma.conf.js --auto-watch --no-single-run",
"lint": "eslint src/ tests/ --ext .js --ext .ts",
"lint:fix": "yarn run lint -- --fix",
"lint:fix": "yarn run lint --fix",
"prettier": "prettier --write .",
"clean": "rimraf dist/*",
"pushTaggedRelease": "git push --follow-tags --no-verify origin master",
"release": "standard-version"
"release": "standard-version",
"precommit": "yarn run build && yarn run type-check && yarn run test && yarn run lint"
},
"dependencies": {
"@playkit-js/playkit-js": "^0.84.3-canary.0-22c594e",
"@playkit-js/playkit-js-dash": "^1.36.1-canary.0-9f58c2a",
"@playkit-js/playkit-js-hls": "^1.32.10-canary.0-0fe6f51",
"@playkit-js/playkit-js-providers": "^2.40.2-canary.0-45b4098",
"@playkit-js/playkit-js-ui": "^0.77.14-canary.0-8ddc9e5",
"@playkit-js/playkit-js-ui": "^0.77.14-canary.0-1a5779a",
"hls.js": "1.4.11",
"shaka-player": "4.7.0"
},
Expand Down
14 changes: 7 additions & 7 deletions src/common/ui-wrapper.ts
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
import { UIManager, Components } from '@playkit-js/playkit-js-ui';
import {
UIManager,
Components,
KPUIAddComponent,
KPUIRemoveComponent
} from '@playkit-js/playkit-js-ui';
import { Env, getLogger, Utils } from '@playkit-js/playkit-js';
import { KalturaPlayer } from '../kaltura-player';
import { UiConfig } from '../types';
import {
KalturaPlayerConfig,
KPUIAddComponent,
KPUIRemoveComponent,
PluginsConfig
} from '../types';
import { KalturaPlayerConfig, PluginsConfig } from '../types';

/**
* The logger of the UIWrapper class.
Expand Down
2 changes: 0 additions & 2 deletions src/types/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,5 @@ export * from './plugins-config';
export * from './prebid-config';
export * from './sources-config';
export * from './thumbnail-config';
export * from './ui-component';
export * from './ui-component-options';
export * from './ui-config';
export * from './visibility-config';
10 changes: 0 additions & 10 deletions src/types/ui-component-options.ts

This file was deleted.

16 changes: 0 additions & 16 deletions src/types/ui-component.ts

This file was deleted.

2 changes: 0 additions & 2 deletions src/types/ui-config.ts
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
// TODO extends UIOptionsObject {
import { UIOptionsObject } from '@playkit-js/playkit-js-ui';

export interface UiConfig extends UIOptionsObject {
disable?: boolean;
css?: string;
customPreset?: { template: () => any; condition: () => any }[];
targetId: string // TODO temp!! delete after fix
}
3 changes: 1 addition & 2 deletions tsconfig-lib.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,5 @@
"declaration": true,
"declarationMap": true
},
"include": ["src/**/*", "./src/types/global/*.d.ts"],
"exclude": ["node_modules", "dist/**/*", "demo/libs/**/*"]
"include": ["src/**/*"]
}
2 changes: 1 addition & 1 deletion webpack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ module.exports = (env, { mode }) => {
path: path.resolve(__dirname, 'dist'),
library: {
name: 'KalturaPlayer',
type: 'var'
type: 'umd'
},
clean: mode === 'development'
},
Expand Down
8 changes: 4 additions & 4 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -1177,10 +1177,10 @@
resolved "https://registry.yarnpkg.com/@playkit-js/playkit-js-providers/-/playkit-js-providers-2.40.2-canary.0-45b4098.tgz#21f5845404782130e8d01aeaae7bff0c4ed7e607"
integrity sha512-n/nJJtNcZiZmyoEbHqBlK6mAq1T+I69yvAY8QjHjvQb7WGjemrevxyXNXckaQc0y95QnMBTXh0IcqGV4XxajLQ==

"@playkit-js/playkit-js-ui@^0.77.14-canary.0-8ddc9e5":
version "0.77.14-canary.0-8ddc9e5"
resolved "https://registry.yarnpkg.com/@playkit-js/playkit-js-ui/-/playkit-js-ui-0.77.14-canary.0-8ddc9e5.tgz#5e40e87d4c1e9e3af4c53c4f03eecad12c417e00"
integrity sha512-VMXo6C0H3lW5cOwNjelcAn7MZdxNRkvZPenejDkT1aaZWu91QKHAkwNNyS79n9oI6uBCoV8iFYDaF2pBE18cpw==
"@playkit-js/playkit-js-ui@^0.77.14-canary.0-1a5779a":
version "0.77.14-canary.0-1a5779a"
resolved "https://registry.yarnpkg.com/@playkit-js/playkit-js-ui/-/playkit-js-ui-0.77.14-canary.0-1a5779a.tgz#c11c73118d2aff656991b0f8a5d41dc031a7ed6a"
integrity sha512-fkQhj66/3DG1I4ccNaEwMftyFppiGz7Rj/IsLy52B1JjtQNPyx9zVl0VMRuVy49JFvFh7dg0pak8kemej/W/yQ==
dependencies:
preact "^10.3.4"
preact-i18n "^2.0.0-preactx.2"
Expand Down

0 comments on commit 9fbc013

Please sign in to comment.