decord/source/design/components/TextInput/native/TextInput.native.tsx

49 lines
1.8 KiB
TypeScript
Raw Normal View History

// Module ID: 6606
// Function ID: 6607
2026-07-20 16:05:17 +00:00
// Name: TextInput
// Dependencies: [109, 19, 21, 4278, 6607, 6613, 6608, 2]
2026-07-20 16:05:17 +00:00
// Module 6606 (TextInput)
import useFieldLabelA11yNative from "useFieldLabelA11yNative" /* 4278 */;
import Input from "Input" /* 6607 */;
import getRequiredFieldA11yName from "getRequiredFieldA11yName" /* 6608 */;
import TextField from "TextField" /* 6613 */;
2026-08-27 16:17:25 +00:00
import closure_3 from "_objectWithoutProperties" /* 109 */;
2026-08-24 06:08:38 +00:00
import { jsx } from "jsxProd" /* 21 */;
2026-08-27 16:17:25 +00:00
import importAllResult from "noop" /* 19 */;
2026-07-20 16:05:17 +00:00
2026-08-24 06:08:38 +00:00
require = arg1;
let closure_2 = ["labelId", "accessibilityLabel"];
2026-08-27 16:17:25 +00:00
const forwardRefResult = importAllResult.forwardRef((status, ref) => {
status = status.status;
({ errorMessage, required } = status);
2026-08-27 16:17:25 +00:00
let obj = useFieldLabelA11yNative;
const fieldLabelA11yNative = obj.useFieldLabelA11yNative(status);
const accessibilityLabel = fieldLabelA11yNative.accessibilityLabel;
2026-07-29 08:29:29 +00:00
if (status == null) {
2026-07-21 22:01:30 +00:00
let str;
if (null != errorMessage) {
2026-07-21 22:01:30 +00:00
str = "error";
2026-07-20 16:05:17 +00:00
}
2026-07-21 22:01:30 +00:00
status = str;
2026-07-20 16:05:17 +00:00
}
2026-08-27 16:17:25 +00:00
obj = {};
const merged = Object.assign(status);
obj.labelId = fieldLabelA11yNative.labelId;
2026-07-20 16:05:17 +00:00
obj = { ref };
2026-08-27 16:17:25 +00:00
const merged1 = Object.assign(status);
2026-07-29 08:29:29 +00:00
obj.status = status;
2026-08-27 16:17:25 +00:00
const merged2 = Object.assign(callback(fieldLabelA11yNative, closure_2));
const tmp4 = callback(fieldLabelA11yNative, closure_2);
let requiredFieldA11yName = getRequiredFieldA11yName.getRequiredFieldA11yName(accessibilityLabel, required);
if (requiredFieldA11yName == null) {
requiredFieldA11yName = accessibilityLabel;
}
obj.accessibilityLabel = requiredFieldA11yName;
2026-08-24 06:08:38 +00:00
obj.children = jsx(TextField.TextField, { ref });
return jsx(Input.Input, { ref });
2026-07-20 16:05:17 +00:00
});
2026-08-24 06:08:38 +00:00
const result = require("set").fileFinishedImporting("design/components/TextInput/native/TextInput.native.tsx");
2026-07-23 10:11:24 +00:00
export const TextInput = forwardRefResult;