Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Combine Email and Phone fixed Issue for NoticeOnly #12196

Merged
merged 12 commits into from
Feb 5, 2025
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,19 @@ Here's a quick example to get you started.
import '@carbon/ibmdotcom-web-components/es/components/notice-choice/index.js';
```

### JS (via CDN latest code)

```javascript
<script type="module" src="https://www.ibm.com/common/carbon-for-ibm-dotcom/tag/v2/latest/notice-choice.min.js"></script>
```


<Description markdown={`${cdnJs({ components: ['notice-choice'] })}`} />

<Description markdown={`${cdnCss()}`} />



### HTML

```html
Expand All @@ -39,7 +48,6 @@ import '@carbon/ibmdotcom-web-components/es/components/notice-choice/index.js';
state="CA"
terms-condition-link=""
hide-error-message="false"
combine-email-phone="false"
>
</c4d-notice-choice>
```
Expand All @@ -66,7 +74,6 @@ document.addEventListener('cds-notice-choice-change', (event) => {
| language | form based on the country and language | en |
| terms-condition-link | Terms and conditions link appended to the end of the privacy statement - should be specific | |
| hide-error-message | Hide Error Messages for PUNS statement | false |
| combine-email-phone | Combine Email and Phone | false |
| environment | Set environment variable Prod or Stage | Prod |

<Props of="c4d-notice-choice" />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -88,11 +88,6 @@ const hideErrorMessages = {
false: 'false',
};

const combineEmailPhone = {
true: 'true',
false: 'false',
};

const environment = {
Production: 'prod',
Stage: 'stage',
Expand All @@ -119,11 +114,6 @@ const props = () => {
hideErrorMessages,
'false'
),
combineEmailPhone: select(
'Combine Email Phone',
combineEmailPhone,
'false'
),
environment: select('Environment', environment, 'prod'),
};
};
Expand All @@ -141,7 +131,6 @@ export const Default = (args) => {
hiddenPhone,
ncTeleDetail,
ncEmailDetail,
combineEmailPhone,
environment,
} = args?.NoticeChoice ?? {};
return html`
Expand All @@ -157,7 +146,6 @@ export const Default = (args) => {
.hiddenPhone="${hiddenPhone}"
.nc-tele-detail="${ncTeleDetail}"
.nc-email-detail="${ncEmailDetail}"
combine-email-phone="${combineEmailPhone}"
environment="${environment}"
@c4d-notice-choice-change=${onChange}></c4d-notice-choice>
`;
Expand Down
Loading
Loading