"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.PresenceBadgeTest = void 0;
const tslib_1 = require("tslib");
const react_1 = tslib_1.__importStar(require("react"));
const react_native_1 = require("react-native");
const react_native_2 = require("@fluentui/react-native");
const badge_1 = require("@fluentui-react-native/badge");
const StyledPicker_1 = require("../Common/StyledPicker");
const badgeSizes = [...badge_1.BadgeSizes];
const PresenceBadgeTest = () => {
    const [size, setSize] = (0, react_1.useState)('medium');
    const [outOfOffice, setOutOfOffice] = (0, react_1.useState)(false);
    const svgIconsEnabled = ['ios', 'macos', 'win32', 'android'].includes(react_native_1.Platform.OS);
    const onSizeChange = (0, react_1.useCallback)((value) => setSize(value), []);
    return (react_1.default.createElement(react_native_1.View, null,
        react_1.default.createElement(StyledPicker_1.StyledPicker, { prompt: "Size", selected: size, onChange: onSizeChange, collection: badgeSizes }),
        react_1.default.createElement(react_native_2.ToggleButton, { onClick: () => setOutOfOffice(!outOfOffice), checked: outOfOffice },
            "Set ",
            outOfOffice ? ' In office' : ' Out of office'),
        svgIconsEnabled && (react_1.default.createElement(react_1.default.Fragment, null,
            react_1.default.createElement(react_native_1.Text, null, "Presence Badge"),
            react_1.default.createElement(react_native_1.View, { style: { flexDirection: 'row', marginEnd: 8 } },
                react_1.default.createElement(badge_1.PresenceBadge, { status: "available", size: size, outOfOffice: outOfOffice }),
                react_1.default.createElement(badge_1.PresenceBadge, { status: "blocked", size: size, outOfOffice: outOfOffice }),
                react_1.default.createElement(badge_1.PresenceBadge, { status: "doNotDisturb", size: size, outOfOffice: outOfOffice }),
                react_1.default.createElement(badge_1.PresenceBadge, { status: "away", size: size, outOfOffice: outOfOffice }),
                react_1.default.createElement(badge_1.PresenceBadge, { status: "busy", size: size, outOfOffice: outOfOffice }),
                react_1.default.createElement(badge_1.PresenceBadge, { status: "offline", size: size, outOfOffice: outOfOffice }),
                react_1.default.createElement(badge_1.PresenceBadge, { status: "outOfOffice", size: size, outOfOffice: outOfOffice }),
                react_1.default.createElement(badge_1.PresenceBadge, { status: "unknown", size: size, outOfOffice: outOfOffice }))))));
};
exports.PresenceBadgeTest = PresenceBadgeTest;
//# sourceMappingURL=PresenceBadgeTest.js.map