Skip to content

Conversation

dmitry-stepanenko
Copy link
Contributor

@dmitry-stepanenko dmitry-stepanenko commented Feb 21, 2022

Related Issue(s)

closes #7751

Description

Adding range selection capabilities to platform checkbox group.

Identified, that there're a lot of redundant component logic both in checkbox and checkbox group, so made the following changes:

fdp-checkbox

  • removed logic for changing selection state. Now everything is handled by internal fd-checkbox
  • deprecated isBinary input as it's completely redundant
  • deprecated value input, that was used to pass trueValue for fd-checkbox. Now it's recommended to use values input, that is the same to what's used inside fd-checkbox
  • removed deprecated stateType input
  • deprecated indeterminateChange output in favour of checkedChange
  • deprecated change output in favour of checkedChange

fdp-checkbox-group

  • deprecated checked input in favour of value: checkbox group cannot be checked by itself
  • BREAKING CHANGE: valueChange now emits actual array of values instead of PlatformCheckboxChange event
  • deprecated checkedChange in favour of valueChange
  • added range selection capabilities

collection-base-input

  • added array value coercion

Screenshots

no bisual changes

Before:

After:

Please check whether the PR fulfills the following requirements

During Implementation
  1. Visual Testing:
  • visual misalignments/updates
  • check Light/Dark/HCB/HCW themes
  • RTL/LTR - proper rendering and labeling
  • responsiveness(resize)
  • Content Density (Cozy/Compact/(Condensed))
  • States - hover/disabled/focused/active/on click/selected/selected hover/press state
  • Interaction/Animation - open/close, expand/collapse, add/remove, check/uncheck
  • Mouse vs. Keyboard support
  • Text Truncation
  1. API and functional correctness
  • check for console logs (warnings, errors)
  • API boundary values
  • [n/a] different combinations of components - free style
  • change the API values during testing
  1. Documentation and Example validations
  • missing API documentation or it is not understandable
  • poor examples
  • [n/a] Stackblitz works for all examples
  1. Accessibility testing
  2. Browser Testing - Edge, Safari, Chrome, Firefox
PR Quality

@netlify
Copy link

netlify bot commented Feb 21, 2022

✔️ Deploy Preview for fundamental-ngx ready!

🔨 Explore the source changes: 30dd23f

🔍 Inspect the deploy log: https://app.netlify.com/sites/fundamental-ngx/deploys/621df97f8030cf0007b460c9

😎 Browse the preview: https://deploy-preview-7785--fundamental-ngx.netlify.app

@github-actions
Copy link

github-actions bot commented Feb 21, 2022

Visit the preview URL for this PR (updated for commit 30dd23f):

https://fundamental-ngx-gh--pr7785-ds-7751-checkbox-gro-rsa21mfb.web.app

(expires Fri, 04 Mar 2022 10:55:09 GMT)

🔥 via Firebase Hosting GitHub Action 🌎

@dmitry-stepanenko dmitry-stepanenko force-pushed the ds/7751-checkbox-group-range-selection branch from 153047b to ed5ecbd Compare February 21, 2022 16:11
@dmitry-stepanenko dmitry-stepanenko requested review from a team February 23, 2022 21:32
Copy link
Contributor

@platon-rov platon-rov left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Overall looks good!

Also, found one broken example in checkbox group docs but it was okay before.

image

@github-actions
Copy link

This pull request is stale because it has been open 2 days with no activity. Remove stale label or comment or this will be closed in 3 days

@github-actions github-actions bot added the stale label Feb 27, 2022
@dmitry-stepanenko dmitry-stepanenko force-pushed the ds/7751-checkbox-group-range-selection branch from ed5ecbd to 30dd23f Compare March 1, 2022 10:46
@dmitry-stepanenko dmitry-stepanenko merged commit 28aa305 into main Mar 3, 2022
@dmitry-stepanenko dmitry-stepanenko deleted the ds/7751-checkbox-group-range-selection branch March 3, 2022 16:33
aberikashvili pushed a commit that referenced this pull request Mar 7, 2022
author Arkadi Berikashvili <[email protected]> 1645522035 +0400
committer Arkadi Berikashvili <[email protected]> 1646661616 +0400

parent 2c6ab2e
author Arkadi Berikashvili <[email protected]> 1645522035 +0400
committer Arkadi Berikashvili <[email protected]> 1646661409 +0400

parent 2c6ab2e
author Arkadi Berikashvili <[email protected]> 1645522035 +0400
committer Arkadi Berikashvili <[email protected]> 1646661161 +0400

