Skip to content

Commit

Permalink
fix!: v3 deprecations (#2655)
Browse files Browse the repository at this point in the history
* fix!: remove deprecatedCustomEvent

* fix(tools)!: remove framework test wrappers

We will retool this and develop something better. In the mean time, use the react wrapper components

* docs: fix logo

* fix(eslint-config): update ecmaVersion

* fix(accordion): use pfv4 tokens

* fix(tools)!: remove DocsPage renderers

* fix(icon)!: remove elements/pf-icon/icons

Use `@patternfly/icons` instead
  • Loading branch information
bennypowers authored Jan 18, 2024
1 parent fe6e646 commit de4cfa4
Show file tree
Hide file tree
Showing 234 changed files with 6,881 additions and 4,802 deletions.
4 changes: 4 additions & 0 deletions .changeset/eight-waves-join.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
---
"@patternfly/elements": major
---
Remove `/elements/pf-icon/icons/**/*`. Use `@patternfly/icons` instead.
4 changes: 4 additions & 0 deletions .changeset/light-carrots-suffer.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
---
"@patternfly/pfe-tools": major
---
Remove `DocsPage` render functions
4 changes: 4 additions & 0 deletions .changeset/little-singers-sell.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
---
"@patternfly/elements": major
---
`<pf-accordion>`: use patternfly design tokens. removes `--accordion__bordered--Color`
4 changes: 4 additions & 0 deletions .changeset/long-rings-burn.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
---
"@patternfly/pfe-core": major
---
Remove `deprecatedCustomEvent`
28 changes: 28 additions & 0 deletions .changeset/odd-mice-stop.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
---
"@patternfly/pfe-tools": major
---
Dev server config no longer uses `nodeResolution`. Instead you must provide configuration for the import map plugin.

```js
import {
pfeDevServerConfig,
getPatternflyIconNodemodulesImports,
} from '@patternfly/pfe-tools/dev-server/config.js';

export default pfeDevServerConfig({
importMapOptions: {
providers: {
'zero-md': 'nodemodules',
'@patternfly/icons': 'nodemodules',
'@patternfly/elements': 'nodemodules',
'@patternfly/pfe-tools': 'nodemodules',
'@patternfly/pfe-core': 'nodemodules',
},
inputMap: {
imports: {
...await getPatternflyIconNodemodulesImports(import.meta.url),
},
},
},
});
```
4 changes: 4 additions & 0 deletions .changeset/olive-pens-create.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
---
"@patternfly/pfe-tools": major
---
Remove react and vue test wrapper helpers. Use React wrapper components instead.
4 changes: 4 additions & 0 deletions .changeset/violet-wasps-obey.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
---
"@patternfly/eslint-config-elements": patch
---
Update ecmaVersion to 2022
1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,6 @@ tools/*/test/**/*.png
!core/*/demo/*
!tools/*/demo/*

elements/pf-icon/icons
!elements/pf-icon/demo/icons/**/*.js

!scripts/**/*.js
Expand Down
8 changes: 7 additions & 1 deletion brand/logo/svg/pfe-icon-white.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
11 changes: 0 additions & 11 deletions core/pfe-core/functions/deprecatedCustomEvent.ts

This file was deleted.

4 changes: 2 additions & 2 deletions core/pfe-core/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -51,8 +51,8 @@
"test": "wtr --files './test/*.spec.ts' --config ../../web-test-runner.config.js"
},
"dependencies": {
"@floating-ui/dom": "^1.5.3",
"lit": "^3.1.0"
"@floating-ui/dom": "^1.5.4",
"lit": "^3.1.1"
},
"repository": {
"type": "git",
Expand Down
9 changes: 9 additions & 0 deletions docs/_data/importMap.cjs
Original file line number Diff line number Diff line change
Expand Up @@ -109,5 +109,14 @@ module.exports = async function() {
map.imports['@patternfly/pfe-tools/environment.js'] = '/tools/environment.js';


// add imports for all icon files in /node_modules/@patternfly/icons/{far, fas, fab, patternfly}/
const iconsImports = (await glob('./{far,fas,fab,patternfly}/*.js', { cwd: path.join(__dirname, '../../node_modules/@patternfly/icons') }))
.filter(x => !x.endsWith('.d.ts'))
.map(x => x);

for (const icon of iconsImports) {
map.imports[`@patternfly/icons/${icon}`] = `/assets/@patternfly/icons/${icon}`;
}

return map;
};
8 changes: 6 additions & 2 deletions docs/_includes/_nav.njk
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,12 @@
<div class="placeholder"></div>
<a href="{{ '/' | url }}" aria-label="PatternFly Elements Home">
<picture>
<source media="(min-width: 420px)" srcset="{{ '/images/pfe-logo-inverse-white.svg' | url }}">
<img alt="PatternFly Elements" src="{{ '/images/pfe-logo-icon-white.svg' | url }}">
<source media="(min-width: 420px)"
srcset="{{ '/images/pfe-logo-inverse-white.svg' | url }}"
height="57.5">
<img alt="PatternFly Elements"
src="{{ '/images/pfe-logo-icon-white.svg' | url }}"
width="57.5" height="57.5">
</picture>
</a>
</div>
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Loading

0 comments on commit de4cfa4

Please sign in to comment.