Skip to content

Commit

Permalink
Merge branch '10.x.x' into fix-karma
Browse files Browse the repository at this point in the history
  • Loading branch information
johnhwhite authored Sep 11, 2024
2 parents 22eb989 + 1a7001d commit 1385a46
Show file tree
Hide file tree
Showing 81 changed files with 1,201 additions and 870 deletions.
3 changes: 0 additions & 3 deletions .github/actions/e2e-affected/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,6 @@ outputs:
runs:
using: 'composite'
steps:
- name: Build e2e-schematics
shell: bash
run: npx nx build e2e-schematics
- name: Check if e2e tests are affected by the changes
id: affected
uses: actions/github-script@v7
Expand Down
69 changes: 55 additions & 14 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,10 @@ on:
branches:
- 10.x.x

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

env:
NX_CLOUD_ACCESS_TOKEN: ${{ secrets.NX_CLOUD_ACCESS_TOKEN }}

Expand All @@ -18,6 +22,9 @@ jobs:
runs-on: ubuntu-latest
outputs:
node-version: ${{ steps.setup-node.outputs.node-version }}
env:
NX_TASKS_RUNNER: 'local'
NX_CLOUD_DISTRIBUTED_EXECUTION: 'false'
steps:
- uses: actions/checkout@v4
with:
Expand All @@ -40,6 +47,23 @@ jobs:
if: steps.cache.outputs.cache-hit != 'true'
run: npm ci

agents:
name: Bootup Nx Cloud agent
runs-on: ubuntu-latest
needs: install-deps
strategy:
matrix:
agent: [1, 2, 3]
steps:
- uses: actions/checkout@v4
- name: Retrieve node_modules cache
uses: actions/cache@v4
with:
path: node_modules
key: ${{ runner.os }}-node-${{ needs.install-deps.outputs.node-version }}-modules-${{ hashFiles('package-lock.json') }}
- name: Start Nx Agent ${{ matrix.agent }}
run: npx nx-cloud start-agent

build-coverage-lint:
name: Build, code coverage unit tests, and linting
if: ${{ !startsWith( github.head_ref || github.ref_name, 'release-please--' ) }}
Expand All @@ -49,10 +73,10 @@ jobs:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- run: npx nx-cloud start-ci-run --distribute-on="8 linux-medium-plus-js"
- uses: actions/setup-node@v4
with:
node-version-file: '.nvmrc'
- run: npx nx-cloud start-ci-run --agent-count=3 --distribute-on="manual"
- name: Retrieve node_modules cache
uses: actions/cache/restore@v4
with:
Expand All @@ -64,10 +88,10 @@ jobs:
run: node ./scripts/rebase-pr.js
- name: Run build, lint, test, and posttest for npm packages
run: |
npx nx affected --target build lint test posttest --configuration ci --exclude '*,!tag:npm'
npx nx affected --target build lint test posttest --configuration ci --parallel 1 --exclude '*,!tag:npm'
- name: Run lint, test, and posttest for non-npm packages
run: |
npx nx affected --target lint test posttest --configuration ci --exclude 'tag:npm'
npx nx affected --target lint test posttest --configuration ci --parallel 1 --exclude 'tag:npm'
- name: Stop
if: ${{ always() }}
run: npx nx-cloud stop-all-agents
Expand Down Expand Up @@ -102,21 +126,14 @@ jobs:
run: |
[ '${{ needs.build-coverage-lint.result }}' == 'success' ] && echo Linted. || false
stop-agents:
name: Stop Nx Cloud agents
needs: build-coverage-lint
runs-on: ubuntu-latest
if: ${{ always() && !startsWith( github.head_ref || github.ref_name, 'release-please--' ) }}
steps:
- name: Stop agents
run: |
[ '${{ needs.build-coverage-lint.result }}' == 'success' ] && echo Agents stopped. || false
check-workspace:
name: Check dependencies and resources
if: ${{ always() && !startsWith( github.head_ref || github.ref_name, 'release-please--' ) }}
if: ${{ !cancelled() && !startsWith( github.head_ref || github.ref_name, 'release-please--' ) }}
needs: install-deps
runs-on: ubuntu-latest
env:
NX_TASKS_RUNNER: 'local'
NX_CLOUD_DISTRIBUTED_EXECUTION: 'false'
steps:
- uses: actions/checkout@v4
with:
Expand Down Expand Up @@ -144,6 +161,9 @@ jobs:
name: Check formatting
needs: install-deps
runs-on: ubuntu-latest
env:
NX_TASKS_RUNNER: 'local'
NX_CLOUD_DISTRIBUTED_EXECUTION: 'false'
steps:
- uses: actions/checkout@v4
with:
Expand All @@ -170,6 +190,9 @@ jobs:
needs: install-deps
runs-on: ubuntu-latest
if: ${{ github.event_name != 'pull_request' }}
env:
NX_TASKS_RUNNER: 'local'
NX_CLOUD_DISTRIBUTED_EXECUTION: 'false'
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
Expand All @@ -194,3 +217,21 @@ jobs:
#cor-skyux-notifications
SLACK_CHANNEL: C01GY7ZP4HM
SLACK_FOOTER: 'Blackbaud Sky Build User'

