Skip to content

Commit

Permalink
Merge branch 'dev' into task/5589_reactAuthWorkflow_versionUpdate
Browse files Browse the repository at this point in the history
  • Loading branch information
priyankakmEaton committed May 8, 2024
2 parents 27ee219 + 23fdc0c commit 56c1833
Show file tree
Hide file tree
Showing 9 changed files with 294 additions and 442 deletions.
8 changes: 4 additions & 4 deletions .github/workflows/blui-ci.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: CI Run
name: Build

on:
push:
Expand Down Expand Up @@ -54,7 +54,7 @@ jobs:
node-version: ${{ matrix.node-version }}
cache: 'yarn'
cache-dependency-path: login-workflow
- run: yarn --frozen-lockfile
- run: yarn --immutable
working-directory: login-workflow
- run: yarn test:ci --coverage --watchAll=false
working-directory: login-workflow
Expand Down Expand Up @@ -82,7 +82,7 @@ jobs:
node-version: ${{ matrix.node-version }}
cache: 'yarn'
cache-dependency-path: login-workflow
- run: yarn --frozen-lockfile
- run: yarn --immutable
working-directory: login-workflow
- run: yarn build
working-directory: login-workflow
Expand Down Expand Up @@ -115,6 +115,6 @@ jobs:
node-version: ${{ matrix.node-version }}
registry-url: 'https://registry.npmjs.org'
cache-dependency-path: login-workflow
- run: yarn --frozen-lockfile
- run: yarn --immutable
- run: npm run publish:package -b ${{env.BRANCH}}
working-directory: login-workflow
4 changes: 2 additions & 2 deletions login-workflow/PUBLISHING.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

## Automatic Publishing

This package is published to NPM automatically by CircleCI when code is merged into the `dev` or `master` branches. To publish a new version, simply update the version in `package.json` and merge your code into the appropriate branch.
This package is published to NPM automatically by Github when code is merged into the `dev` or `master` branches. To publish a new version, simply update the version in `package.json` and merge your code into the appropriate branch.
- The `dev` branch will publish versions marked as `alpha` or `beta`.
- The `master` branch will publish any version (`alpha`, `beta`, or `latest`).
In both cases, the code will only be published if the version number differs from the current version published under the respective dist tag.
Expand All @@ -27,4 +27,4 @@ yarn build
npm adduser && yarn publish:package
```

> Publishing manually should only be done for `alpha` or `beta` packages. The command will work for `latest` packages, but this should be avoided except in rare situations where the automatic publishing functionality is not working in CircleCI.
> Publishing manually should only be done for `alpha` or `beta` packages. The command will work for `latest` packages, but this should be avoided except in rare situations where the automatic publishing functionality is not working in Github.
2 changes: 1 addition & 1 deletion login-workflow/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Test React Auth Workflow

[![](https://img.shields.io/circleci/project/github/etn-ccis/blui-react-workflows/master.svg?style=flat)](https://circleci.com/gh/etn-ccis/blui-react-workflows/tree/master) ![npm (scoped)](https://img.shields.io/npm/v/@brightlayer-ui/react-auth-workflow) [![codecov](https://codecov.io/gh/etn-ccis/blui-react-workflows/branch/master/graph/badge.svg?token=H18T75WBFS)](https://codecov.io/gh/etn-ccis/blui-react-workflows)
[![Build](https://github.com/etn-ccis/blui-react-workflows/actions/workflows/blui-ci.yml/badge.svg?branch=master)](https://github.com/etn-ccis/blui-react-workflows/actions/workflows/blui-ci.yml) ![npm (scoped)](https://img.shields.io/npm/v/@brightlayer-ui/react-auth-workflow) [![codecov](https://codecov.io/gh/etn-ccis/blui-react-workflows/branch/master/graph/badge.svg?token=H18T75WBFS)](https://codecov.io/gh/etn-ccis/blui-react-workflows)

The React Auth Workflow package provides a consistent UI implementation of authentication-related capabilities for use in Eaton web applications built with React.

Expand Down
31 changes: 20 additions & 11 deletions login-workflow/docs/screens/eula.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,14 +18,23 @@ import { RegistrationContextProvider, EulaScreen } from '@brightlayer-ui/react-a

## API

| Prop Name | Type | Description | Default |
|---|---|---|---|
| eulaContent | `string \| JSX.Element` | The content to render for the EULA. Can be a plain string or HTML. | `t('bluiAuth:EULA.EULA_CONTENT')` |
| checkboxLabel | `string` | The text to render for the acceptance checkbox. | `t('bluiAuth:EULA.ACCEPT_EULA')` |
| checkboxProps | `CheckboxProps` | Props to spread to the MUI [Checkbox](https://mui.com/material-ui/api/checkbox/) component | |
| html | `boolean` | True if the EULA should be rendered as HTML, false for plain text | `false` |
| initialCheckboxValue | `boolean` | Used to pre-populate the checked/unchecked checkbox when the screen loads. | `false` |
| onEulaAcceptedChange | `(accepted: boolean) => void` | Called when the acceptance checkbox clicked. | |
| errorDisplayConfig | `ErrorManagerProps` | See [Error Management](../error-management.md) | |

This screen also extends the `WorkflowCardProps` type for updating the title, instructions, buttons, etc. See [Workflow Card](../components/workflow-card.md) for more details.
| Prop Name | Type | Description | Default |
| -------------------- | ----------------------------- | ------------------------------------------------------------------------------------------ | --------------------------------- |
| eulaContent | `string \| JSX.Element` | The content to render for the EULA. Can be a plain string or HTML. | `t('bluiAuth:EULA.EULA_CONTENT')` |
| checkboxLabel | `string` | The text to render for the acceptance checkbox. | `t('bluiAuth:EULA.ACCEPT_EULA')` |
| checkboxProps | `CheckboxProps` | Props to spread to the MUI [Checkbox](https://mui.com/material-ui/api/checkbox/) component | |
| html | `boolean` | True if the EULA should be rendered as HTML, false for plain text | `false` |
| initialCheckboxValue | `boolean` | Used to pre-populate the checked/unchecked checkbox when the screen loads. | `false` |
| onEulaAcceptedChange | `(accepted: boolean) => void` | Called when the acceptance checkbox clicked. | |
| errorDisplayConfig | `ErrorManagerProps` | See [Error Management](../error-management.md) | |
| refreshConfig | `RefreshConfigProps` | configuration for refresh screen | |

This screen also extends the `WorkflowCardProps` type for updating the title, instructions, buttons, etc. See [Workflow Card](../components/workflow-card.md) for more details.

### RefreshConfigProps

| Prop Name | Type | Description | Default |
| ------------------ | ------------ | --------------------------------- | ------------------------------------------- |
| onRefresh | `() => void` | Function to refresh Eula content | |
| refreshButtonLabel | `string` | Label of refresh button | `t('bluiCommon:MESSAGES.RETRY') // "Retry"` |
| showRefreshButton | `boolean` | the refresh button to be rendered | |
37 changes: 31 additions & 6 deletions login-workflow/example-vite/yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -4943,9 +4943,9 @@ [email protected]:
integrity sha512-WMwm9LhRUo+WUaRN+vRuETqG89IgZphVSNkdFgeb6sS/E4OrDIN7t48CAewSHXc6C8lefD8KKfr5vY61brQlow==

