"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.VodDescription = VodDescription;
const jsx_runtime_1 = require("react/jsx-runtime");
const react_native_1 = require("react-native");
const ui_1 = require("../../ui");
const video_store_1 = require("../../video-store/video-store");
const text_1 = require("../ui/text");
function VodDescription() {
    const video = (0, video_store_1.useVideoStore)((x) => x.video);
    const { theme } = (0, ui_1.useTheme)();
    if (!video)
        return null;
    const record = video.record;
    const description = record.description?.trim();
    const tags = record.tags ?? [];
    return ((0, jsx_runtime_1.jsxs)(react_native_1.View, { style: [ui_1.mt[3]], children: [tags.length > 0 ? ((0, jsx_runtime_1.jsx)(react_native_1.ScrollView, { horizontal: true, showsHorizontalScrollIndicator: false, contentContainerStyle: { gap: 6, alignItems: "center" }, style: { marginBottom: 12 }, children: tags.map((tag) => ((0, jsx_runtime_1.jsx)(react_native_1.View, { style: {
                        borderRadius: 999,
                        borderWidth: 1,
                        borderColor: theme.colors.border,
                        backgroundColor: (0, ui_1.hexToRgba)(theme.colors.secondary, 0.3),
                        paddingHorizontal: 8,
                        paddingVertical: 2,
                        flexShrink: 0,
                    }, children: (0, jsx_runtime_1.jsx)(text_1.Text, { size: "xs", color: (0, ui_1.hexToRgba)(theme.colors.primaryForeground, 0.85), children: tag }) }, tag))) })) : null, description ? ((0, jsx_runtime_1.jsx)(text_1.Text, { style: { color: theme.colors.text }, children: description })) : null] }));
}
//# sourceMappingURL=vod-description.js.map