angular-slickgrid 9.0.0 → 9.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +1 -1
- package/{dist/fesm2022 → fesm2022}/angular-slickgrid.mjs +16 -16
- package/package.json +27 -14
- package/.gitbook.yaml +0 -5
- package/CHANGELOG.md +0 -1691
- package/CONTRIBUTING.md +0 -17
- package/angular.json +0 -133
- package/coverage/base.css +0 -224
- package/coverage/block-navigation.js +0 -87
- package/coverage/clover.xml +0 -1620
- package/coverage/coverage-final.json +0 -9
- package/coverage/favicon.png +0 -0
- package/coverage/index.html +0 -176
- package/coverage/library/components/angular-slickgrid.component.ts.html +0 -5074
- package/coverage/library/components/index.html +0 -116
- package/coverage/library/constants.ts.html +0 -397
- package/coverage/library/extensions/index.html +0 -116
- package/coverage/library/extensions/slickRowDetailView.ts.html +0 -1261
- package/coverage/library/index.html +0 -116
- package/coverage/library/modules/angular-slickgrid.module.ts.html +0 -166
- package/coverage/library/modules/index.html +0 -116
- package/coverage/library/services/angularUtil.service.ts.html +0 -445
- package/coverage/library/services/container.service.ts.html +0 -163
- package/coverage/library/services/index.html +0 -161
- package/coverage/library/services/translater.service.ts.html +0 -199
- package/coverage/library/services/utilities.ts.html +0 -142
- package/coverage/prettify.css +0 -1
- package/coverage/prettify.js +0 -2
- package/coverage/sort-arrow-sprite.png +0 -0
- package/coverage/sorter.js +0 -196
- package/dist/LICENSE +0 -21
- package/dist/README.md +0 -142
- package/docs/README.md +0 -5
- package/docs/TOC.md +0 -105
- package/docs/backend-services/Custom-Backend-Service.md +0 -50
- package/docs/backend-services/GraphQL.md +0 -276
- package/docs/backend-services/OData.md +0 -245
- package/docs/backend-services/graphql/GraphQL-Filtering.md +0 -156
- package/docs/backend-services/graphql/GraphQL-JSON-Result.md +0 -85
- package/docs/backend-services/graphql/GraphQL-Pagination.md +0 -77
- package/docs/backend-services/graphql/GraphQL-Sorting.md +0 -78
- package/docs/column-functionalities/cell-menu.md +0 -212
- package/docs/column-functionalities/editors/autocomplete-editor.md +0 -466
- package/docs/column-functionalities/editors/date-editor-flatpickr.md +0 -71
- package/docs/column-functionalities/editors/date-editor-vanilla-calendar.md +0 -91
- package/docs/column-functionalities/editors/longtext-editor-textarea.md +0 -80
- package/docs/column-functionalities/editors/select-dropdown-editor.md +0 -227
- package/docs/column-functionalities/editors.md +0 -604
- package/docs/column-functionalities/filters/autocomplete-filter.md +0 -183
- package/docs/column-functionalities/filters/compound-filters.md +0 -234
- package/docs/column-functionalities/filters/custom-filter.md +0 -117
- package/docs/column-functionalities/filters/filter-intro.md +0 -81
- package/docs/column-functionalities/filters/input-filter.md +0 -260
- package/docs/column-functionalities/filters/range-filters.md +0 -188
- package/docs/column-functionalities/filters/select-filter.md +0 -695
- package/docs/column-functionalities/filters/single-search-filter.md +0 -77
- package/docs/column-functionalities/filters/styling-filled-filters.md +0 -45
- package/docs/column-functionalities/formatters.md +0 -325
- package/docs/column-functionalities/sorting.md +0 -200
- package/docs/developer-guides/csp-compliance.md +0 -64
- package/docs/events/Available-Events.md +0 -223
- package/docs/events/Grid-&-DataView-Events.md +0 -211
- package/docs/getting-started/quick-start.md +0 -230
- package/docs/getting-started/troubleshooting.md +0 -80
- package/docs/grid-functionalities/Column-Picker.md +0 -22
- package/docs/grid-functionalities/Composite-Editor-Modal.md +0 -627
- package/docs/grid-functionalities/Context-Menu.md +0 -226
- package/docs/grid-functionalities/Custom-Footer.md +0 -80
- package/docs/grid-functionalities/Custom-Tooltip-(plugin).md +0 -258
- package/docs/grid-functionalities/Export-to-Excel.md +0 -457
- package/docs/grid-functionalities/Export-to-Text-File.md +0 -165
- package/docs/grid-functionalities/FAQ.md +0 -53
- package/docs/grid-functionalities/Global-Options.md +0 -29
- package/docs/grid-functionalities/Grid-Auto-Resize.md +0 -218
- package/docs/grid-functionalities/Grid-Menu.md +0 -134
- package/docs/grid-functionalities/Grid-State-&-Preset.md +0 -245
- package/docs/grid-functionalities/Header-Menu-&-Header-Buttons.md +0 -125
- package/docs/grid-functionalities/Resize-by-Cell-Content.md +0 -138
- package/docs/grid-functionalities/Row-Selection.md +0 -247
- package/docs/grid-functionalities/Row-based-edit.md +0 -71
- package/docs/grid-functionalities/add-update-highlight.md +0 -258
- package/docs/grid-functionalities/column-row-spanning.md +0 -74
- package/docs/grid-functionalities/dynamic-item-metadata.md +0 -124
- package/docs/grid-functionalities/excel-copy-buffer.md +0 -145
- package/docs/grid-functionalities/frozen-columns-rows.md +0 -164
- package/docs/grid-functionalities/grouping-and-aggregators.md +0 -269
- package/docs/grid-functionalities/header-footer-slots.md +0 -22
- package/docs/grid-functionalities/infinite-scroll.md +0 -150
- package/docs/grid-functionalities/providing-grid-data.md +0 -61
- package/docs/grid-functionalities/row-detail.md +0 -530
- package/docs/grid-functionalities/tree-data-grid.md +0 -391
- package/docs/localization/Localization---Component-Sample.md +0 -87
- package/docs/localization/Localization-with-Custom-Locales.md +0 -66
- package/docs/localization/Localization-with-ngx-translate.md +0 -148
- package/docs/migrations/migration-to-2.x.md +0 -304
- package/docs/migrations/migration-to-3.x.md +0 -295
- package/docs/migrations/migration-to-4.x.md +0 -83
- package/docs/migrations/migration-to-5.x.md +0 -160
- package/docs/migrations/migration-to-6.x.md +0 -128
- package/docs/migrations/migration-to-7.x.md +0 -294
- package/docs/migrations/migration-to-8.x.md +0 -316
- package/docs/migrations/migration-to-9.x.md +0 -219
- package/docs/slick-grid-dataview-objects/slickgrid-dataview-objects.md +0 -79
- package/docs/styling/dark-mode.md +0 -100
- package/docs/styling/styling.md +0 -250
- package/docs/testing/testing-patterns.md +0 -73
- package/eslint.config.mjs +0 -60
- package/ng-package.json +0 -10
- package/src/assets/angular-logo.png +0 -0
- package/src/assets/angular-logo2.png +0 -0
- package/src/assets/data/collection_100_numbers.json +0 -12
- package/src/assets/data/collection_500_numbers.json +0 -52
- package/src/assets/data/countries.json +0 -245
- package/src/assets/data/country_names.json +0 -245
- package/src/assets/data/customers_100.json +0 -102
- package/src/assets/data/users.csv +0 -5
- package/src/assets/i18n/en.json +0 -102
- package/src/assets/i18n/fr.json +0 -103
- package/src/demos/app-routing.module.ts +0 -108
- package/src/demos/app.component.html +0 -187
- package/src/demos/app.component.scss +0 -79
- package/src/demos/app.component.ts +0 -11
- package/src/demos/app.module.ts +0 -196
- package/src/demos/environments/environment.dev.ts +0 -3
- package/src/demos/environments/environment.prod.ts +0 -3
- package/src/demos/environments/environment.ts +0 -8
- package/src/demos/examples/custom-angularComponentEditor.ts +0 -187
- package/src/demos/examples/custom-angularComponentFilter.ts +0 -123
- package/src/demos/examples/custom-buttonFormatter.component.ts +0 -13
- package/src/demos/examples/custom-inputEditor.ts +0 -132
- package/src/demos/examples/custom-inputFilter.ts +0 -134
- package/src/demos/examples/custom-titleFormatter.component.ts +0 -9
- package/src/demos/examples/data/collection_100_numbers.json +0 -12
- package/src/demos/examples/data/collection_500_numbers.json +0 -52
- package/src/demos/examples/data/countries.json +0 -245
- package/src/demos/examples/data/country_names.json +0 -245
- package/src/demos/examples/data/customers_100.json +0 -102
- package/src/demos/examples/data/users.csv +0 -5
- package/src/demos/examples/editor-ng-select.component.ts +0 -38
- package/src/demos/examples/example01.component.html +0 -48
- package/src/demos/examples/example01.component.ts +0 -109
- package/src/demos/examples/example02.component.html +0 -45
- package/src/demos/examples/example02.component.ts +0 -218
- package/src/demos/examples/example03.component.html +0 -118
- package/src/demos/examples/example03.component.ts +0 -694
- package/src/demos/examples/example04.component.html +0 -87
- package/src/demos/examples/example04.component.ts +0 -326
- package/src/demos/examples/example05.component.html +0 -151
- package/src/demos/examples/example05.component.ts +0 -474
- package/src/demos/examples/example06.component.html +0 -163
- package/src/demos/examples/example06.component.ts +0 -446
- package/src/demos/examples/example07.component.html +0 -56
- package/src/demos/examples/example07.component.scss +0 -10
- package/src/demos/examples/example07.component.ts +0 -216
- package/src/demos/examples/example08.component.html +0 -51
- package/src/demos/examples/example08.component.scss +0 -23
- package/src/demos/examples/example08.component.ts +0 -195
- package/src/demos/examples/example09.component.html +0 -55
- package/src/demos/examples/example09.component.scss +0 -22
- package/src/demos/examples/example09.component.ts +0 -302
- package/src/demos/examples/example10.component.html +0 -103
- package/src/demos/examples/example10.component.ts +0 -309
- package/src/demos/examples/example11.component.html +0 -91
- package/src/demos/examples/example11.component.ts +0 -276
- package/src/demos/examples/example12.component.html +0 -98
- package/src/demos/examples/example12.component.ts +0 -317
- package/src/demos/examples/example13.component.html +0 -96
- package/src/demos/examples/example13.component.ts +0 -370
- package/src/demos/examples/example14.component.html +0 -50
- package/src/demos/examples/example14.component.scss +0 -11
- package/src/demos/examples/example14.component.ts +0 -156
- package/src/demos/examples/example15.component.html +0 -56
- package/src/demos/examples/example15.component.ts +0 -304
- package/src/demos/examples/example16.component.html +0 -77
- package/src/demos/examples/example16.component.ts +0 -277
- package/src/demos/examples/example17.component.html +0 -50
- package/src/demos/examples/example17.component.ts +0 -109
- package/src/demos/examples/example18.component.html +0 -132
- package/src/demos/examples/example18.component.ts +0 -445
- package/src/demos/examples/example19-rowdetail.component.html +0 -40
- package/src/demos/examples/example19-rowdetail.component.ts +0 -54
- package/src/demos/examples/example19.component.html +0 -79
- package/src/demos/examples/example19.component.ts +0 -316
- package/src/demos/examples/example20.component.html +0 -76
- package/src/demos/examples/example20.component.scss +0 -11
- package/src/demos/examples/example20.component.ts +0 -341
- package/src/demos/examples/example21.component.html +0 -86
- package/src/demos/examples/example21.component.scss +0 -16
- package/src/demos/examples/example21.component.ts +0 -140
- package/src/demos/examples/example22.component.html +0 -41
- package/src/demos/examples/example22.component.ts +0 -117
- package/src/demos/examples/example23.component.html +0 -111
- package/src/demos/examples/example23.component.ts +0 -323
- package/src/demos/examples/example24.component.html +0 -120
- package/src/demos/examples/example24.component.scss +0 -62
- package/src/demos/examples/example24.component.ts +0 -641
- package/src/demos/examples/example25.component.html +0 -60
- package/src/demos/examples/example25.component.scss +0 -8
- package/src/demos/examples/example25.component.ts +0 -255
- package/src/demos/examples/example26.component.html +0 -98
- package/src/demos/examples/example26.component.scss +0 -42
- package/src/demos/examples/example26.component.ts +0 -383
- package/src/demos/examples/example27.component.html +0 -138
- package/src/demos/examples/example27.component.scss +0 -10
- package/src/demos/examples/example27.component.ts +0 -369
- package/src/demos/examples/example28.component.html +0 -143
- package/src/demos/examples/example28.component.scss +0 -54
- package/src/demos/examples/example28.component.ts +0 -453
- package/src/demos/examples/example29.component.html +0 -30
- package/src/demos/examples/example29.component.ts +0 -70
- package/src/demos/examples/example30.component.html +0 -116
- package/src/demos/examples/example30.component.scss +0 -20
- package/src/demos/examples/example30.component.ts +0 -1070
- package/src/demos/examples/example32.component.html +0 -77
- package/src/demos/examples/example32.component.scss +0 -8
- package/src/demos/examples/example32.component.ts +0 -905
- package/src/demos/examples/example33.component.html +0 -50
- package/src/demos/examples/example33.component.scss +0 -46
- package/src/demos/examples/example33.component.ts +0 -571
- package/src/demos/examples/example34.component.html +0 -82
- package/src/demos/examples/example34.component.scss +0 -77
- package/src/demos/examples/example34.component.ts +0 -434
- package/src/demos/examples/example35.component.html +0 -77
- package/src/demos/examples/example35.component.scss +0 -18
- package/src/demos/examples/example35.component.ts +0 -264
- package/src/demos/examples/example36.component.html +0 -56
- package/src/demos/examples/example36.component.scss +0 -26
- package/src/demos/examples/example36.component.ts +0 -504
- package/src/demos/examples/example37.component.html +0 -30
- package/src/demos/examples/example37.component.ts +0 -123
- package/src/demos/examples/example38.component.html +0 -104
- package/src/demos/examples/example38.component.scss +0 -8
- package/src/demos/examples/example38.component.ts +0 -420
- package/src/demos/examples/example39.component.html +0 -112
- package/src/demos/examples/example39.component.scss +0 -8
- package/src/demos/examples/example39.component.ts +0 -371
- package/src/demos/examples/example40.component.html +0 -76
- package/src/demos/examples/example40.component.ts +0 -226
- package/src/demos/examples/example41.component.html +0 -50
- package/src/demos/examples/example41.component.scss +0 -42
- package/src/demos/examples/example41.component.ts +0 -229
- package/src/demos/examples/example42.component.html +0 -47
- package/src/demos/examples/example42.component.ts +0 -203
- package/src/demos/examples/example43.component.html +0 -94
- package/src/demos/examples/example43.component.scss +0 -30
- package/src/demos/examples/example43.component.ts +0 -449
- package/src/demos/examples/example44.component.html +0 -78
- package/src/demos/examples/example44.component.scss +0 -50
- package/src/demos/examples/example44.component.ts +0 -375
- package/src/demos/examples/example45-detail.component.html +0 -15
- package/src/demos/examples/example45-detail.component.ts +0 -97
- package/src/demos/examples/example45.component.html +0 -110
- package/src/demos/examples/example45.component.scss +0 -50
- package/src/demos/examples/example45.component.ts +0 -243
- package/src/demos/examples/filter-ng-select.component.ts +0 -33
- package/src/demos/examples/grid-custom-pager.component.html +0 -60
- package/src/demos/examples/grid-custom-pager.component.scss +0 -57
- package/src/demos/examples/grid-custom-pager.component.ts +0 -107
- package/src/demos/examples/grid-remote.component.html +0 -44
- package/src/demos/examples/grid-remote.component.ts +0 -164
- package/src/demos/examples/home.component.html +0 -39
- package/src/demos/examples/home.component.ts +0 -10
- package/src/demos/examples/jsonp.ts +0 -89
- package/src/demos/examples/rowdetail-preload.component.ts +0 -10
- package/src/demos/examples/swt-common-grid-pagination.component.ts +0 -160
- package/src/demos/examples/swt-common-grid-test.component.html +0 -37
- package/src/demos/examples/swt-common-grid-test.component.ts +0 -214
- package/src/demos/examples/swt-common-grid.component.ts +0 -436
- package/src/demos/examples/swt-logger.service.ts +0 -173
- package/src/demos/examples/utilities.ts +0 -9
- package/src/favicon.ico +0 -0
- package/src/index.html +0 -17
- package/src/library/components/__tests__/angular-slickgrid.component.spec.ts +0 -2638
- package/src/library/components/angular-slickgrid.component.html +0 -5
- package/src/library/components/angular-slickgrid.component.ts +0 -1662
- package/src/library/constants.ts +0 -105
- package/src/library/extensions/__tests__/slickRowDetailView.spec.ts +0 -751
- package/src/library/extensions/index.ts +0 -1
- package/src/library/extensions/slickRowDetailView.ts +0 -395
- package/src/library/global-grid-options.ts +0 -273
- package/src/library/index.ts +0 -11
- package/src/library/models/angularComponentOutput.interface.ts +0 -6
- package/src/library/models/angularGridInstance.interface.ts +0 -76
- package/src/library/models/externalTestingDependencies.interface.ts +0 -37
- package/src/library/models/gridOption.interface.ts +0 -15
- package/src/library/models/index.ts +0 -5
- package/src/library/models/rowDetailView.interface.ts +0 -16
- package/src/library/modules/angular-slickgrid.module.spec.ts +0 -25
- package/src/library/modules/angular-slickgrid.module.ts +0 -27
- package/src/library/services/__tests__/angularUtilService.spec.ts +0 -156
- package/src/library/services/__tests__/container.service.spec.ts +0 -25
- package/src/library/services/__tests__/translater.service.spec.ts +0 -43
- package/src/library/services/__tests__/utilities.spec.ts +0 -22
- package/src/library/services/angularUtil.service.ts +0 -120
- package/src/library/services/container.service.ts +0 -26
- package/src/library/services/index.ts +0 -4
- package/src/library/services/translater.service.ts +0 -38
- package/src/library/services/utilities.ts +0 -19
- package/src/library/slickgrid-config.ts +0 -10
- package/src/main.ts +0 -13
- package/src/public_api.ts +0 -1
- package/src/styles.scss +0 -178
- package/test/cypress/e2e/example01.cy.ts +0 -367
- package/test/cypress/e2e/example02.cy.ts +0 -60
- package/test/cypress/e2e/example03.cy.ts +0 -268
- package/test/cypress/e2e/example04.cy.ts +0 -254
- package/test/cypress/e2e/example05.cy.ts +0 -804
- package/test/cypress/e2e/example06.cy.ts +0 -890
- package/test/cypress/e2e/example07.cy.ts +0 -384
- package/test/cypress/e2e/example08.cy.ts +0 -190
- package/test/cypress/e2e/example09.cy.ts +0 -392
- package/test/cypress/e2e/example10.cy.ts +0 -650
- package/test/cypress/e2e/example11.cy.ts +0 -86
- package/test/cypress/e2e/example12.cy.ts +0 -269
- package/test/cypress/e2e/example13.cy.ts +0 -246
- package/test/cypress/e2e/example14.cy.ts +0 -122
- package/test/cypress/e2e/example15.cy.ts +0 -598
- package/test/cypress/e2e/example16.cy.ts +0 -427
- package/test/cypress/e2e/example17.cy.ts +0 -83
- package/test/cypress/e2e/example18.cy.ts +0 -431
- package/test/cypress/e2e/example19.cy.ts +0 -263
- package/test/cypress/e2e/example20.cy.ts +0 -264
- package/test/cypress/e2e/example21.cy.ts +0 -77
- package/test/cypress/e2e/example22.cy.ts +0 -94
- package/test/cypress/e2e/example23.cy.ts +0 -259
- package/test/cypress/e2e/example24.cy.ts +0 -707
- package/test/cypress/e2e/example25.cy.ts +0 -193
- package/test/cypress/e2e/example26.cy.ts +0 -111
- package/test/cypress/e2e/example27.cy.ts +0 -261
- package/test/cypress/e2e/example28.cy.ts +0 -740
- package/test/cypress/e2e/example29.cy.ts +0 -30
- package/test/cypress/e2e/example30.cy.ts +0 -757
- package/test/cypress/e2e/example31.cy.ts +0 -69
- package/test/cypress/e2e/example32.cy.ts +0 -272
- package/test/cypress/e2e/example33.cy.ts +0 -278
- package/test/cypress/e2e/example34.cy.ts +0 -84
- package/test/cypress/e2e/example35.cy.ts +0 -178
- package/test/cypress/e2e/example36.cy.ts +0 -219
- package/test/cypress/e2e/example37.cy.ts +0 -52
- package/test/cypress/e2e/example38.cy.ts +0 -160
- package/test/cypress/e2e/example39.cy.ts +0 -150
- package/test/cypress/e2e/example40.cy.ts +0 -126
- package/test/cypress/e2e/example41.cy.ts +0 -90
- package/test/cypress/e2e/example42.cy.ts +0 -82
- package/test/cypress/e2e/example43.cy.ts +0 -482
- package/test/cypress/e2e/example44.cy.ts +0 -458
- package/test/cypress/e2e/example45.cy.ts +0 -455
- package/test/cypress/e2e/home.cy.ts +0 -7
- package/test/cypress/fixtures/example.json +0 -5
- package/test/cypress/plugins/index.ts +0 -17
- package/test/cypress/plugins/utilities.ts +0 -28
- package/test/cypress/support/commands.ts +0 -88
- package/test/cypress/support/common.ts +0 -47
- package/test/cypress/support/drag.ts +0 -101
- package/test/cypress/support/index.ts +0 -20
- package/test/cypress/tsconfig.json +0 -9
- package/test/cypress.config.ts +0 -34
- package/test/mockSlickEvent.ts +0 -77
- package/test/rxjsResourceStub.ts +0 -69
- package/test/test-setup.ts +0 -6
- package/test/translateServiceStub.ts +0 -230
- package/test/translaterServiceStub.ts +0 -239
- package/test/tsconfig.json +0 -17
- package/test/vitest-global-mocks.ts +0 -41
- package/test/vitest-global-setup.ts +0 -3
- package/test/vitest-pretest.ts +0 -5
- package/tsconfig.app.json +0 -14
- package/tsconfig.json +0 -31
- package/tsconfig.spec.json +0 -11
- package/types/sortablejs.d.ts +0 -4
- package/vite.config.mts +0 -51
- /package/{dist/fesm2022 → fesm2022}/angular-slickgrid.mjs.map +0 -0
- /package/{dist/i18n → i18n}/en.json +0 -0
- /package/{dist/i18n → i18n}/fr.json +0 -0
- /package/{dist/index.d.ts → index.d.ts} +0 -0
- /package/{dist/library → library}/components/angular-slickgrid.component.d.ts +0 -0
- /package/{dist/library → library}/constants.d.ts +0 -0
- /package/{dist/library → library}/extensions/index.d.ts +0 -0
- /package/{dist/library → library}/extensions/slickRowDetailView.d.ts +0 -0
- /package/{dist/library → library}/global-grid-options.d.ts +0 -0
- /package/{dist/library → library}/index.d.ts +0 -0
- /package/{dist/library → library}/models/angularComponentOutput.interface.d.ts +0 -0
- /package/{dist/library → library}/models/angularGridInstance.interface.d.ts +0 -0
- /package/{dist/library → library}/models/externalTestingDependencies.interface.d.ts +0 -0
- /package/{dist/library → library}/models/gridOption.interface.d.ts +0 -0
- /package/{dist/library → library}/models/index.d.ts +0 -0
- /package/{dist/library → library}/models/rowDetailView.interface.d.ts +0 -0
- /package/{dist/library → library}/modules/angular-slickgrid.module.d.ts +0 -0
- /package/{dist/library → library}/services/angularUtil.service.d.ts +0 -0
- /package/{dist/library → library}/services/container.service.d.ts +0 -0
- /package/{dist/library → library}/services/index.d.ts +0 -0
- /package/{dist/library → library}/services/translater.service.d.ts +0 -0
- /package/{dist/library → library}/services/utilities.d.ts +0 -0
- /package/{dist/library → library}/slickgrid-config.d.ts +0 -0
- /package/{dist/public_api.d.ts → public_api.d.ts} +0 -0
|
@@ -1,707 +0,0 @@
|
|
|
1
|
-
describe('Example 24 - Cell Menu & Context Menu Plugins', () => {
|
|
2
|
-
const GRID_ROW_HEIGHT = 35;
|
|
3
|
-
const fullEnglishTitles = ['#', 'Title', '% Complete', 'Start', 'Finish', 'Priority', 'Completed', 'Action'];
|
|
4
|
-
const fullFrenchTitles = ['#', 'Titre', '% Achevée', 'Début', 'Fin', 'Priorité', 'Terminé', 'Action'];
|
|
5
|
-
|
|
6
|
-
it('should display Example title', () => {
|
|
7
|
-
cy.visit(`${Cypress.config('baseUrl')}/example24`);
|
|
8
|
-
cy.get('h2').should('contain', 'Example 24: Cell Menu & Context Menu Plugins');
|
|
9
|
-
});
|
|
10
|
-
|
|
11
|
-
describe('English Locale', () => {
|
|
12
|
-
it('should have exact Column Titles in the grid', () => {
|
|
13
|
-
cy.get('#grid24')
|
|
14
|
-
.find('.slick-header-columns')
|
|
15
|
-
.children()
|
|
16
|
-
.each(($child, index) => expect($child.text()).to.eq(fullEnglishTitles[index]));
|
|
17
|
-
});
|
|
18
|
-
|
|
19
|
-
it('should have first row with "Task 0" and a Priority set to a Yellow Star (low) with the Action cell disabled and not clickable', () => {
|
|
20
|
-
cy.get('#grid24').find('.slick-row .slick-cell:nth(1)').contains('Task 0');
|
|
21
|
-
|
|
22
|
-
cy.get('#grid24').find('.slick-row .slick-cell:nth(5)').find('.mdi-star.yellow');
|
|
23
|
-
|
|
24
|
-
cy.get('#grid24').find('.slick-row .slick-cell:nth(6)').find('.mdi-check.checkmark-icon');
|
|
25
|
-
|
|
26
|
-
cy.get('#grid24').find('.slick-row .slick-cell:nth(7) .disabled').contains('Action');
|
|
27
|
-
|
|
28
|
-
cy.get('.slick-cell-menu').should('not.exist');
|
|
29
|
-
});
|
|
30
|
-
|
|
31
|
-
it('should expect the Context Menu to not have the "Help" menu when there is Completed set to True', () => {
|
|
32
|
-
const commands = ['Copy', 'Export to Excel', '', 'Delete Row', '', 'Disabled Command', '', 'Exports', 'Feedback'];
|
|
33
|
-
|
|
34
|
-
cy.get('#grid24').find('.slick-row .slick-cell:nth(1)').contains('Task 0');
|
|
35
|
-
|
|
36
|
-
cy.get('#grid24').find('.slick-row .slick-cell:nth(1)').rightclick({ force: true });
|
|
37
|
-
|
|
38
|
-
cy.get('.slick-context-menu.dropright .slick-menu-command-list')
|
|
39
|
-
.find('.slick-menu-item')
|
|
40
|
-
.each(($command, index) => {
|
|
41
|
-
expect($command.text()).to.contain(commands[index]);
|
|
42
|
-
expect($command.text()).not.include('Help');
|
|
43
|
-
});
|
|
44
|
-
});
|
|
45
|
-
|
|
46
|
-
it('should be able to click on the Context Menu (x) close button, on top right corner, to close the menu', () => {
|
|
47
|
-
cy.get('.slick-context-menu.dropright').should('exist');
|
|
48
|
-
|
|
49
|
-
cy.get('.slick-context-menu button.close').click();
|
|
50
|
-
});
|
|
51
|
-
|
|
52
|
-
it('should change "Task 0" Priority to "High" with Context Menu and expect the Action Menu to become clickable and usable', () => {
|
|
53
|
-
cy.get('#grid24').find('.slick-row .slick-cell:nth(1)').contains('Task 0');
|
|
54
|
-
|
|
55
|
-
cy.get('#grid24').find('.slick-row .slick-cell:nth(5)').rightclick({ force: true });
|
|
56
|
-
|
|
57
|
-
cy.get('.slick-context-menu .slick-menu-option-list').contains('High').click();
|
|
58
|
-
|
|
59
|
-
cy.get('.slick-context-menu .slick-menu-command-list').should('not.exist');
|
|
60
|
-
|
|
61
|
-
cy.get('#grid24').find('.slick-row .slick-cell:nth(7)').contains('Action').click({ force: true });
|
|
62
|
-
|
|
63
|
-
cy.get('.slick-cell-menu.dropleft').should('exist');
|
|
64
|
-
});
|
|
65
|
-
|
|
66
|
-
it('should expect a "Command 2" to be disabled and not clickable (menu will remain open), in that same Action menu', () => {
|
|
67
|
-
cy.get('.slick-cell-menu .slick-menu-item.slick-menu-item-disabled').contains('Command 2').click({ force: true });
|
|
68
|
-
|
|
69
|
-
cy.get('.slick-cell-menu.dropleft').should('exist');
|
|
70
|
-
});
|
|
71
|
-
|
|
72
|
-
it('should change the Completed to "False" in that same Action and then expect the "Command 2" to enabled and clickable', () => {
|
|
73
|
-
const alertStub = cy.stub();
|
|
74
|
-
cy.on('window:alert', alertStub);
|
|
75
|
-
|
|
76
|
-
cy.get('.slick-cell-menu .slick-menu-option-list').find('.slick-menu-item').contains('False').click();
|
|
77
|
-
|
|
78
|
-
cy.get('#grid24').find('.slick-row .slick-cell:nth(7)').contains('Action').click({ force: true });
|
|
79
|
-
|
|
80
|
-
cy.get('.slick-cell-menu .slick-menu-item')
|
|
81
|
-
.contains('Command 2')
|
|
82
|
-
.click()
|
|
83
|
-
.then(() => expect(alertStub.getCall(0)).to.be.calledWith('Command 2'));
|
|
84
|
-
});
|
|
85
|
-
|
|
86
|
-
it('should expect the Context Menu now have the "Help" menu when Completed is set to False', () => {
|
|
87
|
-
const commands = ['Copy', 'Export to Excel', '', 'Delete Row', '', 'Help', 'Disabled Command', '', 'Exports', 'Feedback'];
|
|
88
|
-
|
|
89
|
-
cy.get('#grid24').find('.slick-row .slick-cell:nth(1)').contains('Task 0');
|
|
90
|
-
|
|
91
|
-
cy.get('#grid24').find('.slick-row .slick-cell:nth(6)').rightclick({ force: true });
|
|
92
|
-
|
|
93
|
-
cy.get('.slick-context-menu.dropleft .slick-menu-command-list')
|
|
94
|
-
.find('.slick-menu-item')
|
|
95
|
-
.each(($command, index) => expect($command.text()).to.contain(commands[index]));
|
|
96
|
-
|
|
97
|
-
cy.get('.slick-context-menu button.close').click();
|
|
98
|
-
});
|
|
99
|
-
|
|
100
|
-
it('should be able to click on the Action Cell Menu (x) close button, on top right corner, to close the menu', () => {
|
|
101
|
-
cy.get('#grid24').find('.slick-row .slick-cell:nth(7)').contains('Action').click({ force: true });
|
|
102
|
-
|
|
103
|
-
cy.get('.slick-cell-menu.dropleft').should('exist');
|
|
104
|
-
|
|
105
|
-
cy.get('.slick-cell-menu button.close').click();
|
|
106
|
-
|
|
107
|
-
cy.get('.slick-cell-menu.dropleft').should('not.exist');
|
|
108
|
-
});
|
|
109
|
-
|
|
110
|
-
it('should click on the "Show Commands & Priority Options" button and see both list when opening Context Menu', () => {
|
|
111
|
-
cy.get('[data-test=context-menu-commands-and-priority-button]').click();
|
|
112
|
-
|
|
113
|
-
cy.get('#grid24').find('.slick-row .slick-cell:nth(5)').rightclick({ force: true });
|
|
114
|
-
|
|
115
|
-
cy.get('.slick-context-menu .slick-menu-option-list').should('exist').contains('High');
|
|
116
|
-
|
|
117
|
-
cy.get('.slick-context-menu .slick-menu-command-list')
|
|
118
|
-
.find('.slick-menu-item.red')
|
|
119
|
-
.find('.slick-menu-content.bold')
|
|
120
|
-
.should('exist')
|
|
121
|
-
.contains('Delete Row');
|
|
122
|
-
|
|
123
|
-
cy.get('.slick-context-menu button.close').click();
|
|
124
|
-
});
|
|
125
|
-
|
|
126
|
-
it('should click on the "Show Priority Options Only" button and see both list when opening Context Menu', () => {
|
|
127
|
-
cy.get('[data-test=context-menu-priority-only-button]').click();
|
|
128
|
-
|
|
129
|
-
cy.get('#grid24').find('.slick-row .slick-cell:nth(5)').rightclick({ force: true });
|
|
130
|
-
|
|
131
|
-
cy.get('.slick-context-menu .slick-menu-option-list').should('exist').contains('High');
|
|
132
|
-
|
|
133
|
-
cy.get('.slick-context-menu .slick-menu-command-list').should('not.exist');
|
|
134
|
-
|
|
135
|
-
cy.get('.slick-context-menu button.close').click();
|
|
136
|
-
});
|
|
137
|
-
|
|
138
|
-
it('should click on the "Show Actions Commands & Completed Options" button and see both list when opening Action Cell Menu', () => {
|
|
139
|
-
cy.get('[data-test=cell-menu-commands-and-options-true-button]').click();
|
|
140
|
-
|
|
141
|
-
cy.get('#grid24').find('.slick-row .slick-cell:nth(7)').contains('Action').click({ force: true });
|
|
142
|
-
|
|
143
|
-
cy.get('.slick-cell-menu .slick-menu-option-list').should('exist').contains('True');
|
|
144
|
-
|
|
145
|
-
cy.get('.slick-cell-menu .slick-menu-command-list').should('exist').contains('Delete Row');
|
|
146
|
-
|
|
147
|
-
cy.get('.slick-cell-menu button.close').click();
|
|
148
|
-
});
|
|
149
|
-
|
|
150
|
-
it('should open the Action Cell Menu and expect the Completed "null" option when this Effort is set to False', () => {
|
|
151
|
-
cy.get('#grid24').find('.slick-row .slick-cell:nth(7)').contains('Action').click({ force: true });
|
|
152
|
-
|
|
153
|
-
cy.get('.slick-cell-menu.dropleft').should('exist');
|
|
154
|
-
|
|
155
|
-
cy.get('.slick-cell-menu')
|
|
156
|
-
.find('.slick-menu-option-list')
|
|
157
|
-
.find('.slick-menu-item.italic')
|
|
158
|
-
.find('.slick-menu-content')
|
|
159
|
-
.contains('null');
|
|
160
|
-
});
|
|
161
|
-
|
|
162
|
-
it('should open the Action Cell Menu and not expect the Completed "null" option when this Effort is set to True', () => {
|
|
163
|
-
cy.get('.slick-cell-menu.dropleft').should('exist');
|
|
164
|
-
|
|
165
|
-
cy.get('.slick-cell-menu').find('.slick-menu-option-list').contains('True').click();
|
|
166
|
-
|
|
167
|
-
cy.get('#grid24').find('.slick-row .slick-cell:nth(7)').contains('Action').click({ force: true });
|
|
168
|
-
|
|
169
|
-
cy.get('.slick-cell-menu').each(($row) => {
|
|
170
|
-
expect($row.text()).not.include('null');
|
|
171
|
-
});
|
|
172
|
-
});
|
|
173
|
-
|
|
174
|
-
it('should reset Completed to False for the next test to include all commands', () => {
|
|
175
|
-
cy.get('.slick-cell-menu').find('.slick-menu-option-list').contains('False').click();
|
|
176
|
-
});
|
|
177
|
-
|
|
178
|
-
it('should click on the "Show Action Commands Only" button and see both list when opening Context Menu', () => {
|
|
179
|
-
const commands = ['Command 1', 'Command 2', '', 'Delete Row', 'Help', 'Disabled Command', '', 'Exports', 'Feedback'];
|
|
180
|
-
|
|
181
|
-
cy.get('[data-test=cell-menu-commands-and-options-false-button]').click();
|
|
182
|
-
|
|
183
|
-
cy.get('#grid24').find('.slick-row .slick-cell:nth(7)').contains('Action').click({ force: true });
|
|
184
|
-
|
|
185
|
-
cy.get('.slick-cell-menu .slick-menu-command-list')
|
|
186
|
-
.should('exist')
|
|
187
|
-
.find('.slick-menu-item')
|
|
188
|
-
.each(($command, index) => expect($command.text()).to.contain(commands[index]));
|
|
189
|
-
|
|
190
|
-
cy.get('.slick-cell-menu .slick-menu-option-list').should('not.exist');
|
|
191
|
-
|
|
192
|
-
cy.get('.slick-cell-menu button.close').click();
|
|
193
|
-
});
|
|
194
|
-
|
|
195
|
-
it('should be able to delete first row by using the "Delete Row" command from the Context Menu', () => {
|
|
196
|
-
cy.get('#grid24').find('.slick-row .slick-cell:nth(1)').contains('Task 0');
|
|
197
|
-
|
|
198
|
-
cy.get('#grid24').find('.slick-row .slick-cell:nth(1)').rightclick({ force: true });
|
|
199
|
-
|
|
200
|
-
cy.get('.slick-context-menu .slick-menu-command-list')
|
|
201
|
-
.find('.slick-menu-item.red')
|
|
202
|
-
.find('.slick-menu-content.bold')
|
|
203
|
-
.should('exist')
|
|
204
|
-
.contains('Delete Row')
|
|
205
|
-
.click();
|
|
206
|
-
|
|
207
|
-
cy.get('#grid24')
|
|
208
|
-
.find('.slick-row .slick-cell:nth(1)')
|
|
209
|
-
.each(($row) => {
|
|
210
|
-
expect($row.text()).not.include('Task 0');
|
|
211
|
-
});
|
|
212
|
-
});
|
|
213
|
-
|
|
214
|
-
it('should be able to delete the 3rd row "Task 3" by using the "Delete Row" command from the Action Cell Menu', () => {
|
|
215
|
-
cy.get('#grid24').find('.slick-row:nth(2) .slick-cell:nth(1)').contains('Task 3');
|
|
216
|
-
|
|
217
|
-
cy.get('#grid24').find('.slick-row:nth(2) .slick-cell:nth(7)').contains('Action').click({ force: true });
|
|
218
|
-
|
|
219
|
-
cy.get('.slick-cell-menu .slick-menu-command-list')
|
|
220
|
-
.find('.slick-menu-item.red')
|
|
221
|
-
.find('.slick-menu-content.bold')
|
|
222
|
-
.should('exist')
|
|
223
|
-
.contains('Delete Row')
|
|
224
|
-
.click();
|
|
225
|
-
|
|
226
|
-
cy.get('#grid24')
|
|
227
|
-
.find('.slick-row:nth(2) .slick-cell:nth(1)')
|
|
228
|
-
.each(($row) => {
|
|
229
|
-
expect($row.text()).not.include('Task 3');
|
|
230
|
-
});
|
|
231
|
-
});
|
|
232
|
-
|
|
233
|
-
it('should check Context Menu "menuUsabilityOverride" condition and expect to not be able to open Context Menu from rows than are >= to Task 21', () => {
|
|
234
|
-
cy.get('.slick-viewport-top.slick-viewport-left').scrollTo('bottom').wait(50);
|
|
235
|
-
|
|
236
|
-
cy.get('#grid24').find('.slick-row:nth(3) .slick-cell:nth(1)').rightclick({ force: true });
|
|
237
|
-
|
|
238
|
-
cy.get('.slick-context-menu .slick-menu-command-list').should('not.exist');
|
|
239
|
-
});
|
|
240
|
-
|
|
241
|
-
it('should scroll back to top row and be able to open Context Menu', () => {
|
|
242
|
-
cy.get('.slick-viewport-top.slick-viewport-left').scrollTo('top').wait(50);
|
|
243
|
-
|
|
244
|
-
cy.get('#grid24').find('.slick-row:nth(1) .slick-cell:nth(1)').rightclick({ force: true });
|
|
245
|
-
|
|
246
|
-
cy.get('.slick-context-menu .slick-menu-command-list').should('exist');
|
|
247
|
-
|
|
248
|
-
cy.get('.slick-context-menu button.close').click();
|
|
249
|
-
});
|
|
250
|
-
});
|
|
251
|
-
|
|
252
|
-
describe('French Locale', () => {
|
|
253
|
-
it('should switch locale to French', () => {
|
|
254
|
-
cy.get('[data-test=language-button]').click();
|
|
255
|
-
|
|
256
|
-
cy.get('[data-test=selected-locale]').should('contain', 'fr.json');
|
|
257
|
-
});
|
|
258
|
-
|
|
259
|
-
it('should show both Commands & Options on the Action Cell Menu', () => {
|
|
260
|
-
cy.get('[data-test=cell-menu-commands-and-options-true-button]').click();
|
|
261
|
-
});
|
|
262
|
-
|
|
263
|
-
it('should have exact Column Titles in the grid', () => {
|
|
264
|
-
cy.get('#grid24')
|
|
265
|
-
.find('.slick-header-columns')
|
|
266
|
-
.children()
|
|
267
|
-
.each(($child, index) => expect($child.text()).to.contain(fullFrenchTitles[index]));
|
|
268
|
-
});
|
|
269
|
-
|
|
270
|
-
it('should have first row with "Tâche 1" and a Priority set to a Orange Star (medium) with the Action cell disabled and not clickable', () => {
|
|
271
|
-
cy.get('#grid24').find('.slick-row .slick-cell:nth(1)').contains('Tâche 1');
|
|
272
|
-
|
|
273
|
-
cy.get('#grid24').find('.slick-row .slick-cell:nth(5)').find('.mdi-star.orange');
|
|
274
|
-
|
|
275
|
-
cy.get('#grid24').find('.slick-row .slick-cell:nth(7) .disabled').contains('Action');
|
|
276
|
-
|
|
277
|
-
cy.get('.slick-cell-menu').should('not.exist');
|
|
278
|
-
});
|
|
279
|
-
|
|
280
|
-
it('should expect the Context Menu to not have the "Aide" menu when there is Completed set to False', () => {
|
|
281
|
-
const commands = [
|
|
282
|
-
'Copier',
|
|
283
|
-
'Exporter vers Excel',
|
|
284
|
-
'',
|
|
285
|
-
'Supprimer la ligne',
|
|
286
|
-
'',
|
|
287
|
-
'Aide',
|
|
288
|
-
'Commande désactivée',
|
|
289
|
-
'',
|
|
290
|
-
'Exports',
|
|
291
|
-
'Feedback',
|
|
292
|
-
];
|
|
293
|
-
|
|
294
|
-
cy.get('#grid24').find('.slick-row .slick-cell:nth(1)').contains('Tâche 1');
|
|
295
|
-
|
|
296
|
-
cy.get('#grid24').find('.slick-row .slick-cell:nth(1)').rightclick({ force: true });
|
|
297
|
-
|
|
298
|
-
cy.get('.slick-context-menu.dropright .slick-menu-command-list')
|
|
299
|
-
.find('.slick-menu-item')
|
|
300
|
-
.each(($command, index) => expect($command.text()).to.contain(commands[index]));
|
|
301
|
-
});
|
|
302
|
-
|
|
303
|
-
it('should be able to click on the Context Menu (x) close button, on top right corner, to close the menu', () => {
|
|
304
|
-
cy.get('.slick-context-menu.dropright').should('exist');
|
|
305
|
-
|
|
306
|
-
cy.get('.slick-context-menu button.close').click();
|
|
307
|
-
});
|
|
308
|
-
|
|
309
|
-
it('should change "Tâche 1" Priority to "Haut" with Context Menu and expect the Action Menu to become clickable and usable', () => {
|
|
310
|
-
cy.get('#grid24').find('.slick-row .slick-cell:nth(1)').contains('Tâche 1');
|
|
311
|
-
|
|
312
|
-
cy.get('#grid24').find('.slick-row .slick-cell:nth(5)').rightclick({ force: true });
|
|
313
|
-
|
|
314
|
-
cy.get('.slick-context-menu .slick-menu-option-list').contains('Haut').click();
|
|
315
|
-
|
|
316
|
-
cy.get('.slick-context-menu .slick-menu-command-list').should('not.exist');
|
|
317
|
-
|
|
318
|
-
cy.get('#grid24').find('.slick-row .slick-cell:nth(7)').contains('Action').click({ force: true });
|
|
319
|
-
|
|
320
|
-
cy.get('.slick-cell-menu.dropleft').should('exist');
|
|
321
|
-
});
|
|
322
|
-
|
|
323
|
-
it('should expect a "Command 2" to be enabled and clickable in that same Action menu', () => {
|
|
324
|
-
const stub = cy.stub();
|
|
325
|
-
cy.on('window:alert', stub);
|
|
326
|
-
|
|
327
|
-
cy.get('#grid24').find('.slick-row .slick-cell:nth(7)').contains('Action').click({ force: true });
|
|
328
|
-
|
|
329
|
-
cy.get('.slick-cell-menu .slick-menu-item')
|
|
330
|
-
.contains('Command 2')
|
|
331
|
-
.click()
|
|
332
|
-
.then(() => expect(stub.getCall(0)).to.be.calledWith('Command 2'));
|
|
333
|
-
});
|
|
334
|
-
|
|
335
|
-
it('should expect the Context Menu now have the "Aide" menu when Completed is set to False', () => {
|
|
336
|
-
const commands = [
|
|
337
|
-
'Copier',
|
|
338
|
-
'Exporter vers Excel',
|
|
339
|
-
'',
|
|
340
|
-
'Supprimer la ligne',
|
|
341
|
-
'',
|
|
342
|
-
'Aide',
|
|
343
|
-
'Commande désactivée',
|
|
344
|
-
'',
|
|
345
|
-
'Exports',
|
|
346
|
-
'Feedback',
|
|
347
|
-
];
|
|
348
|
-
|
|
349
|
-
cy.get('#grid24').find('.slick-row .slick-cell:nth(1)').contains('Tâche 1');
|
|
350
|
-
|
|
351
|
-
cy.get('#grid24').find('.slick-row .slick-cell:nth(6)').rightclick({ force: true });
|
|
352
|
-
|
|
353
|
-
cy.get('.slick-context-menu.dropleft .slick-menu-command-list')
|
|
354
|
-
.find('.slick-menu-item')
|
|
355
|
-
.each(($command, index) => expect($command.text()).to.contain(commands[index]));
|
|
356
|
-
|
|
357
|
-
cy.get('.slick-context-menu button.close').click();
|
|
358
|
-
});
|
|
359
|
-
|
|
360
|
-
it('should be able to click on the Action Cell Menu (x) close button, on top right corner, to close the menu', () => {
|
|
361
|
-
cy.get('#grid24').find('.slick-row .slick-cell:nth(7)').contains('Action').click({ force: true });
|
|
362
|
-
|
|
363
|
-
cy.get('.slick-cell-menu.dropleft').should('exist');
|
|
364
|
-
|
|
365
|
-
cy.get('.slick-cell-menu button.close').click();
|
|
366
|
-
|
|
367
|
-
cy.get('.slick-cell-menu.dropleft').should('not.exist');
|
|
368
|
-
});
|
|
369
|
-
|
|
370
|
-
it('should click on the "Show Commands & Priority Options" button and see both list when opening Context Menu', () => {
|
|
371
|
-
cy.get('[data-test=context-menu-commands-and-priority-button]').click();
|
|
372
|
-
|
|
373
|
-
cy.get('#grid24').find('.slick-row .slick-cell:nth(5)').rightclick({ force: true });
|
|
374
|
-
|
|
375
|
-
cy.get('.slick-context-menu .slick-menu-option-list').should('exist').contains('Haut');
|
|
376
|
-
|
|
377
|
-
cy.get('.slick-context-menu .slick-menu-command-list')
|
|
378
|
-
.find('.slick-menu-item.red')
|
|
379
|
-
.find('.slick-menu-content.bold')
|
|
380
|
-
.should('exist')
|
|
381
|
-
.contains('Supprimer la ligne');
|
|
382
|
-
|
|
383
|
-
cy.get('.slick-context-menu button.close').click();
|
|
384
|
-
});
|
|
385
|
-
|
|
386
|
-
it('should click on the "Show Priority Options Only" button and see both list when opening Context Menu', () => {
|
|
387
|
-
cy.get('[data-test=context-menu-priority-only-button]').click();
|
|
388
|
-
|
|
389
|
-
cy.get('#grid24').find('.slick-row .slick-cell:nth(5)').rightclick({ force: true });
|
|
390
|
-
|
|
391
|
-
cy.get('.slick-context-menu .slick-menu-option-list').should('exist').contains('Haut');
|
|
392
|
-
|
|
393
|
-
cy.get('.slick-context-menu .slick-menu-command-list').should('not.exist');
|
|
394
|
-
|
|
395
|
-
cy.get('.slick-context-menu button.close').click();
|
|
396
|
-
});
|
|
397
|
-
|
|
398
|
-
it('should click on the "Show Actions Commands & Completed Options" button and see both list when opening Action Cell Menu', () => {
|
|
399
|
-
cy.get('[data-test=cell-menu-commands-and-options-true-button]').click();
|
|
400
|
-
|
|
401
|
-
cy.get('#grid24').find('.slick-row .slick-cell:nth(7)').contains('Action').click({ force: true });
|
|
402
|
-
|
|
403
|
-
cy.get('.slick-cell-menu .slick-menu-option-list').should('exist').contains('Vrai');
|
|
404
|
-
|
|
405
|
-
cy.get('.slick-cell-menu .slick-menu-command-list').should('exist').contains('Supprimer la ligne');
|
|
406
|
-
|
|
407
|
-
cy.get('.slick-cell-menu button.close').click();
|
|
408
|
-
});
|
|
409
|
-
|
|
410
|
-
it('should open the Action Cell Menu and expect the Completed "null" option when this Effort is set to Faux', () => {
|
|
411
|
-
cy.get('#grid24').find('.slick-row .slick-cell:nth(7)').contains('Action').click({ force: true });
|
|
412
|
-
|
|
413
|
-
cy.get('.slick-cell-menu.dropleft').should('exist');
|
|
414
|
-
|
|
415
|
-
cy.get('.slick-cell-menu')
|
|
416
|
-
.find('.slick-menu-option-list')
|
|
417
|
-
.find('.slick-menu-item.italic')
|
|
418
|
-
.find('.slick-menu-content')
|
|
419
|
-
.contains('null');
|
|
420
|
-
});
|
|
421
|
-
|
|
422
|
-
it('should open the Action Cell Menu and not expect the Completed "null" option when this Effort is set to True', () => {
|
|
423
|
-
cy.get('.slick-cell-menu.dropleft').should('exist');
|
|
424
|
-
|
|
425
|
-
cy.get('.slick-cell-menu').find('.slick-menu-option-list').contains('Vrai').click();
|
|
426
|
-
|
|
427
|
-
cy.get('#grid24').find('.slick-row .slick-cell:nth(7)').contains('Action').click({ force: true });
|
|
428
|
-
|
|
429
|
-
cy.get('.slick-cell-menu').each(($row) => {
|
|
430
|
-
expect($row.text()).not.include('null');
|
|
431
|
-
});
|
|
432
|
-
});
|
|
433
|
-
|
|
434
|
-
it('should reset Completed to Faux for the next test to include all commands', () => {
|
|
435
|
-
cy.get('.slick-cell-menu').find('.slick-menu-option-list').contains('Faux').click();
|
|
436
|
-
});
|
|
437
|
-
|
|
438
|
-
it('should click on the "Show Action Commands Only" button and see both list when opening Context Menu', () => {
|
|
439
|
-
const commands = ['Command 1', 'Command 2', '', 'Supprimer la ligne', 'Aide', 'Commande désactivée', '', 'Exports', 'Feedback'];
|
|
440
|
-
|
|
441
|
-
cy.get('[data-test=cell-menu-commands-and-options-false-button]').click();
|
|
442
|
-
|
|
443
|
-
cy.get('#grid24').find('.slick-row .slick-cell:nth(7)').contains('Action').click({ force: true });
|
|
444
|
-
|
|
445
|
-
cy.get('.slick-cell-menu .slick-menu-command-list')
|
|
446
|
-
.should('exist')
|
|
447
|
-
.find('.slick-menu-item')
|
|
448
|
-
.each(($command, index) => expect($command.text()).to.contain(commands[index]));
|
|
449
|
-
|
|
450
|
-
cy.get('.slick-cell-menu .slick-menu-option-list').should('not.exist');
|
|
451
|
-
|
|
452
|
-
cy.get('.slick-cell-menu button.close').click();
|
|
453
|
-
});
|
|
454
|
-
|
|
455
|
-
it('should be able to delete first row by using the "Supprimer la ligne" command from the Context Menu', () => {
|
|
456
|
-
cy.get('#grid24').find('.slick-row .slick-cell:nth(1)').contains('Tâche 1');
|
|
457
|
-
|
|
458
|
-
cy.get('#grid24').find('.slick-row .slick-cell:nth(1)').rightclick({ force: true });
|
|
459
|
-
|
|
460
|
-
cy.get('.slick-context-menu .slick-menu-command-list')
|
|
461
|
-
.find('.slick-menu-item.red')
|
|
462
|
-
.find('.slick-menu-content.bold')
|
|
463
|
-
.should('exist')
|
|
464
|
-
.contains('Supprimer la ligne')
|
|
465
|
-
.click();
|
|
466
|
-
|
|
467
|
-
cy.get('#grid24')
|
|
468
|
-
.find('.slick-row .slick-cell:nth(1)')
|
|
469
|
-
.each(($row) => {
|
|
470
|
-
expect($row.text()).not.include('Tâche 1');
|
|
471
|
-
});
|
|
472
|
-
});
|
|
473
|
-
|
|
474
|
-
it('should be able to delete the 4th row "Tâche 6" by using the "Supprimer la ligne" command from the Action Cell Menu', () => {
|
|
475
|
-
cy.get('#grid24').find('.slick-row:nth(3) .slick-cell:nth(1)').contains('Tâche 6');
|
|
476
|
-
|
|
477
|
-
cy.get('#grid24').find('.slick-row:nth(3) .slick-cell:nth(7)').contains('Action').click({ force: true });
|
|
478
|
-
|
|
479
|
-
cy.get('.slick-cell-menu .slick-menu-command-list')
|
|
480
|
-
.find('.slick-menu-item.red')
|
|
481
|
-
.find('.slick-menu-content.bold')
|
|
482
|
-
.should('exist')
|
|
483
|
-
.contains('Supprimer la ligne')
|
|
484
|
-
.click();
|
|
485
|
-
|
|
486
|
-
cy.get('#grid24')
|
|
487
|
-
.find('.slick-row:nth(3) .slick-cell:nth(1)')
|
|
488
|
-
.each(($row) => {
|
|
489
|
-
expect($row.text()).not.include('Tâche 6');
|
|
490
|
-
});
|
|
491
|
-
});
|
|
492
|
-
});
|
|
493
|
-
|
|
494
|
-
describe('with sub-menus', () => {
|
|
495
|
-
it('should switch back locale to English', () => {
|
|
496
|
-
cy.get('#grid24').find('button.slick-grid-menu-button').trigger('click').click();
|
|
497
|
-
|
|
498
|
-
cy.get('[data-test=language-button]').click();
|
|
499
|
-
|
|
500
|
-
cy.get('[data-test=selected-locale]').should('contain', 'en.json');
|
|
501
|
-
});
|
|
502
|
-
|
|
503
|
-
it('should reopen Context Menu hover "Priority" column then open options sub-menu & select "High" option and expect Task to be set to High in the UI', () => {
|
|
504
|
-
const subOptions = ['Low', 'Medium', 'High'];
|
|
505
|
-
|
|
506
|
-
cy.get(`[style="transform: translateY(${GRID_ROW_HEIGHT * 0}px);"] .slick-cell:nth(5)`).rightclick({ force: true });
|
|
507
|
-
|
|
508
|
-
cy.get('.slick-context-menu.slick-menu-level-0 .slick-menu-option-list')
|
|
509
|
-
.find('.slick-menu-item .slick-menu-content')
|
|
510
|
-
.contains('Sub-Options (demo)')
|
|
511
|
-
.click();
|
|
512
|
-
|
|
513
|
-
cy.get('.slick-context-menu.slick-menu-level-1 .slick-menu-option-list').as('subMenuList');
|
|
514
|
-
cy.get('@subMenuList').find('.slick-menu-title').contains('Change Priority');
|
|
515
|
-
cy.get('@subMenuList')
|
|
516
|
-
.should('exist')
|
|
517
|
-
.find('.slick-menu-item .slick-menu-content')
|
|
518
|
-
.each(($command, index) => expect($command.text()).to.eq(subOptions[index]));
|
|
519
|
-
|
|
520
|
-
cy.get('@subMenuList').find('.slick-menu-item .slick-menu-content').contains('High').click();
|
|
521
|
-
|
|
522
|
-
cy.get(`[style="transform: translateY(${GRID_ROW_HEIGHT * 0}px);"] .slick-cell:nth(5)`).find('.mdi-star.red');
|
|
523
|
-
});
|
|
524
|
-
|
|
525
|
-
it('should be able to open Context Menu from any other cell and click on Export->Text and expect alert triggered with Text Export', () => {
|
|
526
|
-
const subCommands1 = ['Text', 'Excel'];
|
|
527
|
-
const stub = cy.stub();
|
|
528
|
-
cy.on('window:alert', stub);
|
|
529
|
-
|
|
530
|
-
cy.get(`[style="transform: translateY(${GRID_ROW_HEIGHT * 0}px);"] .slick-cell:nth(1)`).should('contain', 'Task 2');
|
|
531
|
-
cy.get(`[style="transform: translateY(${GRID_ROW_HEIGHT * 0}px);"] .slick-cell:nth(1)`).rightclick({ force: true });
|
|
532
|
-
|
|
533
|
-
cy.get('.slick-context-menu.slick-menu-level-0 .slick-menu-command-list')
|
|
534
|
-
.find('.slick-menu-item .slick-menu-content')
|
|
535
|
-
.contains(/^Exports$/)
|
|
536
|
-
.click();
|
|
537
|
-
|
|
538
|
-
cy.get('.slick-context-menu.slick-menu-level-1 .slick-menu-command-list')
|
|
539
|
-
.should('exist')
|
|
540
|
-
.find('.slick-menu-item')
|
|
541
|
-
.each(($command, index) => expect($command.text()).to.contain(subCommands1[index]));
|
|
542
|
-
|
|
543
|
-
cy.get('.slick-context-menu.slick-menu-level-1 .slick-menu-command-list')
|
|
544
|
-
.find('.slick-menu-item')
|
|
545
|
-
.contains('Text')
|
|
546
|
-
.click()
|
|
547
|
-
.then(() => expect(stub.getCall(0)).to.be.calledWith('Exporting as Text (tab delimited)'));
|
|
548
|
-
});
|
|
549
|
-
|
|
550
|
-
it('should be able to open Context Menu and click on Export->Excel-> sub-commands to see 1 context menu + 1 sub-menu then clicking on Text should call alert action', () => {
|
|
551
|
-
const subCommands1 = ['Text', 'Excel'];
|
|
552
|
-
const subCommands2 = ['Excel (csv)', 'Excel (xlsx)'];
|
|
553
|
-
const stub = cy.stub();
|
|
554
|
-
cy.on('window:alert', stub);
|
|
555
|
-
|
|
556
|
-
cy.get(`[style="transform: translateY(${GRID_ROW_HEIGHT * 0}px);"] .slick-cell:nth(1)`).should('contain', 'Task 2');
|
|
557
|
-
cy.get(`[style="transform: translateY(${GRID_ROW_HEIGHT * 0}px);"] .slick-cell:nth(1)`).rightclick({ force: true });
|
|
558
|
-
|
|
559
|
-
cy.get('.slick-context-menu.slick-menu-level-0 .slick-menu-command-list')
|
|
560
|
-
.find('.slick-menu-item .slick-menu-content')
|
|
561
|
-
.contains(/^Exports$/)
|
|
562
|
-
.click();
|
|
563
|
-
|
|
564
|
-
cy.get('.slick-context-menu.slick-menu-level-1 .slick-menu-command-list')
|
|
565
|
-
.should('exist')
|
|
566
|
-
.find('.slick-menu-item .slick-menu-content')
|
|
567
|
-
.each(($command, index) => expect($command.text()).to.contain(subCommands1[index]));
|
|
568
|
-
|
|
569
|
-
cy.get('.slick-context-menu.slick-menu-level-1 .slick-menu-command-list')
|
|
570
|
-
.find('.slick-menu-item .slick-menu-content')
|
|
571
|
-
.contains('Excel')
|
|
572
|
-
.click();
|
|
573
|
-
|
|
574
|
-
cy.get('.slick-context-menu.slick-menu-level-2 .slick-menu-command-list').as('subMenuList2');
|
|
575
|
-
|
|
576
|
-
cy.get('@subMenuList2').find('.slick-menu-title').contains('available formats');
|
|
577
|
-
|
|
578
|
-
cy.get('@subMenuList2')
|
|
579
|
-
.should('exist')
|
|
580
|
-
.find('.slick-menu-item .slick-menu-content')
|
|
581
|
-
.each(($command, index) => expect($command.text()).to.contain(subCommands2[index]));
|
|
582
|
-
|
|
583
|
-
cy.get('.slick-context-menu.slick-menu-level-2 .slick-menu-command-list')
|
|
584
|
-
.find('.slick-menu-item .slick-menu-content')
|
|
585
|
-
.contains('Excel (xlsx)')
|
|
586
|
-
.click()
|
|
587
|
-
.then(() => expect(stub.getCall(0)).to.be.calledWith('Exporting as Excel (xlsx)'));
|
|
588
|
-
});
|
|
589
|
-
|
|
590
|
-
it('should click on the "Show Commands & Priority Options" button and see both list when opening Context Menu', () => {
|
|
591
|
-
cy.get('[data-test=context-menu-commands-and-priority-button]').click();
|
|
592
|
-
|
|
593
|
-
cy.get('#grid24').find('.slick-row .slick-cell:nth(5)').rightclick({ force: true });
|
|
594
|
-
|
|
595
|
-
cy.get('.slick-context-menu .slick-menu-option-list').should('exist').contains('High');
|
|
596
|
-
|
|
597
|
-
cy.get('.slick-context-menu .slick-menu-command-list')
|
|
598
|
-
.find('.slick-menu-item.red')
|
|
599
|
-
.find('.slick-menu-content.bold')
|
|
600
|
-
.should('exist')
|
|
601
|
-
.contains('Delete Row');
|
|
602
|
-
|
|
603
|
-
cy.get('.slick-context-menu button.close').click();
|
|
604
|
-
});
|
|
605
|
-
|
|
606
|
-
it('should open Export->Excel sub-menu & open again Sub-Options on top and expect sub-menu to be recreated with that Sub-Options list instead of the Export->Excel list', () => {
|
|
607
|
-
const subCommands1 = ['Text', 'Excel'];
|
|
608
|
-
const subCommands2 = ['Excel (csv)', 'Excel (xlsx)'];
|
|
609
|
-
const subOptions = ['Low', 'Medium', 'High'];
|
|
610
|
-
|
|
611
|
-
cy.get(`[style="transform: translateY(${GRID_ROW_HEIGHT * 0}px);"] > .slick-cell:nth(5)`);
|
|
612
|
-
cy.get(`[style="transform: translateY(${GRID_ROW_HEIGHT * 0}px);"] > .slick-cell:nth(5)`).rightclick({ force: true });
|
|
613
|
-
|
|
614
|
-
cy.get('.slick-context-menu.slick-menu-level-0 .slick-menu-command-list')
|
|
615
|
-
.find('.slick-menu-item .slick-menu-content')
|
|
616
|
-
.contains(/^Exports$/)
|
|
617
|
-
.click();
|
|
618
|
-
|
|
619
|
-
cy.get('.slick-context-menu.slick-menu-level-1 .slick-menu-command-list')
|
|
620
|
-
.should('exist')
|
|
621
|
-
.find('.slick-menu-item .slick-menu-content')
|
|
622
|
-
.each(($command, index) => expect($command.text()).to.contain(subCommands1[index]));
|
|
623
|
-
|
|
624
|
-
cy.get('.slick-context-menu.slick-menu-level-1 .slick-menu-command-list')
|
|
625
|
-
.find('.slick-menu-item .slick-menu-content')
|
|
626
|
-
.contains('Excel')
|
|
627
|
-
.click();
|
|
628
|
-
|
|
629
|
-
cy.get('.slick-context-menu.slick-menu-level-2 .slick-menu-command-list')
|
|
630
|
-
.should('exist')
|
|
631
|
-
.find('.slick-menu-item .slick-menu-content')
|
|
632
|
-
.each(($command, index) => expect($command.text()).to.contain(subCommands2[index]));
|
|
633
|
-
|
|
634
|
-
cy.get('.slick-context-menu.slick-menu-level-0 .slick-menu-option-list')
|
|
635
|
-
.find('.slick-menu-item .slick-menu-content')
|
|
636
|
-
.contains('Sub-Options')
|
|
637
|
-
.click();
|
|
638
|
-
|
|
639
|
-
cy.get('.slick-context-menu.slick-menu-level-1 .slick-menu-option-list').as('optionSubList2');
|
|
640
|
-
|
|
641
|
-
cy.get('@optionSubList2').find('.slick-menu-title').contains('Change Priority');
|
|
642
|
-
|
|
643
|
-
cy.get('@optionSubList2')
|
|
644
|
-
.should('exist')
|
|
645
|
-
.find('.slick-menu-item .slick-menu-content')
|
|
646
|
-
.each(($option, index) => expect($option.text()).to.contain(subOptions[index]));
|
|
647
|
-
});
|
|
648
|
-
|
|
649
|
-
it('should open Export->Excel context sub-menu then open Feedback->ContactUs sub-menus and expect previous Export menu to no longer exists', () => {
|
|
650
|
-
const subCommands1 = ['Text', 'Excel'];
|
|
651
|
-
const subCommands2 = ['Request update from supplier', '', 'Contact Us'];
|
|
652
|
-
const subCommands2_1 = ['Email us', 'Chat with us', 'Book an appointment'];
|
|
653
|
-
|
|
654
|
-
const stub = cy.stub();
|
|
655
|
-
cy.on('window:alert', stub);
|
|
656
|
-
|
|
657
|
-
cy.get(`[style="transform: translateY(${GRID_ROW_HEIGHT * 0}px);"] > .slick-cell:nth(5)`);
|
|
658
|
-
cy.get(`[style="transform: translateY(${GRID_ROW_HEIGHT * 0}px);"] > .slick-cell:nth(5)`).rightclick({ force: true });
|
|
659
|
-
|
|
660
|
-
cy.get('.slick-context-menu.slick-menu-level-0 .slick-menu-command-list')
|
|
661
|
-
.find('.slick-menu-item .slick-menu-content')
|
|
662
|
-
.contains(/^Exports$/)
|
|
663
|
-
.click();
|
|
664
|
-
|
|
665
|
-
cy.get('.slick-context-menu.slick-menu-level-1 .slick-menu-command-list')
|
|
666
|
-
.should('exist')
|
|
667
|
-
.find('.slick-menu-item .slick-menu-content')
|
|
668
|
-
.each(($command, index) => expect($command.text()).to.contain(subCommands1[index]));
|
|
669
|
-
|
|
670
|
-
// click different sub-menu
|
|
671
|
-
cy.get('.slick-context-menu.slick-menu-level-0 .slick-menu-command-list')
|
|
672
|
-
.find('.slick-menu-item .slick-menu-content')
|
|
673
|
-
.contains('Feedback')
|
|
674
|
-
.should('exist')
|
|
675
|
-
.click();
|
|
676
|
-
|
|
677
|
-
cy.get('.slick-submenu').should('have.length', 1);
|
|
678
|
-
cy.get('.slick-context-menu.slick-menu-level-1 .slick-menu-command-list')
|
|
679
|
-
.should('exist')
|
|
680
|
-
.find('.slick-menu-item .slick-menu-content')
|
|
681
|
-
.each(($command, index) => expect($command.text()).to.contain(subCommands2[index]));
|
|
682
|
-
|
|
683
|
-
// click on Feedback->ContactUs
|
|
684
|
-
cy.get('.slick-context-menu.slick-menu-level-1.dropleft') // left align
|
|
685
|
-
.find('.slick-menu-item .slick-menu-content')
|
|
686
|
-
.contains('Contact Us')
|
|
687
|
-
.should('exist')
|
|
688
|
-
.trigger('mouseover'); // mouseover or click should work
|
|
689
|
-
|
|
690
|
-
cy.get('.slick-submenu').should('have.length', 2);
|
|
691
|
-
cy.get('.slick-context-menu.slick-menu-level-2.dropright') // right align
|
|
692
|
-
.should('exist')
|
|
693
|
-
.find('.slick-menu-item .slick-menu-content')
|
|
694
|
-
.each(($command, index) => expect($command.text()).to.eq(subCommands2_1[index]));
|
|
695
|
-
|
|
696
|
-
cy.get('.slick-context-menu.slick-menu-level-2');
|
|
697
|
-
|
|
698
|
-
cy.get('.slick-context-menu.slick-menu-level-2 .slick-menu-command-list')
|
|
699
|
-
.find('.slick-menu-item .slick-menu-content')
|
|
700
|
-
.contains('Chat with us')
|
|
701
|
-
.click()
|
|
702
|
-
.then(() => expect(stub.getCall(0)).to.be.calledWith('Command: contact-chat'));
|
|
703
|
-
|
|
704
|
-
cy.get('.slick-submenu').should('have.length', 0);
|
|
705
|
-
});
|
|
706
|
-
});
|
|
707
|
-
});
|