ejs@^3.1.6:
version "3.1.9"
resolved "https://registry.yarnpkg.com/ejs/-/ejs-3.1.9.tgz#03c9e8777fe12686a9effcef22303ca3d8eeb361"
integrity sha512-rC+QVNMJWv+MtPgkt0y+0rVEIdbtxVADApW9JXrUVlzHetgcyczP/E7DJmWJ4fJCZF2cPcBk0laWO9ZHMG3DmQ==
version "3.1.10"
resolved "https://registry.yarnpkg.com/ejs/-/ejs-3.1.10.tgz#69ab8358b14e896f80cc39e62087b88500c3ac3b"
integrity sha512-UeJmFfOrAQS8OJWPZ4qtgHyWExa088/MtK5UEyoJGFH67cDEXkZSviOiKRCZ4Xij0zxI3JECgYs3oKx+AizQBA==
dependencies:
jake "^10.8.5"

Expand Down Expand Up @@ -10130,7 +10130,16 @@ string-natural-compare@^3.0.1:
resolved "https://registry.yarnpkg.com/string-natural-compare/-/string-natural-compare-3.0.1.tgz#7a42d58474454963759e8e8b7ae63d71c1e7fdf4"
integrity sha512-n3sPwynL1nwKi3WJ6AIsClwBMa0zTi54fn2oLU6ndfTSIO05xaznjSf15PcBZU6FNWbmN5Q6cxT4V5hGvB4taw==

"string-width-cjs@npm:string-width@^4.2.0", string-width@^4.1.0, string-width@^4.2.0, string-width@^4.2.3:
"string-width-cjs@npm:string-width@^4.2.0":
version "4.2.3"
resolved "https://registry.yarnpkg.com/string-width/-/string-width-4.2.3.tgz#269c7117d27b05ad2e536830a8ec895ef9c6d010"
integrity sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==
dependencies:
emoji-regex "^8.0.0"
is-fullwidth-code-point "^3.0.0"
strip-ansi "^6.0.1"

string-width@^4.1.0, string-width@^4.2.0, string-width@^4.2.3:
version "4.2.3"
resolved "https://registry.yarnpkg.com/string-width/-/string-width-4.2.3.tgz#269c7117d27b05ad2e536830a8ec895ef9c6d010"
integrity sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==
Expand Down Expand Up @@ -10213,7 +10222,14 @@ stringify-object@^3.3.0:
is-obj "^1.0.1"
is-regexp "^1.0.0"

