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

fix: Explicitly omit crossOrigin and placeholder props #812

Merged
merged 3 commits into from
Jan 16, 2024
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 CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,11 @@

Reactist follows [semantic versioning](https://semver.org/) and doesn't introduce breaking changes (API-wise) in minor or patch releases. However, the appearance of a component might change in a minor or patch release so keep an eye on redesigns and make sure your app still looks and feels like you expect it.

# v23.0.0

- [BREAKING] Remove unsupported `crossOrigin` attribute from `input`- and `textarea`-based components.
- [BREAKING] Remove unsupported `placeholder` attribute from heading components.

# v22.3.3

- [Fix] Vertical alignment of inline code elements inside a `Prose` component
Expand Down
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
"email": "[email protected]",
"url": "http://doist.com"
},
"version": "22.3.3",
"version": "23.0.0",
"license": "MIT",
"homepage": "https://github.com/Doist/reactist#readme",
"repository": {
Expand Down
1 change: 1 addition & 0 deletions src/checkbox-field/checkbox-field.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ type CheckboxFieldProps = Omit<
| 'aria-describedby'
| 'aria-label'
| 'aria-labelledby'
| 'crossOrigin'
> & {
'aria-checked'?: never
/** Identifies the set of checkboxes controlled by the mixed checkbox for assistive technologies. */
Expand Down
2 changes: 1 addition & 1 deletion src/heading/heading.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ type HeadingElement = 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6'

type SupportedHeadingElementProps = Omit<
JSX.IntrinsicElements[HeadingElement],
'className' | 'children'
'className' | 'children' | 'placeholder'
>

type HeadingProps = SupportedHeadingElementProps & {
Expand Down
2 changes: 1 addition & 1 deletion src/password-field/password-field.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import { Button } from '../button'

import type { BaseFieldVariantProps } from '../base-field'

type PasswordFieldProps = Omit<TextFieldProps, 'type' | 'startSlot' | 'endSlot'> &
type PasswordFieldProps = Omit<TextFieldProps, 'type' | 'startSlot' | 'endSlot' | 'crossOrigin'> &
BaseFieldVariantProps & {
togglePasswordLabel?: string
}
Expand Down
3 changes: 2 additions & 1 deletion src/select-field/select-field.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@ import { BaseField, BaseFieldVariantProps, FieldComponentProps } from '../base-f
import { Box } from '../box'
import styles from './select-field.module.css'

type SelectFieldProps = FieldComponentProps<HTMLSelectElement> & BaseFieldVariantProps
type SelectFieldProps = Omit<FieldComponentProps<HTMLSelectElement>, 'crossOrigin'> &
BaseFieldVariantProps

const SelectField = React.forwardRef<HTMLSelectElement, SelectFieldProps>(function SelectField(
{
Expand Down
1 change: 1 addition & 0 deletions src/switch-field/switch-field.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ type SwitchFieldProps = Omit<
| 'aria-describedby'
| 'aria-label'
| 'aria-labelledby'
| 'crossOrigin'
> & {
/** Identifies the element (or elements) that describes the switch for assistive technologies. */
'aria-describedby'?: string
Expand Down
2 changes: 1 addition & 1 deletion src/text-area/text-area.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { BaseField, BaseFieldVariantProps, FieldComponentProps } from '../base-f
import { Box } from '../box'
import styles from './text-area.module.css'

type TextAreaProps = FieldComponentProps<HTMLTextAreaElement> &
type TextAreaProps = Omit<FieldComponentProps<HTMLTextAreaElement>, 'crossOrigin'> &
BaseFieldVariantProps & {
/**
* The number of visible text lines for the text area.
Expand Down
2 changes: 1 addition & 1 deletion src/text-field/text-field.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import { useMergeRefs } from 'use-callback-ref'

type TextFieldType = 'email' | 'search' | 'tel' | 'text' | 'url'

type TextFieldProps = Omit<FieldComponentProps<HTMLInputElement>, 'type'> &
type TextFieldProps = Omit<FieldComponentProps<HTMLInputElement>, 'type' | 'crossOrigin'> &
BaseFieldVariantProps & {
type?: TextFieldType
startSlot?: React.ReactChild
Expand Down
Loading