stop-agents:
name: Stop Nx Cloud agents
runs-on: ubuntu-latest
if: ${{ !cancelled() }}
needs: build-coverage-lint
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version-file: '.nvmrc'
- name: Retrieve node_modules cache
uses: actions/cache/restore@v4
with:
path: node_modules
key: ${{ runner.os }}-node-${{ needs.install-deps.outputs.node-version }}-modules-${{ hashFiles('package-lock.json') }}
- name: Stop Nx Cloud agents
run: npx nx-cloud stop-all-agents
60 changes: 49 additions & 11 deletions .github/workflows/e2e.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,16 @@ on:
- 10.x.x
workflow_dispatch:

concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.ref_name || github.event.ref }}
cancel-in-progress: true

env:
CYPRESS_VERIFY_TIMEOUT: 120000
GH_PAGES_OWNER: blackbaud
NX_CLOUD_ACCESS_TOKEN: ${{ secrets.NX_CLOUD_ACCESS_TOKEN }}
NX_TASKS_RUNNER: 'local'
NX_CLOUD_DISTRIBUTED_EXECUTION: 'false'
NX_REJECT_UNKNOWN_LOCAL_CACHE: '0'
PERCY_BROWSER_EXECUTABLE: /usr/bin/chromium
PERCY_COMMIT: ${{ github.sha }}
PERCY_SKIP_UPDATE_CHECK: 'true'
Expand Down Expand Up @@ -83,6 +89,19 @@ jobs:
echo 'Using workflow parameters:'
echo ''
echo '${{ steps.parameters.outputs.parameters }}' | jq
- name: Cache e2e-schematics
uses: actions/cache@v4
id: cache-e2e-schematics
with:
path: ./dist/libs/sdk/e2e-schematics
key: e2e-schematics-${{ runner.os }}-${{ github.head_ref || github.ref_name || github.event.ref }}
- name: Build e2e-schematics
# Used by .github/actions/e2e-affected/action.yml
if: steps.cache-e2e-schematics.outputs.cache-hit != 'true'
shell: bash
run: |
export CI="false"; export GITHUB_ACTIONS="false"; # Do not use NX cloud.
npx nx build e2e-schematics --no-parallel --runner=local
build-storybook:
name: Build Project Storybook
Expand All @@ -94,7 +113,6 @@ jobs:
strategy:
# If one build fails, do not cancel other builds.
fail-fast: false
max-parallel: 8
matrix:
project: ${{ fromJSON(needs.install-deps.outputs.parameters).projects }}
steps:
Expand All @@ -120,8 +138,15 @@ jobs:
/home/runner/.cache/Cypress
key: ${{ runner.os }}-node-${{ needs.install-deps.outputs.node-version }}-modules-${{ hashFiles('package-lock.json') }}
if: ${{ matrix.project != 'skip' }}
- name: Retrieve build-storybook-cache
uses: actions/cache@v4
with:
path: .nx/cache
key: build-storybook-${{ matrix.project }}-${{ runner.os }}-${{ github.head_ref || github.ref_name || github.event.ref }}
restore-keys: build-storybook-${{ matrix.project }}-${{ runner.os }}-
if: ${{ matrix.project != 'skip' }}
- name: Build ${{ matrix.project }}
run: npx nx run ${{ matrix.project }}:build-storybook:ci --no-agents
run: npx nx run ${{ matrix.project }}:build-storybook:ci --no-parallel --runner=local
if: ${{ matrix.project != 'skip' }}
- name: Upload storybook artifact
uses: actions/upload-artifact@v4
Expand Down Expand Up @@ -175,11 +200,17 @@ jobs:
/home/runner/.cache/Cypress
key: ${{ runner.os }}-node-${{ needs.install-deps.outputs.node-version }}-modules-${{ hashFiles('package-lock.json') }}
if: ${{ fromJson(needs.install-deps.outputs.parameters).ghPagesRepo == 'skyux-pr-preview' }}
- name: Retrieve build-${{ matrix.app }}-cache
uses: actions/cache@v4
with:
path: .nx/cache
key: build-${{ matrix.app }}-${{ runner.os }}-${{ github.head_ref || github.ref_name || github.event.ref }}
restore-keys: build-${{ matrix.app }}-${{ runner.os }}-
- name: Build ${{ matrix.app }}
run: |
npx nx build ${{ matrix.app }} \
--baseHref="https://blackbaud.github.io/skyux-pr-preview/${{ needs.install-deps.outputs.pr-number }}/${{ matrix.app }}/" \
--no-agents
--no-parallel --runner=local
if: ${{ fromJson(needs.install-deps.outputs.parameters).ghPagesRepo == 'skyux-pr-preview' && matrix.app != 'dep-graph' }}
- name: Build ${{ matrix.app }}
run: npx nx dep-graph --file=dist/apps/dep-graph/index.html
Expand Down Expand Up @@ -252,7 +283,7 @@ jobs:
--projectsJson='${{ fromJson(needs.install-deps.outputs.parameters).projectsJson }}' \
--baseUrl='../${{ fromJson(needs.install-deps.outputs.parameters).storybooksPath }}'
- name: Build Storybook Composition
run: npx nx run storybook:build-storybook:ci --outputDir=dist/storybook --no-agents
run: npx nx run storybook:build-storybook:ci --outputDir=dist/storybook --no-parallel --runner=local
- name: Checkout ${{ fromJson(needs.install-deps.outputs.parameters).ghPagesRepo }}
uses: actions/checkout@v4
with:
Expand All @@ -276,10 +307,9 @@ jobs:
concurrency:
group: ${{ github.workflow }}-${{ github.job }}--${{ matrix.project }}-${{ github.head_ref || format('{0}-{1}', github.run_id, github.run_attempt) }}
cancel-in-progress: true
needs: [install-deps, build-storybook]
needs: install-deps
strategy:
fail-fast: false
max-parallel: 8
matrix:
include: ${{ fromJSON(needs.install-deps.outputs.parameters).e2eTargets }}
steps:
Expand All @@ -305,6 +335,11 @@ jobs:
/home/runner/.cache/Cypress
key: ${{ runner.os }}-node-${{ needs.install-deps.outputs.node-version }}-modules-${{ hashFiles('package-lock.json') }}
if: ${{ matrix.project != 'skip' }}
- name: Cache e2e-schematics
uses: actions/cache/restore@v4
with:
path: ./dist/libs/sdk/e2e-schematics
key: e2e-schematics-${{ runner.os }}-${{ github.head_ref || github.ref_name || github.event.ref }}
- name: Check if ${{ matrix.project }} is affected
if: ${{ matrix.project != 'skip' }}
uses: ./.github/actions/e2e-affected
Expand All @@ -327,15 +362,15 @@ jobs:
echo '# PERCY_TARGET_COMMIT' $PERCY_TARGET_COMMIT
# Timing setting recommended by https://docs.percy.io/docs/cypress#missing-assets
npx percy exec -t 350 -- nx e2e ${{ matrix.project }} -c ci --no-agents 2>&1 | tee ${{ runner.temp }}/percy-${{ matrix.project }}.log
npx percy exec -t 350 -- nx e2e ${{ matrix.project }} -c ci --no-parallel --runner=local 2>&1 | tee ${{ runner.temp }}/percy-${{ matrix.project }}.log
RESULT=$?
if [ $RESULT -ne 0 ]; then
echo "Percy failed with exit code $RESULT"
RETRY=$(grep -cE '(This is likely a client error|Error: Can only finalize pending builds|Module loop: this module is already being loaded.)' ${{ runner.temp }}/percy-${{ matrix.project }}.log)
if [ $RETRY -gt 0 ]; then
echo "Percy client error. Retrying..."
set -eo pipefail
npx percy exec -t 350 -- nx e2e ${{ matrix.project }} -c ci --no-agents 2>&1 | tee ${{ runner.temp }}/percy-${{ matrix.project }}.log
npx percy exec -t 350 -- nx e2e ${{ matrix.project }} -c ci --no-parallel --runner=local 2>&1 | tee ${{ runner.temp }}/percy-${{ matrix.project }}.log
else
exit 1
fi
Expand Down Expand Up @@ -416,8 +451,11 @@ jobs:
node_modules
/home/runner/.cache/Cypress
key: ${{ runner.os }}-node-${{ needs.install-deps.outputs.node-version }}-modules-${{ hashFiles('package-lock.json') }}
- name: Build e2e-schematics
run: npx nx build e2e-schematics --no-agents
- name: Cache e2e-schematics
uses: actions/cache/restore@v4
with:
path: ./dist/libs/sdk/e2e-schematics
key: e2e-schematics-${{ runner.os }}-${{ github.head_ref || github.ref_name || github.event.ref }}
- name: Download Percy Build Numbers
uses: actions/download-artifact@v4
with:
Expand Down
26 changes: 26 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,31 @@
# Changelog