parent 2c6ab2e
author Arkadi Berikashvili <[email protected]> 1645522035 +0400
committer Arkadi Berikashvili <[email protected]> 1646661134 +0400

fix(core): fix carousel issue

* fix(core): now time column respects elementsAtOnce config and instead of 7 items now only 5 are shown simultaneously

* feat(core): added elementsAtOnce to carousel-column and time component. fixed type issues in wdio

* feat(core): updating configs after input change

* chore(core): removed redundant properties

chore(release): version 0.33.5-rc.8 build 2940 [ci skip]

fix(core): fix few issues in multi input (#7760)

* fix(core): some issues in multi input of core
Fixes #7759

* refactor(core): remove unused code

* refactor(core): rename and add comment

* fix(core): ctrl+a and delete

in custom example test has been failed.
was fixed and it do what it's expecting.

* fix(core): fix test

to passed test some changes applied as expected the behavior.

chore(release): version 0.33.5-rc.9 build 2942 [ci skip]

docs(core): upload-collection - add range selection to the example (#7761)

chore(release): version 0.33.5-rc.10 build 2943 [ci skip]

chore(deps): bump core-js from 3.7.0 to 3.21.1 (#7782)

Bumps [core-js](https://github.com/zloirock/core-js) from 3.7.0 to 3.21.1.
- [Release notes](https://github.com/zloirock/core-js/releases)
- [Changelog](https://github.com/zloirock/core-js/blob/master/CHANGELOG.md)
- [Commits](zloirock/core-js@v3.7.0...v3.21.1)

---
updated-dependencies:
- dependency-name: core-js
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <[email protected]>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

fix(platform): multi-input - omit extra dataSource triggering (#7788)

chore(release): version 0.33.5-rc.11 build 2951 [ci skip]

feat(platform): table - range selection & bug fixes (#7768)

chore(release): version 0.33.5-rc.12 build 2952 [ci skip]

feat(platform): emit event when smart filters have been updated (#7771)

chore(release): version 0.33.5-rc.13 build 2953 [ci skip]

feat(core): grid-list - range selection using "shift" (#7758)

chore(release): version 0.33.5-rc.14 build 2954 [ci skip]

fix(platform): upload collections enhancements (#7742)

chore(release): version 0.33.5-rc.15 build 2956 [ci skip]

fix(core): schematics angular cdk version issue (#7800)

chore(release): version 0.33.5-rc.16 build 2968 [ci skip]

fix(core): menu item should not receive focus on mouse hover and remove extra box shadow [ci visual] (#7774)

* fix(core): menu item should not receive focus on mouse hover

* fix(core): remove extra box-shadow on menu [ci visual]

chore(release): version 0.33.5-rc.17 build 2979 [ci skip]

chore(deps-dev): bump @angular-eslint/eslint-plugin-template (#7806)

Bumps [@angular-eslint/eslint-plugin-template](https://github.com/angular-eslint/angular-eslint/tree/HEAD/packages/eslint-plugin-template) from 13.0.1 to 13.1.0.
- [Release notes](https://github.com/angular-eslint/angular-eslint/releases)
- [Changelog](https://github.com/angular-eslint/angular-eslint/blob/master/packages/eslint-plugin-template/CHANGELOG.md)
- [Commits](https://github.com/angular-eslint/angular-eslint/commits/v13.1.0/packages/eslint-plugin-template)

---
updated-dependencies:
- dependency-name: "@angular-eslint/eslint-plugin-template"
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <[email protected]>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

chore(release): version 0.33.5-rc.18 build 2980 [ci skip]

fix(core): hide dots when there's nothing to scroll

fix(core): added disable functions for previous/next buttons in the calendar (#7574)

* fix(core): added disable functions for previous/next buttons in the calender

* fix(core): changed to input set and added documentation in core

* fix(core): added optional date parameter

* fix(core): changed the input functions to just booleans for calendar-header, added handling the logic in the calendar, passing date to the disable functions

* fix(core): calendar navigation buttons disable functions fixes

1. fixed docs id and source files
2. added better documentation for using disable functions
3. removed unneeded complex layout in the example file
4. removed example from calendar.po.ts
5. removed ariaDisabled as was not neeeded
6. exported disable functions to a separate type
7. checked validation that input functions are actually functions
7. changed function to be called when bindings are changed, active view is changed or selected date is changed
8. added disable functions as inputs for date picker as well
9. added selected date, currently displayed date and active view to be passed as a context to the function
10. fixed some husky errors with unused variables

* fix(core): calendar navigation buttons fixes

* fix(core): added correct import for navigationbuttondisablefunction type

* fix(core): changed working with currentlyDisplayed prop and made documentation more generic

* fix(core): added hidden and removed unused and empty function

* fix(core): calendar a11y

Co-authored-by: Platon Rov <[email protected]>

chore(release): version 0.33.5-rc.19 build 2988 [ci skip]

Update libs/core/src/lib/carousel/carousel.component.html

Co-authored-by: Dmitriy Stepanenko <[email protected]>

fix(core): remvoe extra method

chore(deps-dev): bump rollup from 2.67.3 to 2.68.0 (#7809)

Bumps [rollup](https://github.com/rollup/rollup) from 2.67.3 to 2.68.0.
- [Release notes](https://github.com/rollup/rollup/releases)
- [Changelog](https://github.com/rollup/rollup/blob/master/CHANGELOG.md)
- [Commits](rollup/rollup@v2.67.3...v2.68.0)

---
updated-dependencies:
- dependency-name: rollup
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <[email protected]>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

chore(release): version 0.33.5-rc.20 build 2993 [ci skip]

chore(deps-dev): bump @types/lodash-es from 4.17.5 to 4.17.6 (#7803)

Bumps [@types/lodash-es](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/lodash-es) from 4.17.5 to 4.17.6.
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/lodash-es)

---
updated-dependencies:
- dependency-name: "@types/lodash-es"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <[email protected]>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

chore(release): version 0.33.5-rc.21 build 2994 [ci skip]

chore(deps-dev): bump @wdio/cli from 7.16.15 to 7.16.16 (#7802)

Bumps [@wdio/cli](https://github.com/webdriverio/webdriverio) from 7.16.15 to 7.16.16.
- [Release notes](https://github.com/webdriverio/webdriverio/releases)
- [Changelog](https://github.com/webdriverio/webdriverio/blob/main/CHANGELOG.md)
- [Commits](webdriverio/webdriverio@v7.16.15...v7.16.16)

---
updated-dependencies:
- dependency-name: "@wdio/cli"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <[email protected]>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

chore(release): version 0.33.5-rc.22 build 2997 [ci skip]

fix(core): layout grid vertical gutter (#7813)

chore(release): version 0.33.5-rc.23 build 3002 [ci skip]

fix(core): @angular/cdk schematics issue (#7820)

chore(release): version 0.33.5-rc.24 build 3013 [ci skip]

fix(core): notification a11y (#7330)

chore(release): version 0.33.5-rc.25 build 3014 [ci skip]

chore(core): fix lint errors in notification (#7823)

chore(release): version 0.33.5-rc.26 build 3023 [ci skip]

feat(core,platform): bring horizon themes (#7819)

chore(release): version 0.33.5-rc.27 build 3026 [ci skip]

chore(deps): migrate to the latest nx and angular 13 versions (#7817)

* chore(ci): migrate to the latest nx and angular 13 versions

* chore(platform): lint fixing

* chore(deps): revert to previous version of @angular/cdk due to a bug

* test(platform): fix icon tab bar dnd test cases

* chore: bump cdk to latest

* chore(core,platform): nx migration file removing

Co-authored-by: dmitry-stepanenko <[email protected]>
Co-authored-by: Platon Rov <[email protected]>

chore(release): version 0.33.5-rc.28 build 3045 [ci skip]

feat(platform): checkbox,checkbox-group - range selection & code enhancements (#7785)

chore(release): version 0.33.5-rc.29 build 3047 [ci skip]

fix(core): @angular/cdk schematics issue (#7820)

chore(core): fix lint errors in notification (#7823)

chore(deps): migrate to the latest nx and angular 13 versions (#7817)

* chore(ci): migrate to the latest nx and angular 13 versions

* chore(platform): lint fixing

* chore(deps): revert to previous version of @angular/cdk due to a bug

* test(platform): fix icon tab bar dnd test cases

* chore: bump cdk to latest

* chore(core,platform): nx migration file removing

Co-authored-by: dmitry-stepanenko <[email protected]>
Co-authored-by: Platon Rov <[email protected]>

feat(platform): checkbox,checkbox-group - range selection & code enhancements (#7785)

chore(release): version 0.33.5-rc.29 build 3047 [ci skip]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat(platform): checkbox-group - allow to select ranges using "shift"

4 participants