decord/source/design/components/Button/native/IconButton.native.tsx

66 lines
2.4 KiB
TypeScript
Raw Normal View History

// Module ID: 8097
// Function ID: 8098
2026-07-20 16:05:17 +00:00
// Name: IconButton
// Dependencies: [19, 21, 4560, 576, 4983, 8098, 4556, 2]
2026-07-20 16:05:17 +00:00
// Module 8097 (IconButton)
import ThemesDefault from "Themes" /* 576 */;
import Text from "Text" /* 4556 */;
import BaseButton from "BaseButton" /* 4983 */;
import BaseIconButton from "BaseIconButton" /* 8098 */;
2026-08-24 06:08:38 +00:00
import jsxProd from "jsxProd" /* 21 */;
import createCacheKey from "createCacheKey" /* 4560 */;
2026-08-24 06:08:38 +00:00
import importAllResult from "noop" /* 19 */;
2026-07-23 10:11:24 +00:00
2026-08-24 06:08:38 +00:00
require = arg1;
2026-07-29 08:29:29 +00:00
({ jsx: c3, jsxs: c4 } = jsxProd);
let closure_5 = createCacheKey.createStyles((arg0) => {
2026-08-24 06:08:38 +00:00
const labelPressable = { paddingBottom: ThemesDefault.space.PX_4, gap: ThemesDefault.space.PX_8, alignItems: "center", alignSelf: "center", flexGrow: null };
2026-07-20 16:05:17 +00:00
let num = 0;
if (arg0) {
num = 1;
}
2026-07-29 08:29:29 +00:00
labelPressable[4] = num;
return { labelPressable, label: { textAlign: "center" } };
2026-07-20 16:05:17 +00:00
});
2026-08-24 06:08:38 +00:00
const forwardRefResult = importAllResult.forwardRef((grow) => {
2026-07-20 16:05:17 +00:00
({ label, accessibilityLabel, maxFontSizeMultiplier, accessibilityHint } = grow);
2026-07-29 08:29:29 +00:00
const merged = Object.assign(grow, Object.create(null));
const tmp2 = callback3(grow.grow);
2026-07-20 16:05:17 +00:00
if (null != label) {
2026-07-29 08:29:29 +00:00
let obj = { style: null };
obj[0] = tmp2.labelPressable;
2026-07-20 16:05:17 +00:00
const merged1 = Object.assign(merged);
2026-07-29 08:29:29 +00:00
obj.variant = "none";
obj.accessibilityLabel = accessibilityLabel;
obj.accessibilityHint = accessibilityHint;
obj = { ref: null };
obj[0] = arg1;
2026-07-20 16:05:17 +00:00
const merged2 = Object.assign(merged);
2026-07-29 08:29:29 +00:00
obj.accessibilityRole = "none";
obj.accessibilityLabel = "";
obj.size = "lg";
obj.maxFontSizeMultiplier = maxFontSizeMultiplier;
2026-08-24 06:08:38 +00:00
const items = [callback(BaseIconButton.BaseIconButton, obj), ];
obj1 = { style: null, variant: "text-xs/medium", color: "interactive-text-default", maxFontSizeMultiplier: null, children: null };
2026-07-29 08:29:29 +00:00
obj1[0] = tmp2.label;
obj1[3] = maxFontSizeMultiplier;
obj1[4] = label;
2026-08-24 06:08:38 +00:00
items[1] = callback(Text.Text, obj1);
2026-07-29 08:29:29 +00:00
obj.children = items;
2026-08-24 06:08:38 +00:00
let tmp9 = callback2(BaseButton.BaseButton, obj);
2026-07-20 16:05:17 +00:00
} else {
2026-07-29 08:29:29 +00:00
obj = { ref: null };
obj[0] = arg1;
2026-07-20 16:05:17 +00:00
const merged3 = Object.assign(merged);
2026-07-29 08:29:29 +00:00
obj.accessibilityLabel = accessibilityLabel;
obj.accessibilityHint = accessibilityHint;
obj.maxFontSizeMultiplier = maxFontSizeMultiplier;
2026-08-24 06:08:38 +00:00
tmp9 = callback(BaseIconButton.BaseIconButton, obj);
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
return tmp9;
2026-07-20 16:05:17 +00:00
});
2026-08-24 06:08:38 +00:00
const result = require("set").fileFinishedImporting("design/components/Button/native/IconButton.native.tsx");
2026-07-20 16:05:17 +00:00
export const IconButton = forwardRefResult;