"use strict";
var __webpack_require__ = {};
(()=>{
    __webpack_require__.n = (module)=>{
        var getter = module && module.__esModule ? ()=>module['default'] : ()=>module;
        __webpack_require__.d(getter, {
            a: getter
        });
        return getter;
    };
})();
(()=>{
    __webpack_require__.d = (exports1, definition)=>{
        for(var key in definition)if (__webpack_require__.o(definition, key) && !__webpack_require__.o(exports1, key)) Object.defineProperty(exports1, key, {
            enumerable: true,
            get: definition[key]
        });
    };
})();
(()=>{
    __webpack_require__.o = (obj, prop)=>Object.prototype.hasOwnProperty.call(obj, prop);
})();
(()=>{
    __webpack_require__.r = (exports1)=>{
        if ("u" > typeof Symbol && Symbol.toStringTag) Object.defineProperty(exports1, Symbol.toStringTag, {
            value: 'Module'
        });
        Object.defineProperty(exports1, '__esModule', {
            value: true
        });
    };
})();
var __webpack_exports__ = {};
__webpack_require__.r(__webpack_exports__);
__webpack_require__.d(__webpack_exports__, {
    renderGeneratedMarkdownContent: ()=>renderGeneratedMarkdownContent
});
const external_dompurify_namespaceObject = require("dompurify");
var external_dompurify_default = /*#__PURE__*/ __webpack_require__.n(external_dompurify_namespaceObject);
const external_lit_namespaceObject = require("lit");
const unsafe_html_js_namespaceObject = require("lit/directives/unsafe-html.js");
require("../../atomic-generated-answer-inline-link/atomic-generated-answer-inline-link.cjs");
const external_markdown_utils_cjs_namespaceObject = require("./markdown-utils.cjs");
const renderGeneratedMarkdownContent = ({ props })=>{
    const answerAsHtml = external_dompurify_default().sanitize((0, external_markdown_utils_cjs_namespaceObject.transformMarkdownToHtml)(props.answer ?? ''), {
        ADD_ATTR: [
            'part'
        ],
        CUSTOM_ELEMENT_HANDLING: {
            tagNameCheck: /^atomic-generated-answer-inline-link$/,
            attributeNameCheck: /^(href|title|exportparts)$/
        }
    });
    return (0, external_lit_namespaceObject.html)`
    <div
      part="generated-text"
      class="text-on-background mb-0 ${props.isStreaming ? 'cursor' : ''}"
    >
      ${(0, unsafe_html_js_namespaceObject.unsafeHTML)(answerAsHtml)}
    </div>
  `;
};
exports.renderGeneratedMarkdownContent = __webpack_exports__.renderGeneratedMarkdownContent;
for(var __rspack_i in __webpack_exports__)if (-1 === [
    "renderGeneratedMarkdownContent"
].indexOf(__rspack_i)) exports[__rspack_i] = __webpack_exports__[__rspack_i];
Object.defineProperty(exports, '__esModule', {
    value: true
});
