Skip to content
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
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@
"dependencies": {
"@base-ui/react": "^1.6.0",
"@douglasneuroinformatics/libjs": "^3.2.1",
"@douglasneuroinformatics/libui-form-types": "^1.1.0",
"@douglasneuroinformatics/libui-form-types": "^1.4.0",
"@radix-ui/react-accordion": "^1.2.3",
"@radix-ui/react-alert-dialog": "^1.1.6",
"@radix-ui/react-avatar": "^1.1.3",
Expand Down
10 changes: 5 additions & 5 deletions pnpm-lock.yaml

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

12 changes: 1 addition & 11 deletions src/components/Form/StringField/StringFieldComboBox.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,17 +11,7 @@ import type { BaseFieldComponentProps } from '../types.ts';
type ComboBoxItem<T extends string> = { label: string; value: T };

export type StringFieldComboBoxProps<T extends string = string> = Simplify<
BaseFieldComponentProps<T> &
Extract<StringFormField<T>, { options: object }> & {
/**
* Whether text that does not match any option may be entered. When enabled, text that does not
* resolve to an option is committed as the value instead of being discarded when the popup
* closes. Note that such a value is not a key of `options`, so the validation schema for this
* field must accept arbitrary strings.
* @default false
*/
allowCustomValue?: boolean;
}
BaseFieldComponentProps<T> & Extract<StringFormField<T>, { variant: 'combobox' }>
>;

export const StringFieldComboBox = <T extends string = string>({
Expand Down
11 changes: 1 addition & 10 deletions src/components/Form/StringField/StringFieldPassword.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -15,16 +15,7 @@ import type { BaseFieldComponentProps } from '../types.ts';
export type PasswordStrengthValue = 0 | 1 | 2 | 3 | 4;

export type StringFieldPasswordProps = BaseFieldComponentProps<string> &
Extract<StringFormField, { variant: 'password' }> & {
/**
* A function used to generate a passphrase for this field. When provided, a button is rendered
* in the input that fills the field with the returned value and reveals it.
*
* Declared here rather than coming from `StringFormField`, and should be removed once the
* form types package publishes it on the password variant.
*/
generatePassword?: (this: void) => string;
};
Extract<StringFormField, { variant: 'password' }>;

export const StringFieldPassword = ({
calculateStrength,
Expand Down
Loading