## [10.43.0](https://github.com/blackbaud/skyux/compare/10.42.0...10.43.0) (2024-09-09)


### Features

* add support for `axe-core@4.10.0` ([#2696](https://github.com/blackbaud/skyux/issues/2696)) ([48855a3](https://github.com/blackbaud/skyux/commit/48855a3ade96984aac2a62e95b1f0b4eac6102e7))


### Bug Fixes

* **components/ag-grid:** improve row selector performance ([#2691](https://github.com/blackbaud/skyux/issues/2691)) ([e1d391b](https://github.com/blackbaud/skyux/commit/e1d391bcf594fd5b03cf9ee189c067801d7d588f))
* **components/lookup:** add required label asterisk for template driven forms ([#2694](https://github.com/blackbaud/skyux/issues/2694)) ([2f25548](https://github.com/blackbaud/skyux/commit/2f25548870a035fb97c12d2667d477f9018c3961))

## [10.42.0](https://github.com/blackbaud/skyux/compare/10.41.5...10.42.0) (2024-09-06)


### Features

* **components/theme:** add support for @skyux/icons@7.8.0 ([#2678](https://github.com/blackbaud/skyux/issues/2678)) ([1997de3](https://github.com/blackbaud/skyux/commit/1997de3beb4b586a66dc78fc47f95c0fea74a885))


### Bug Fixes

* **components/forms:** stop requiring labelText in field group ([#2674](https://github.com/blackbaud/skyux/issues/2674)) ([a245e9a](https://github.com/blackbaud/skyux/commit/a245e9a71a7512ec9503a273c7dce1534c2dcdee))
* **components/icon:** variant input is respected for SVG-based icons ([#2688](https://github.com/blackbaud/skyux/issues/2688)) ([d5681a6](https://github.com/blackbaud/skyux/commit/d5681a627f6da97c1fb1b2b314f3b4ce04dfd187))

## [10.41.5](https://github.com/blackbaud/skyux/compare/10.41.4...10.41.5) (2024-08-26)


Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@
[disabled]="disabled"
>
<sky-lookup
required
formControlName="friends2"
idProperty="id"
[data]="people"
Expand Down Expand Up @@ -105,8 +106,11 @@

<div class="app-screenshot" id="lookup-single-visual">
<form novalidate [formGroup]="bestFriendsForm">
<sky-input-box class="sky-margin-stacked-lg" [disabled]="disabled">
<label class="sky-control-label"> Who is your best friend? </label>
<sky-input-box
class="sky-margin-stacked-lg"
[disabled]="disabled"
labelText="Who is your best friend?"
>
<sky-lookup
formControlName="bestFriend"
idProperty="id"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ import {
UntypedFormBuilder,
UntypedFormControl,
UntypedFormGroup,
Validators,
} from '@angular/forms';
import {
SkyAutocompleteSearchAsyncArgs,
Expand Down Expand Up @@ -177,7 +178,7 @@ export class LookupComponent implements OnInit {
});

this.bestFriendsForm = this.formBuilder.group({
bestFriend: new UntypedFormControl(this.bestFriend),
bestFriend: new UntypedFormControl(this.bestFriend, Validators.required),
bestFriendAsync: undefined,
});
}
Expand Down
7 changes: 1 addition & 6 deletions karma.conf.js
Original file line number Diff line number Diff line change
Expand Up @@ -43,12 +43,7 @@ module.exports = () => {
},
ChromeHeadlessNoSandbox: {
base: 'ChromeHeadless',
flags: [
'--headless',
'--disable-gpu',
'--disable-dev-shm-usage',
'--window-size=1920,1080',
],
flags: ['--headless=new', '--window-size=1920,1080'],
},
},
restartOnFileChange: true,
Expand Down
4 changes: 2 additions & 2 deletions libs/components/a11y/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@
},
"homepage": "https://github.com/blackbaud/skyux#readme",
"peerDependencies": {
"@angular/common": "^17.3.4",
"@angular/core": "^17.3.4",
"@angular/common": "^17.3.12",
"@angular/core": "^17.3.12",
"@skyux/core": "0.0.0-PLACEHOLDER",
"@skyux/i18n": "0.0.0-PLACEHOLDER"
},
Expand Down
Loading

0 comments on commit 1385a46

Please sign in to comment.