Skip to content

Commit

Permalink
(HDS-2419) Remove useless native props
Browse files Browse the repository at this point in the history
  • Loading branch information
mrTuomoK committed Oct 14, 2024
1 parent 26f141c commit 91d3ca6
Show file tree
Hide file tree
Showing 6 changed files with 0 additions and 52 deletions.
4 changes: 0 additions & 4 deletions packages/react/src/components/accordion/Accordion.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -69,10 +69,6 @@ export type CommonAccordionProps = React.PropsWithChildren<{
* @default 2
*/
headingLevel?: number;
/**
* The id for the accordion element
*/
id?: string;
/**
* Boolean indicating whether the accordion is initially opened.
* @default false
Expand Down
4 changes: 0 additions & 4 deletions packages/react/src/components/button/Button.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -64,10 +64,6 @@ export type CommonButtonProps = AllElementPropsWithoutRef<'button'> & {
* @default ButtonTheme.Bus
*/
theme?: ButtonPresetTheme | ButtonTheme;
/**
* If `true`, the button will be disabled
*/
disabled?: boolean;
/**
* If `true`, the button will take up the full width of its container
*/
Expand Down
16 changes: 0 additions & 16 deletions packages/react/src/components/checkbox/Checkbox.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,18 +11,10 @@ import { AllElementPropsWithoutRef, MergeAndOverrideProps } from '../../utils/el
export type CheckboxProps = MergeAndOverrideProps<
AllElementPropsWithoutRef<'input'>,
{
/**
* If `true`, the component is checked
*/
checked?: boolean;
/**
* Additional class names to apply to the checkbox
*/
className?: string;
/**
* If `true`, the checkbox will be disabled
*/
disabled?: boolean;
/**
* The error text content that will be shown below the checkbox
*/
Expand All @@ -43,18 +35,10 @@ export type CheckboxProps = MergeAndOverrideProps<
* The label for the checkbox
*/
label?: string | React.ReactNode;
/**
* Callback fired when the state is changed
*/
onChange?: React.ChangeEventHandler<HTMLInputElement>;
/**
* Override or extend the styles applied to the component
*/
style?: React.CSSProperties;
/**
* The value of the component
*/
value?: string;
/**
* Tooltip text for the checkbox
*/
Expand Down
8 changes: 0 additions & 8 deletions packages/react/src/components/radioButton/RadioButton.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,18 +8,10 @@ import { AllElementPropsWithoutRef, MergeAndOverrideProps } from '../../utils/el
export type RadioButtonProps = MergeAndOverrideProps<
AllElementPropsWithoutRef<'input'>,
{
/**
* If `true`, the component is checked
*/
checked?: boolean;
/**
* Additional class names to apply to the radio button
*/
className?: string;
/**
* If `true`, the radio button will be disabled
*/
disabled?: boolean;
/**
* The helper text content that will be shown below the input
*/
Expand Down
12 changes: 0 additions & 12 deletions packages/react/src/components/textInput/TextInput.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -32,10 +32,6 @@ export type TextInputProps = MergeAndOverrideProps<
* The default input element value. Use when the component is not controlled
*/
defaultValue?: string;
/**
* If `true`, the input will be disabled
*/
disabled?: boolean;
/**
* The error text content that will be shown below the input
*/
Expand Down Expand Up @@ -72,14 +68,6 @@ export type TextInputProps = MergeAndOverrideProps<
* Short hint displayed in the input before the user enters a value
*/
placeholder?: string;
/**
* If `true`, prevents the user from changing the value of the field (not from interacting with the field)
*/
readOnly?: boolean;
/**
* If `true`, the label is displayed as required and the `input` element will be required
*/
required?: boolean;
/**
* Override or extend the styles applied to the component
*/
Expand Down
8 changes: 0 additions & 8 deletions packages/react/src/components/textarea/TextArea.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,6 @@ export type TextAreaProps = MergeAndOverrideProps<
* The default textarea element value. Use when the component is not controlled
*/
defaultValue?: string;
/**
* If `true`, the textarea will be disabled
*/
disabled?: boolean;
/**
* The error text content that will be shown below the textarea
*/
Expand Down Expand Up @@ -53,10 +49,6 @@ export type TextAreaProps = MergeAndOverrideProps<
* Short hint displayed in the textarea before the user enters a value
*/
placeholder?: string;
/**
* If `true`, the label is displayed as required and the `textarea` element will be required
*/
required?: boolean;
/**
* Override or extend the styles applied to the component. See text field [tokens](https://city-of-helsinki.github.io/helsinki-design-system/components/text-field#tokens) for available CSS variables
*/
Expand Down

0 comments on commit 91d3ca6

Please sign in to comment.