Skip to content

Commit

Permalink
Rebase v6 branch (#9832)
Browse files Browse the repository at this point in the history
* fix(RTL): added right-to-left page demo (#9694)

* chore(release): releasing packages [ci skip]

 - @patternfly/react-code-editor@5.2.0-prerelease.20
 - @patternfly/react-core@5.2.0-prerelease.20
 - @patternfly/react-docs@6.2.0-prerelease.20
 - demo-app-ts@5.1.1-prerelease.43
 - @patternfly/react-table@5.2.0-prerelease.20

* fix(Wizard): onStepChange - skip isDisabled & isHidden (#9748)

* fix(Text input): Added aria-expanded (#9705)

* fix(Text input): Added aria-expanded

* add interface

* updates from review

* fix(Notification Drawer): Added screen reader text for notification drawer item read state (#9569)

* fix(Notification Drawer): Added screen reader text for notification drawer item read state

* fix snapshot

* Update prop description

* add aria-live

* update snapshots

* feat(Wizard): ability to add props to WizardFooter buttons (#9709)

* feat: ability to add props to WizardFooter buttons

* fix(WizardFooter): null check

* fix(Wizard): simpler design of adding footer buttons props

* test(Wizard): can add props to footer buttons

* docs(WizardFooter): move comment so docs have correct description

* refactor(WizardFooter): move FooterButtonProps to types file

* chore(Divider): update tests to new standards (#9714)

* chore(Divider): update tests to new standards

* changes from PR review

* chore(release): releasing packages [ci skip]

 - @patternfly/react-code-editor@5.2.0-prerelease.21
 - @patternfly/react-core@5.2.0-prerelease.21
 - @patternfly/react-docs@6.2.0-prerelease.21
 - demo-app-ts@5.1.1-prerelease.44
 - @patternfly/react-table@5.2.0-prerelease.21

* fix(TreeView): define button type (#9770)

* bug(build): fixed built ESM files importing CJS files from react-styles (#9347)

* bug(build): fixed built ESM files importing CJS files from react-styles

* edited yarn.lock to invalidate deps cache in GH actions

* excluded file extensions from react-styles path transform in ESM build

* updated jest config to transform .mjs files

* updated pr action to invalidate deps cache if package files added/edited

* chore(deps): Add ts-node to support executing typescript files directly

* chore(release): releasing packages [ci skip]

 - @patternfly/react-code-editor@5.2.0-prerelease.22
 - @patternfly/react-core@5.2.0-prerelease.22
 - @patternfly/react-docs@6.2.0-prerelease.22
 - demo-app-ts@5.1.1-prerelease.45
 - @patternfly/react-table@5.2.0-prerelease.22
 - transformer-react-styles-esm-imports@1.0.1-prerelease.0

* chore(deps): update dependency @patternfly/patternfly to v5.2.0-prerelease.4 (#9780)

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

* chore(release): releasing packages [ci skip]

 - @patternfly/react-charts@7.2.0-prerelease.6
 - @patternfly/react-code-editor@5.2.0-prerelease.23
 - @patternfly/react-core@5.2.0-prerelease.23
 - @patternfly/react-docs@6.2.0-prerelease.23
 - @patternfly/react-icons@5.2.0-prerelease.6
 - demo-app-ts@5.1.1-prerelease.46
 - @patternfly/react-styles@5.2.0-prerelease.4
 - @patternfly/react-table@5.2.0-prerelease.23
 - @patternfly/react-tokens@5.2.0-prerelease.5

* feat(Datalist): implement full page Basic demo to match HTML #9048 (#9087)

* feat(Datalist): implement full page Basic demo to match HTML #9048

* fix syntax error

* comments applied

* comments applied

* comments applied

* comments applied

* \xa0 comments applied

* move key per review comments

* address PR comments

* revert change to package.json

* Converted basic demo to TS

---------

Co-authored-by: nicolethoen <nthoen@redhat.com>
Co-authored-by: Eric Olkowski <thatblindgeye@gmail.com>

* fix(ClipboardCopy): kepp caret position (#9772)

* chore(release): releasing packages [ci skip]

 - @patternfly/react-code-editor@5.2.0-prerelease.24
 - @patternfly/react-core@5.2.0-prerelease.24
 - @patternfly/react-docs@6.2.0-prerelease.24
 - demo-app-ts@5.1.1-prerelease.47
 - @patternfly/react-table@5.2.0-prerelease.24

* chore(deps): update devdependencies (#9757)

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

* chore(deps): update dependency @patternfly/patternfly to v5.2.0-prerelease.5 (#9806)

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

* chore(deps): update devdependencies (#9800)

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

* chore(release): releasing packages [ci skip]

 - @patternfly/react-charts@7.2.0-prerelease.7
 - @patternfly/react-code-editor@5.2.0-prerelease.25
 - @patternfly/react-core@5.2.0-prerelease.25
 - @patternfly/react-docs@6.2.0-prerelease.25
 - @patternfly/react-icons@5.2.0-prerelease.7
 - demo-app-ts@5.1.1-prerelease.48
 - @patternfly/react-styles@5.2.0-prerelease.5
 - @patternfly/react-table@5.2.0-prerelease.25
 - @patternfly/react-tokens@5.2.0-prerelease.6

* fix(DatePicker): updated logic for parsing and focus management (#9794)

* chore(release): releasing packages [ci skip]

 - @patternfly/react-code-editor@5.2.0-prerelease.26
 - @patternfly/react-core@5.2.0-prerelease.26
 - @patternfly/react-docs@6.2.0-prerelease.26
 - demo-app-ts@5.1.1-prerelease.49
 - @patternfly/react-table@5.2.0-prerelease.26

* chore(PrimaryDetail): convert demos to TS (#9787)

* chore(release): releasing packages [ci skip]

 - @patternfly/react-code-editor@5.2.0-prerelease.27
 - @patternfly/react-core@5.2.0-prerelease.27
 - @patternfly/react-docs@6.2.0-prerelease.27
 - demo-app-ts@5.1.1-prerelease.50
 - @patternfly/react-table@5.2.0-prerelease.27

* chore(misc): clean up instances of Array.apply (#9798)

* clean up instances of Array.apply

* rename item to value

* chore(release): releasing packages [ci skip]

 - @patternfly/react-code-editor@5.2.0-prerelease.28
 - @patternfly/react-core@5.2.0-prerelease.28
 - @patternfly/react-docs@6.2.0-prerelease.28
 - @patternfly/react-integration@5.1.1-prerelease.15
 - demo-app-ts@5.1.1-prerelease.51
 - @patternfly/react-table@5.2.0-prerelease.28

* chore(eslint): Added React Testing Library linter plugin (#9805)

* chore(release): releasing packages [ci skip]

 - @patternfly/react-code-editor@5.2.0-prerelease.29
 - @patternfly/react-core@5.2.0-prerelease.29
 - @patternfly/react-docs@6.2.0-prerelease.29
 - @patternfly/react-icons@5.2.0-prerelease.8
 - demo-app-ts@5.1.1-prerelease.52
 - @patternfly/react-table@5.2.0-prerelease.29

* chore(DataList): update tests (#9672)

* add spread prop test, update test

* chore(DataList): update tests

* fix merge error

* break out into separate files, pr feedback

* updates

* fix some example ids

* minor test updates

* revert action change

* bug(ClipboardCopy): change children type to string (#9743)

* bug(ClipboardCopy): change children type to string

Signed-off-by: gitdallas <dallas.nicol@gmail.com>

* fix clipboardcopyexpanded to work with string children

Signed-off-by: gitdallas <dallas.nicol@gmail.com>

* refactor a bit

* fix bad rebase

---------

Signed-off-by: gitdallas <dallas.nicol@gmail.com>

* chore(deps): update devdependencies (#9817)

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

* fix Search Input - composable advanced search demo (#9484)

* Search Input - composable advanced search fix date

* remove isFill from datePicker

* docs(custom menu): add example with search input inline filtering (#9687)

* docs(custom menu): add example with search input inline filtering

* refactor(demo menu): rename to InlineSearchFilterMenuDemo

* chore(HelperText): update tests (#9761)

* chore(HelperText): update tests

* break out helpertextitem tests, update tests

* updates

* fix lint

* fix(Chip): update tooltip vis when chip updates (#9819)

* fix(Chip): enable tooltip when chip updates

* fix casting

* chore(DescriptionList): update tests (#9753)

* chore(DescriptionList): update tests

* break out tests, pr feedback

* updates

* add autofit width mod test

* chore(release): releasing packages [ci skip]

 - @patternfly/react-code-editor@5.2.0-prerelease.30
 - @patternfly/react-core@5.2.0-prerelease.30
 - @patternfly/react-docs@6.2.0-prerelease.30
 - demo-app-ts@5.1.1-prerelease.53
 - @patternfly/react-table@5.2.0-prerelease.30

* chore(TreeView): updated tests (#9773)

* chore(TreeView): updated tests

* Added tests for TreeViewListItem

* Added tests for TreeViewRoot and TreeView

* Updated snapshots and queries

* chore(Table) convert demos to ts (#9621)

* chore(table) convert to TS

chore(DashboardWrapper) convert to TS

chore(Table) convert demos to TS

delete superfluous dashboard components

declare as ts files

remove duplicate ids

fix import errors, WIP build errors

sync toolbar demo with main

* update import paths

* fix more import paths

* try import from dist/esm

* fix build

* convert remaining table demos to ts, WIP draggable logic

* revert col management with draggable to previous dnd implementation

* align file names with demo names, cleanup types, fix TS errors in demo files

* update fileNames in table.md

* PR feedback from Eric

* fix category dropdown

* fix demos, remove table actions that do not support main purpose of column management demos

* add fix for a11y tests as suggested by Eric

* update toolbar snap

* add param type to labelText

---------

Co-authored-by: Jenny <32821331+jenny-s51@users.noreply.github.com>

* chore(release): releasing packages [ci skip]

 - @patternfly/react-code-editor@5.2.0-prerelease.31
 - @patternfly/react-core@5.2.0-prerelease.31
 - @patternfly/react-docs@6.2.0-prerelease.31
 - demo-app-ts@5.1.1-prerelease.54
 - @patternfly/react-table@5.2.0-prerelease.31

* chore(deps): update devdependencies (#9829)

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

---------

Signed-off-by: gitdallas <dallas.nicol@gmail.com>
Co-authored-by: Michael Coker <35148959+mcoker@users.noreply.github.com>
Co-authored-by: patternfly-build <patternfly-build@redhat.com>
Co-authored-by: Jeff Puzzo <96431149+jpuzz0@users.noreply.github.com>
Co-authored-by: adamviktora <84135613+adamviktora@users.noreply.github.com>
Co-authored-by: Mark Franceschelli <39063664+mfrances17@users.noreply.github.com>
Co-authored-by: kmcfaul <45077788+kmcfaul@users.noreply.github.com>
Co-authored-by: Austin Sullivan <ausulliv@redhat.com>
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Kells512 <72694484+Kells512@users.noreply.github.com>
Co-authored-by: nicolethoen <nthoen@redhat.com>
Co-authored-by: Eric Olkowski <thatblindgeye@gmail.com>
Co-authored-by: Eric Olkowski <70952936+thatblindgeye@users.noreply.github.com>
Co-authored-by: Jenny <32821331+jenny-s51@users.noreply.github.com>
Co-authored-by: Dallas <dallas.nicol@gmail.com>
Co-authored-by: Maria <mariaaga@redhat.com>
Co-authored-by: Dominik Petřík <77832970+Dominik-Petrik@users.noreply.github.com>
  • Loading branch information
17 people authored Nov 21, 2023
1 parent e097336 commit 8bc9f34
Show file tree
Hide file tree
Showing 218 changed files with 9,163 additions and 9,118 deletions.
1 change: 0 additions & 1 deletion .eslintignore
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
# Javascript builds
node_modules
dist
__tests__
thirdparty
tsc_out
.out
Expand Down
9 changes: 9 additions & 0 deletions .eslintrc.json
Original file line number Diff line number Diff line change
Expand Up @@ -127,6 +127,15 @@
"rules": {
"patternfly-react/no-anonymous-functions": "off"
}
},
{
"files": ["**/*.test.[jt]s?(x)"],
"extends": ["plugin:testing-library/react"],
"rules": {
"testing-library/no-node-access": "off",
"react/jsx-key": "off",
"no-console": "off"
}
}
]
}
2 changes: 1 addition & 1 deletion .github/workflows/pr-preview.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ jobs:
node_modules
**/node_modules
~/.cache/Cypress
key: ${{ runner.os }}-yarn-14-${{ secrets.CACHE_VERSION }}-${{ hashFiles('yarn.lock') }}
key: ${{ runner.os }}-yarn-14-${{ secrets.CACHE_VERSION }}-${{ hashFiles('yarn.lock', 'packages/*/package.json') }}
- run: yarn install --frozen-lockfile
if: steps.yarn-cache.outputs.cache-hit != 'true'
- uses: actions/cache@v2
Expand Down
2 changes: 1 addition & 1 deletion jest.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ module.exports = {
],
roots: ['<rootDir>/packages'],
transform: {
'^.+\\.[jt]sx?$': 'babel-jest',
'^.+\\.m?[jt]sx?$': 'babel-jest',
'^.+\\.svg$': 'jest-transform-stub'
},
setupFilesAfterEnv: ['<rootDir>/packages/testSetup.ts'],
Expand Down
7 changes: 5 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@
"@testing-library/jest-dom": "^5.16.5",
"@testing-library/react": "^13.4.0",
"@testing-library/user-event": "14.5.1",
"@types/jest": "29.5.5",
"@types/jest": "29.5.8",
"@types/react": "^18",
"@types/react-dom": "^18",
"@typescript-eslint/eslint-plugin": "^5.59.2",
Expand All @@ -50,6 +50,7 @@
"eslint-plugin-markdown": "^3.0.0",
"eslint-plugin-prettier": "^5.0.0",
"eslint-plugin-react": "^7.32.2",
"eslint-plugin-testing-library": "^6.1.0",
"fs-extra": "^11.1.1",
"glob": "^9.3.0",
"husky": "^4.3.0",
Expand All @@ -64,7 +65,8 @@
"react-dom": "^18",
"surge": "^0.23.1",
"ts-patch": "^2.1.0",
"typescript": "^4.7.4"
"typescript": "^4.7.4",
"ts-node": "^10.9.1"
},
"scripts": {
"build": "yarn clean && yarn build:generate && yarn build:esm && yarn build:cjs && yarn build:subpaths && yarn build:single:packages",
Expand All @@ -84,6 +86,7 @@
"lint:md": "yarn eslint packages --ext md --no-eslintrc --config .eslintrc-md.json --cache",
"lint:ts": "yarn lint packages/*/src",
"lint:versions": "node scripts/verifyPatternflyVersions.js",
"lint:tests": "yarn lint packages/*/src/components/*/__tests__/*.test.*",
"prepare": "ts-patch install -s",
"serve:docs": "yarn workspace @patternfly/react-docs serve",
"serve:integration": "lerna run serve:demo-app",
Expand Down
8 changes: 8 additions & 0 deletions packages/react-charts/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,14 @@ See [Conventional Commits](https://conventionalcommits.org) for commit guideline

**Note:** Version bump only for package @patternfly/react-charts

# 7.2.0-prerelease.7 (2023-11-10)

**Note:** Version bump only for package @patternfly/react-charts

# 7.2.0-prerelease.6 (2023-11-03)

**Note:** Version bump only for package @patternfly/react-charts

# 7.2.0-prerelease.5 (2023-10-26)

**Note:** Version bump only for package @patternfly/react-charts
Expand Down
48 changes: 48 additions & 0 deletions packages/react-code-editor/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,54 @@ See [Conventional Commits](https://conventionalcommits.org) for commit guideline

**Note:** Version bump only for package @patternfly/react-code-editor

# [5.2.0-prerelease.31](https://github.com/patternfly/patternfly-react/compare/@patternfly/react-code-editor@5.2.0-prerelease.30...@patternfly/react-code-editor@5.2.0-prerelease.31) (2023-11-17)

**Note:** Version bump only for package @patternfly/react-code-editor

# [5.2.0-prerelease.30](https://github.com/patternfly/patternfly-react/compare/@patternfly/react-code-editor@5.2.0-prerelease.29...@patternfly/react-code-editor@5.2.0-prerelease.30) (2023-11-16)

**Note:** Version bump only for package @patternfly/react-code-editor

# [5.2.0-prerelease.29](https://github.com/patternfly/patternfly-react/compare/@patternfly/react-code-editor@5.2.0-prerelease.28...@patternfly/react-code-editor@5.2.0-prerelease.29) (2023-11-14)

**Note:** Version bump only for package @patternfly/react-code-editor

# [5.2.0-prerelease.28](https://github.com/patternfly/patternfly-react/compare/@patternfly/react-code-editor@5.2.0-prerelease.27...@patternfly/react-code-editor@5.2.0-prerelease.28) (2023-11-14)

**Note:** Version bump only for package @patternfly/react-code-editor

# [5.2.0-prerelease.27](https://github.com/patternfly/patternfly-react/compare/@patternfly/react-code-editor@5.2.0-prerelease.26...@patternfly/react-code-editor@5.2.0-prerelease.27) (2023-11-14)

**Note:** Version bump only for package @patternfly/react-code-editor

# [5.2.0-prerelease.26](https://github.com/patternfly/patternfly-react/compare/@patternfly/react-code-editor@5.2.0-prerelease.25...@patternfly/react-code-editor@5.2.0-prerelease.26) (2023-11-13)

**Note:** Version bump only for package @patternfly/react-code-editor

# [5.2.0-prerelease.25](https://github.com/patternfly/patternfly-react/compare/@patternfly/react-code-editor@5.2.0-prerelease.24...@patternfly/react-code-editor@5.2.0-prerelease.25) (2023-11-10)

**Note:** Version bump only for package @patternfly/react-code-editor

# [5.2.0-prerelease.24](https://github.com/patternfly/patternfly-react/compare/@patternfly/react-code-editor@5.2.0-prerelease.23...@patternfly/react-code-editor@5.2.0-prerelease.24) (2023-11-03)

**Note:** Version bump only for package @patternfly/react-code-editor

# [5.2.0-prerelease.23](https://github.com/patternfly/patternfly-react/compare/@patternfly/react-code-editor@5.2.0-prerelease.22...@patternfly/react-code-editor@5.2.0-prerelease.23) (2023-11-03)

**Note:** Version bump only for package @patternfly/react-code-editor

# [5.2.0-prerelease.22](https://github.com/patternfly/patternfly-react/compare/@patternfly/react-code-editor@5.2.0-prerelease.21...@patternfly/react-code-editor@5.2.0-prerelease.22) (2023-11-02)

**Note:** Version bump only for package @patternfly/react-code-editor

# [5.2.0-prerelease.21](https://github.com/patternfly/patternfly-react/compare/@patternfly/react-code-editor@5.2.0-prerelease.20...@patternfly/react-code-editor@5.2.0-prerelease.21) (2023-11-02)

**Note:** Version bump only for package @patternfly/react-code-editor

# [5.2.0-prerelease.20](https://github.com/patternfly/patternfly-react/compare/@patternfly/react-code-editor@5.2.0-prerelease.19...@patternfly/react-code-editor@5.2.0-prerelease.20) (2023-11-02)

**Note:** Version bump only for package @patternfly/react-code-editor

# [5.2.0-prerelease.19](https://github.com/patternfly/patternfly-react/compare/@patternfly/react-code-editor@5.2.0-prerelease.18...@patternfly/react-code-editor@5.2.0-prerelease.19) (2023-10-30)

**Note:** Version bump only for package @patternfly/react-code-editor
Expand Down
70 changes: 70 additions & 0 deletions packages/react-core/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,76 @@ See [Conventional Commits](https://conventionalcommits.org) for commit guideline

- **Drawer:** Added start and end to position props, updated resizing to work with RTL ([#9627](https://github.com/patternfly/patternfly-react/issues/9627)) ([e12b872](https://github.com/patternfly/patternfly-react/commit/e12b8726b9ebc2fec921b7316a270a9c09decf96))

# [5.2.0-prerelease.31](https://github.com/patternfly/patternfly-react/compare/@patternfly/react-core@5.2.0-prerelease.30...@patternfly/react-core@5.2.0-prerelease.31) (2023-11-17)

**Note:** Version bump only for package @patternfly/react-core

# [5.2.0-prerelease.30](https://github.com/patternfly/patternfly-react/compare/@patternfly/react-core@5.2.0-prerelease.29...@patternfly/react-core@5.2.0-prerelease.30) (2023-11-16)

### Bug Fixes

- **Chip:** update tooltip vis when chip updates ([#9819](https://github.com/patternfly/patternfly-react/issues/9819)) ([18c140a](https://github.com/patternfly/patternfly-react/commit/18c140a2adcc1833e4b095755aa7495d1d88a177))

# [5.2.0-prerelease.29](https://github.com/patternfly/patternfly-react/compare/@patternfly/react-core@5.2.0-prerelease.28...@patternfly/react-core@5.2.0-prerelease.29) (2023-11-14)

**Note:** Version bump only for package @patternfly/react-core

# [5.2.0-prerelease.28](https://github.com/patternfly/patternfly-react/compare/@patternfly/react-core@5.2.0-prerelease.27...@patternfly/react-core@5.2.0-prerelease.28) (2023-11-14)

**Note:** Version bump only for package @patternfly/react-core

# [5.2.0-prerelease.27](https://github.com/patternfly/patternfly-react/compare/@patternfly/react-core@5.2.0-prerelease.26...@patternfly/react-core@5.2.0-prerelease.27) (2023-11-14)

**Note:** Version bump only for package @patternfly/react-core

# [5.2.0-prerelease.26](https://github.com/patternfly/patternfly-react/compare/@patternfly/react-core@5.2.0-prerelease.25...@patternfly/react-core@5.2.0-prerelease.26) (2023-11-13)

### Bug Fixes

- **DatePicker:** updated logic for parsing and focus management ([#9794](https://github.com/patternfly/patternfly-react/issues/9794)) ([a12cf31](https://github.com/patternfly/patternfly-react/commit/a12cf313f0924a61a8cf20ee78b4b27290b9c05f))

# [5.2.0-prerelease.25](https://github.com/patternfly/patternfly-react/compare/@patternfly/react-core@5.2.0-prerelease.24...@patternfly/react-core@5.2.0-prerelease.25) (2023-11-10)

**Note:** Version bump only for package @patternfly/react-core

# [5.2.0-prerelease.24](https://github.com/patternfly/patternfly-react/compare/@patternfly/react-core@5.2.0-prerelease.23...@patternfly/react-core@5.2.0-prerelease.24) (2023-11-03)

### Bug Fixes

- **ClipboardCopy:** kepp caret position ([#9772](https://github.com/patternfly/patternfly-react/issues/9772)) ([981361e](https://github.com/patternfly/patternfly-react/commit/981361e0de354bbe06c4a799b6e7c92228dab51f))

### Features

- **Datalist:** implement full page Basic demo to match HTML [#9048](https://github.com/patternfly/patternfly-react/issues/9048) ([#9087](https://github.com/patternfly/patternfly-react/issues/9087)) ([ab18059](https://github.com/patternfly/patternfly-react/commit/ab1805993ed5e2b5ed3d2f1be4131e035152b468))

# [5.2.0-prerelease.23](https://github.com/patternfly/patternfly-react/compare/@patternfly/react-core@5.2.0-prerelease.22...@patternfly/react-core@5.2.0-prerelease.23) (2023-11-03)

**Note:** Version bump only for package @patternfly/react-core

# [5.2.0-prerelease.22](https://github.com/patternfly/patternfly-react/compare/@patternfly/react-core@5.2.0-prerelease.21...@patternfly/react-core@5.2.0-prerelease.22) (2023-11-02)

### Bug Fixes

- **TreeView:** define button type ([#9770](https://github.com/patternfly/patternfly-react/issues/9770)) ([a772c6d](https://github.com/patternfly/patternfly-react/commit/a772c6d67bfa4154979ee14a34ec954406503109))

# [5.2.0-prerelease.21](https://github.com/patternfly/patternfly-react/compare/@patternfly/react-core@5.2.0-prerelease.20...@patternfly/react-core@5.2.0-prerelease.21) (2023-11-02)

### Bug Fixes

- **Notification Drawer:** Added screen reader text for notification drawer item read state ([#9569](https://github.com/patternfly/patternfly-react/issues/9569)) ([bc19f91](https://github.com/patternfly/patternfly-react/commit/bc19f9148e872fb62d8cd2bf644a771d9c5650d7))
- **Text input:** Added aria-expanded ([#9705](https://github.com/patternfly/patternfly-react/issues/9705)) ([7f6a62c](https://github.com/patternfly/patternfly-react/commit/7f6a62c1a3f860a8759c63cde17da6b763dd7b48))
- **Wizard:** onStepChange - skip isDisabled & isHidden ([#9748](https://github.com/patternfly/patternfly-react/issues/9748)) ([4d4d623](https://github.com/patternfly/patternfly-react/commit/4d4d623d294bbc7821c6dc9156980f2b8c609c96))

### Features

- **Wizard:** ability to add props to WizardFooter buttons ([#9709](https://github.com/patternfly/patternfly-react/issues/9709)) ([9f21cee](https://github.com/patternfly/patternfly-react/commit/9f21cee5438c8ec4d0e2c5c938f9fffda013757b))

# [5.2.0-prerelease.20](https://github.com/patternfly/patternfly-react/compare/@patternfly/react-core@5.2.0-prerelease.19...@patternfly/react-core@5.2.0-prerelease.20) (2023-11-02)

### Bug Fixes

- **RTL:** added right-to-left page demo ([#9694](https://github.com/patternfly/patternfly-react/issues/9694)) ([d7308ae](https://github.com/patternfly/patternfly-react/commit/d7308aebec1e3ff22df548b5613f058c9ba35262))

# [5.2.0-prerelease.19](https://github.com/patternfly/patternfly-react/compare/@patternfly/react-core@5.2.0-prerelease.18...@patternfly/react-core@5.2.0-prerelease.19) (2023-10-30)

**Note:** Version bump only for package @patternfly/react-core
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,6 @@ import { render } from '@testing-library/react';
import { AboutModalBox } from '../AboutModalBox';

test('AboutModalBox Test', () => {
const { asFragment } = render(
<AboutModalBox aria-labelledby="id">
This is a AboutModalBox
</AboutModalBox>
);
const { asFragment } = render(<AboutModalBox aria-labelledby="id">This is a AboutModalBox</AboutModalBox>);
expect(asFragment()).toMatchSnapshot();
});
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,6 @@ test('Renders children', () => {
});

test('Matches the snapshot', () => {
const { asFragment } = render(
<AccordionItem>Test</AccordionItem>
);
const { asFragment } = render(<AccordionItem>Test</AccordionItem>);
expect(asFragment()).toMatchSnapshot();
});
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ test('Alert Group renders without children', () => {
});

test('Alert Group works with n children', () => {
const { asFragment } = render(
render(
<AlertGroup data-testid="container">
<Alert variant="success" title="alert title" />
<Alert variant="warning" title="another alert title" />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -115,10 +115,11 @@ test('Clicking backToTop scrolls back to top of the element passed via scrollabl
const user = userEvent.setup();
const wrapper = document.getElementById('backToTopWrapper');
fireEvent.scroll(wrapper as HTMLElement, { target: { scrollY: 401 } });
// eslint-disable-next-line @typescript-eslint/no-non-null-assertion
wrapper!.scrollTo = jest.fn();
await user.click(screen.getByRole(`button`).parentElement as Element);

expect(wrapper?.scrollTo).toBeCalledTimes(1);
expect(wrapper?.scrollTo).toHaveBeenCalledTimes(1);
});

test('Passes correct text content to button child component', () => {
Expand Down
2 changes: 1 addition & 1 deletion packages/react-core/src/components/Button/Button.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import * as React from 'react';
import styles from '@patternfly/react-styles/css/components/Button/button';
import { css } from '@patternfly/react-styles';
import { Spinner, spinnerSize } from '../Spinner';
import { useOUIAProps, OUIAProps } from '../../helpers';
import { useOUIAProps, OUIAProps } from '../../helpers/OUIA/ouia';
import { Badge } from '../Badge';

export enum ButtonVariant {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ import React from 'react';

import { render, screen } from '@testing-library/react';

import CartArrowDownIcon from '@patternfly/react-icons/dist/esm/icons/cart-arrow-down-icon';
import { Button, ButtonVariant } from '../Button';

Object.values(ButtonVariant).forEach((variant) => {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,9 @@ test('Next year dates have correct year in aria label', () => {
});

test('InlineProps render correct wrapper component and attributes', () => {
render(<CalendarMonth inlineProps={{component: 'article', title: <div id="hi">Title</div>, ariaLabelledby: "hi"}} />);
render(
<CalendarMonth inlineProps={{ component: 'article', title: <div id="hi">Title</div>, ariaLabelledby: 'hi' }} />
);

const article = screen.getByRole('article');
expect(article).toHaveAttribute('aria-labelledby', 'hi');
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ describe('CardBody', () => {
test('allows passing in a React Component as the component', () => {
const Component = () => <div>im a div</div>;

render(<CardBody component={(Component as unknown) as keyof JSX.IntrinsicElements} />);
render(<CardBody component={Component as unknown as keyof JSX.IntrinsicElements} />);
expect(screen.getByText('im a div')).toBeInTheDocument();
});

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ describe('CardFooter', () => {

test('allows passing in a React Component as the component', () => {
const Component = () => <div>im a div</div>;
render(<CardFooter component={(Component as unknown) as keyof JSX.IntrinsicElements} />);
render(<CardFooter component={Component as unknown as keyof JSX.IntrinsicElements} />);
expect(screen.getByText('im a div')).toBeInTheDocument();
});
});
11 changes: 11 additions & 0 deletions packages/react-core/src/components/Chip/Chip.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,17 @@ class Chip extends React.Component<ChipProps, ChipState> {
});
}

componentDidUpdate(_prevProps: ChipProps, prevState: ChipState) {
const nextIsTooltipVisible = Boolean(
this.span.current && this.span.current.offsetWidth < this.span.current.scrollWidth
);
if (prevState.isTooltipVisible !== nextIsTooltipVisible) {
this.setState({
isTooltipVisible: nextIsTooltipVisible
});
}
}

setChipStyle = () => ({
[cssChipTextMaxWidth.name]: this.props.textMaxWidth
});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ test('chip group with closeBtnAriaLabel', () => {
</ChipGroup>
);
expect(screen.getByLabelText('close button aria label')).toBeInTheDocument();
expect(screen.getByLabelText('close button aria label')).toHaveAccessibleName("close button aria label category");
expect(screen.getByLabelText('close button aria label')).toHaveAccessibleName('close button aria label category');
});

test('chip group onClick', async () => {
Expand Down Expand Up @@ -169,8 +169,6 @@ test('chip group expanded', async () => {
});

test('overflow chip does not render by default when < 4 children are passed', async () => {
const user = userEvent.setup();

render(
<ChipGroup>
<Chip>1</Chip>
Expand All @@ -183,8 +181,6 @@ test('overflow chip does not render by default when < 4 children are passed', as
});

test('overflow chip collapsed by default', async () => {
const user = userEvent.setup();

render(
<ChipGroup>
<Chip>1</Chip>
Expand Down
Loading

0 comments on commit 8bc9f34

Please sign in to comment.