-
Notifications
You must be signed in to change notification settings - Fork 17
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
12 changed files
with
172 additions
and
177 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
'@hashicorp/react-marketo-form': minor | ||
--- | ||
|
||
Add support for htmltext fields |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
21 changes: 21 additions & 0 deletions
21
packages/marketo-form/partials/fields/htmltext-field/index.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
/** | ||
* Copyright (c) HashiCorp, Inc. | ||
* SPDX-License-Identifier: MPL-2.0 | ||
*/ | ||
|
||
import FieldWrapper from '../../field-wrapper' | ||
import type { MarketoFormHtmltextField } from '../../../types' | ||
import styles from './style.module.css' | ||
|
||
const Index = ({ field }: { field: MarketoFormHtmltextField }) => { | ||
return ( | ||
<FieldWrapper fieldId={field.id}> | ||
<span | ||
className={styles.htmltext} | ||
dangerouslySetInnerHTML={{ __html: field.text }} | ||
/> | ||
</FieldWrapper> | ||
) | ||
} | ||
|
||
export default Index |
6 changes: 6 additions & 0 deletions
6
packages/marketo-form/partials/fields/htmltext-field/style.module.css
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
.htmltext { | ||
composes: g-type-body-small from global; | ||
color: var(--wpl-neutral-500); | ||
margin-top: var(--wpl-spacing-02); | ||
margin-bottom: var(--wpl-spacing-05); | ||
} |
148 changes: 0 additions & 148 deletions
148
packages/marketo-form/partials/fields/privacy-policy-field/index.tsx
This file was deleted.
Oops, something went wrong.
8 changes: 0 additions & 8 deletions
8
packages/marketo-form/partials/fields/privacy-policy-field/style.module.css
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.