@react-types/searchfield 3.0.0-nightly-641446f65-240905

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md ADDED
@@ -0,0 +1,3 @@
1
+ # @react-types/searchfield
2
+
3
+ This package is part of [react-spectrum](https://github.com/adobe/react-spectrum). See the repo for more details.
package/package.json ADDED
@@ -0,0 +1,22 @@
1
+ {
2
+ "name": "@react-types/searchfield",
3
+ "version": "3.0.0-nightly-641446f65-240905",
4
+ "description": "Spectrum UI components in React",
5
+ "license": "Apache-2.0",
6
+ "types": "src/index.d.ts",
7
+ "repository": {
8
+ "type": "git",
9
+ "url": "https://github.com/adobe/react-spectrum"
10
+ },
11
+ "dependencies": {
12
+ "@react-types/shared": "^3.0.0-nightly-641446f65-240905",
13
+ "@react-types/textfield": "^3.0.0-nightly-641446f65-240905"
14
+ },
15
+ "peerDependencies": {
16
+ "react": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0 || ^19.0.0"
17
+ },
18
+ "publishConfig": {
19
+ "access": "public"
20
+ },
21
+ "stableVersion": "3.5.8"
22
+ }
package/src/index.d.ts ADDED
@@ -0,0 +1,25 @@
1
+ /*
2
+ * Copyright 2020 Adobe. All rights reserved.
3
+ * This file is licensed to you under the Apache License, Version 2.0 (the "License");
4
+ * you may not use this file except in compliance with the License. You may obtain a copy
5
+ * of the License at http://www.apache.org/licenses/LICENSE-2.0
6
+ *
7
+ * Unless required by applicable law or agreed to in writing, software distributed under
8
+ * the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS
9
+ * OF ANY KIND, either express or implied. See the License for the specific language
10
+ * governing permissions and limitations under the License.
11
+ */
12
+
13
+ import {AriaTextFieldProps, SpectrumTextFieldProps, TextFieldProps} from '@react-types/textfield';
14
+ import {SpectrumTextInputBase} from '@react-types/shared';
15
+
16
+ export interface SearchFieldProps extends TextFieldProps {
17
+ /** Handler that is called when the SearchField is submitted. */
18
+ onSubmit?: (value: string) => void,
19
+
20
+ /** Handler that is called when the clear button is pressed. */
21
+ onClear?: () => void
22
+ }
23
+
24
+ export interface AriaSearchFieldProps extends SearchFieldProps, AriaTextFieldProps {}
25
+ export interface SpectrumSearchFieldProps extends SpectrumTextInputBase, Omit<AriaSearchFieldProps, 'isInvalid' | 'validationState'>, SpectrumTextFieldProps {}