Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .changeset/breezy-steaks-melt.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@patternfly/pfe-label": patch
---

Fix label style loading
4 changes: 4 additions & 0 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,10 @@ jobs:
id: build
run: npm run build

- name: Release Dry Run
id: release-dry
run: npm run prepublishOnly -ws --if-present

# Upload compiled assets to make them available for downstream jobs
- name: Upload artifacts
uses: actions/upload-artifact@v2
Expand Down
4 changes: 3 additions & 1 deletion elements/pfe-icon/demo/pfe-icon.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
import '@patternfly/pfe-icon';
import '@patternfly/pfe-tooltip';
import '@patternfly/pfe-button';
// TS6202: Project references may not form a circular graph.
// import '@patternfly/pfe-button';
import('@patternfly' + '/' + 'pfe-button');
import '@patternfly/pfe-autocomplete';
import { iconSets } from '@patternfly/pfe-tools/environment.js';
import { render, html } from 'lit';
Expand Down
2 changes: 1 addition & 1 deletion elements/pfe-icon/pfe-icon.ts
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ export class PfeIcon extends LitElement {

private static getters = new Map<string, URLGetter>();

private static instances = new Set();
private static instances = new Set<PfeIcon>();

/** Icon set */
@property() set = PfeIcon.defaultIconSet;
Expand Down
9 changes: 5 additions & 4 deletions elements/pfe-icon/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,11 @@
"./**/*"
],
"exclude": [
"./icons/**/*.js"
"./icons/**/*.js",
"./demo/pfe-icon.js",
"./demo/custom-icon-sets.js",
"./test/rh-icon*.js",
"./custom-elements-manifest.config.js"
],
"compilerOptions": {
"module": "esnext",
Expand All @@ -22,9 +26,6 @@
{
"path": "../pfe-tooltip"
},
{
"path": "../pfe-button"
},
{
"path": "../pfe-autocomplete"
}
Expand Down
2 changes: 1 addition & 1 deletion elements/pfe-label/pfe-label.ts
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ import styles from './pfe-label.scss';
export class PfeLabel extends BaseLabel {
static readonly version = '{{version}}';

static readonly styles = [BaseLabel.styles, styles];
static readonly styles = [...BaseLabel.styles, styles];

static readonly shadowRootOptions: ShadowRootInit = { ...BaseLabel.shadowRootOptions, delegatesFocus: true };

Expand Down
4 changes: 2 additions & 2 deletions elements/pfe-label/test/pfe-label.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,8 @@ describe('<pfe-label>', function() {
// replace the default built-in icon set resolveIconName function
// with one that loads local icons. we don't want tests dependent on
// prod servers.
PfeIcon.addIconSet('rh', '', function(name: string) {
return `/elements/pfe-icon/test/${name.replace('rh', 'rh-icon')}.svg`;
PfeIcon.addIconSet('rh', function(name: string) {
return new URL(`/elements/pfe-icon/test/${name.replace('rh', 'rh-icon')}.svg`);
});
});

Expand Down