"strip-ansi-cjs@npm:strip-ansi@^6.0.1", strip-ansi@^6.0.0, strip-ansi@^6.0.1:
"strip-ansi-cjs@npm:strip-ansi@^6.0.1":
version "6.0.1"
resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-6.0.1.tgz#9e26c63d30f53443e9489495b2105d37b67a85d9"
integrity sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==
dependencies:
ansi-regex "^5.0.1"

strip-ansi@^6.0.0, strip-ansi@^6.0.1:
version "6.0.1"
resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-6.0.1.tgz#9e26c63d30f53443e9489495b2105d37b67a85d9"
integrity sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==
Expand Down Expand Up @@ -11293,7 +11309,16 @@ [email protected]:
"@types/trusted-types" "^2.0.2"
workbox-core "6.6.1"

"wrap-ansi-cjs@npm:wrap-ansi@^7.0.0", wrap-ansi@^7.0.0:
"wrap-ansi-cjs@npm:wrap-ansi@^7.0.0":
version "7.0.0"
resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-7.0.0.tgz#67e145cff510a6a6984bdf1152911d69d2eb9e43"
integrity sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q==
dependencies:
ansi-styles "^4.0.0"
string-width "^4.1.0"
strip-ansi "^6.0.0"

wrap-ansi@^7.0.0:
version "7.0.0"
resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-7.0.0.tgz#67e145cff510a6a6984bdf1152911d69d2eb9e43"
integrity sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q==
Expand Down
2 changes: 1 addition & 1 deletion login-workflow/example/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@
"@types/node": "^17.0.23",
"@types/react": "^18.0.31",
"@types/react-dom": "^18.0.0",
"date-fns": "^3.0.6",
"date-fns": "^3.6.0",
"i18next": "^23.7.13",
"react": "^18.2.0",
"react-app-polyfill": "^3.0.0",
Expand Down
14 changes: 7 additions & 7 deletions login-workflow/example/yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -4312,10 +4312,10 @@ data-urls@^2.0.0:
whatwg-mimetype "^2.3.0"
whatwg-url "^8.0.0"

date-fns@^3.0.6:
version "3.0.6"
resolved "https://registry.yarnpkg.com/date-fns/-/date-fns-3.0.6.tgz#fe3aeb7592d359f075ffc41cb16139828810ca83"
integrity sha512-W+G99rycpKMMF2/YD064b2lE7jJGUe+EjOES7Q8BIGY8sbNdbgcs9XFTZwvzc9Jx1f3k7LB7gZaZa7f8Agzljg==
date-fns@^3.6.0:
version "3.6.0"
resolved "https://registry.yarnpkg.com/date-fns/-/date-fns-3.6.0.tgz#f20ca4fe94f8b754951b24240676e8618c0206bf"
integrity sha512-fRHTG8g/Gif+kSh50gaGEdToemgfj74aRX3swtiouboip5JDLAyDE9F11nHMIcvOaXeOC6D7SpNhi7uFyB7Uww==

[email protected], debug@^2.6.0:
version "2.6.9"
Expand Down Expand Up @@ -4605,9 +4605,9 @@ [email protected]:
integrity sha512-WMwm9LhRUo+WUaRN+vRuETqG89IgZphVSNkdFgeb6sS/E4OrDIN7t48CAewSHXc6C8lefD8KKfr5vY61brQlow==

ejs@^3.1.6:
version "3.1.9"
resolved "https://registry.yarnpkg.com/ejs/-/ejs-3.1.9.tgz#03c9e8777fe12686a9effcef22303ca3d8eeb361"
integrity sha512-rC+QVNMJWv+MtPgkt0y+0rVEIdbtxVADApW9JXrUVlzHetgcyczP/E7DJmWJ4fJCZF2cPcBk0laWO9ZHMG3DmQ==
version "3.1.10"
resolved "https://registry.yarnpkg.com/ejs/-/ejs-3.1.10.tgz#69ab8358b14e896f80cc39e62087b88500c3ac3b"
integrity sha512-UeJmFfOrAQS8OJWPZ4qtgHyWExa088/MtK5UEyoJGFH67cDEXkZSviOiKRCZ4Xij0zxI3JECgYs3oKx+AizQBA==
dependencies:
jake "^10.8.5"

Expand Down
2 changes: 1 addition & 1 deletion login-workflow/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@
"eslint-config-prettier": "^8.3.0",
"eslint-plugin-react": "^7.29.4",
"eslint-plugin-react-hooks": "^4.4.0",
"firebase-tools": "^11.0.1",
"firebase-tools": "^13.6.0",
"i18next": "^23.2.6",
"identity-obj-proxy": "^3.0.0",
"jest": "^29.3.1",
Expand Down
Loading

0 comments on commit 56c1833

Please sign in to comment.