Skip to content

Commit

Permalink
feat(ngTableSettings): nested options never undefined
Browse files Browse the repository at this point in the history
This is part of supporting typescript strictNullChecks compiler option

BREAKING CHANGES

`ISettings`: replaced with `Settings` class and a type alias of `SettingsPartial`

`Settings.interceptors`, `Settings.counts`: arrays are cloned therefore any changes to the array will not be recognised

`settings(newSettings)`: any setting value supplied as undefined will now be ignored.

Instead of `undefined` you will need to supply a suitable value as described below:

* `counts` - an empty array to prevent the page size buttons rendering
* `filterOptions.filterDelay` - `0` to remove the debounce delay
* `filterOptions.filterDelayThreshold` - `null` so that a `dataset` of any size will have a `filterDelay` applied
* `groupOptions.sortDirection` - `''` so that grouped columns are NOT sorted by default
* `groupOptions.isExpanded` - `false` so that each grouped set of rows are collapsed by default
* `paginationMaxBlocks`, `paginationMinBlocks` - `0`
  • Loading branch information
ccrowhurstram committed Dec 21, 2016
1 parent 5317463 commit 6e810ba
Show file tree
Hide file tree
Showing 29 changed files with 783 additions and 424 deletions.
11 changes: 6 additions & 5 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,12 @@ e2e/**/*.d.ts
!e2e/protractor*.js
!demo-apps/es5/index.js
!demo-apps/es6-systemjs/index.js
test/**/*.d.ts
test/**/*.js.map
test/**/*.js
!test/index.js
!test/index.d.ts
test/specs/**/*.d.ts
test/specs/**/*.js.map
test/specs/**/*.js
test/util/**/*.d.ts
test/util/**/*.js.map
test/util/**/*.js
bundles
build
build-stats.json
Expand Down
7 changes: 4 additions & 3 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,11 @@
"**/.git": true,
"**/.DS_Store": true,
"**/*.js": {"when": "$(basename).ts"},
"**/*.js.map": true,
"*.d.ts": true,
"src/**/*.d.ts": true,
"src/**/*.js.map": true,
"test/**/*.d.ts": true,
"test/**/*.js.map": true,
"test/specs/**/*.d.ts": true,
"test/util/**/*.d.ts": true,
"bundles/": true,
"demo-apps/**/build/": true,
"demo-site/api-docs/": true,
Expand Down
2 changes: 1 addition & 1 deletion demo-apps/ts-webpack/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
"build": "node ../../node_modules/webpack/bin/webpack.js --env.debug",
"prebuild:prod": "npm run clean",
"build:prod": "node ../../node_modules/webpack/bin/webpack.js --progress --env.prod",
"clean": "node ../../node_modules/shx/lib/cli.js rm -rf build build-stats.json src/**/*.js src/**/*.js.map",
"clean": "node ../../node_modules/shx/lib/cli.js rm -rf build build-stats.json src/**/*.{js,js.map}",
"linklocal": "npm run _linklocal && npm prune",
"serve": "node ../../node_modules/http-server/bin/http-server build -c-1 -o",
"start": "node ../../node_modules/webpack-dev-server/bin/webpack-dev-server.js --progress --env.debug --open",
Expand Down
2 changes: 1 addition & 1 deletion karma.conf.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ module.exports = function (config) {
// list of files / patterns to load in the browser
files: [
// libraries
'node_modules/lodash/index.js',
'node_modules/lodash/lodash.js',
'node_modules/angular/angular.js',
'node_modules/angular-mocks/angular-mocks.js',
testGlob
Expand Down
Loading

0 comments on commit 6e810ba

Please sign in to comment.