Skip to content

Commit

Permalink
chore(cellnav): add support for typescript
Browse files Browse the repository at this point in the history
  • Loading branch information
mportuga committed Apr 12, 2024
1 parent fc29bb4 commit df1b293
Show file tree
Hide file tree
Showing 6 changed files with 120 additions and 3 deletions.
93 changes: 90 additions & 3 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,8 @@
"shelljs": "^0.8.2",
"text-loader": "^0.0.1",
"time-grunt": "^1.4.0",
"ts-loader": "^9.5.1",
"typescript": "^5.4.5",
"validate-commit-message": "^3.0.1",
"webdriver-manager": "^12.1.7",
"webpack": "^5.74.0",
Expand Down
8 changes: 8 additions & 0 deletions packages/cellnav/src/ts/cell-nav.constants.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
export const FEATURE_NAME = 'gridCellNav';
export const CELL_NAV_EVENT = 'cellNav';
export const direction = {LEFT: 0, RIGHT: 1, UP: 2, DOWN: 3, PG_UP: 4, PG_DOWN: 5};
export const EVENT_TYPE = {
KEYDOWN: 0,
CLICK: 1,
CLEAR: 2
};
4 changes: 4 additions & 0 deletions packages/cellnav/tsconfig.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"extends": "../tsconfig.json",
"include": ["./**/*.ts"]
}
11 changes: 11 additions & 0 deletions tsconfig.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"compilerOptions": {
"outDir": "./dist/",
"noImplicitAny": true,
"module": "es6",
"target": "es5",
"allowJs": true,
"moduleResolution": "node"
},
"include": ["./packages/**/*.ts"]
}
5 changes: 5 additions & 0 deletions webpack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,11 @@ module.exports = {
},
module: {
rules: [
{
test: /\.ts?$/,
use: 'ts-loader',
exclude: /node_modules/,
},
{
test: /\.html$/i,
include,
Expand Down

0 comments on commit df1b293

Please sign in to comment.