/*!
Copyright (c) 2026 Lenovo SSG BASD. All rights reserved.
@license Proprietary

This software is the confidential and proprietary property of Lenovo SSG BASD.
You shall not disclose such Confidential Information and shall use it only in
accordance with the terms of the license agreement.

--- Build Info ---
Version: 1.1.1
Build Time: 2026/2/26 17:21:00
Build Commit: 81e556ed827e2f043668506dae6fae8dbb9ef395
*/
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});require('./MarkButton.css');const e=require("vue"),i=require("./icons.js"),t=require("../constant/index.js");;/* empty css                 */const o=require("../../../_virtual/_plugin-vue_export-helper.js"),c=["disabled","title"],r=["innerHTML"],n={__name:"MarkButton",props:{type:{type:String,required:!0,validator:e=>t.FONT_SETTINGS.includes(e)},editor:{type:Object,required:!0},disabled:{type:Boolean,default:!1}},setup(t){const o=t,n={bold:{title:"Bold",icon:i.boldIcon,command:()=>o.editor?.chain().focus().toggleBold().run(),isActive:()=>o.editor?.isActive("bold")},italic:{title:"Italic",icon:i.italicIcon,command:()=>o.editor?.chain().focus().toggleItalic().run(),isActive:()=>o.editor?.isActive("italic")},strike:{title:"Strikethrough",icon:i.strikeIcon,command:()=>o.editor?.chain().focus().toggleStrike().run(),isActive:()=>o.editor?.isActive("strike")},code:{title:"Code",icon:i.codeIcon,command:()=>o.editor?.chain().focus().toggleCode().run(),isActive:()=>o.editor?.isActive("code")},underline:{title:"Underline",icon:i.underlineIcon,command:()=>o.editor?.chain().focus().toggleUnderline().run(),isActive:()=>o.editor?.isActive("underline")},superscript:{title:"Superscript",icon:i.superscriptIcon,command:()=>o.editor?.chain().focus().toggleSuperscript().run(),isActive:()=>o.editor?.isActive("superscript")},subscript:{title:"Subscript",icon:i.subscriptIcon,command:()=>o.editor?.chain().focus().toggleSubscript().run(),isActive:()=>o.editor?.isActive("subscript")}},s=e.computed(()=>n[o.type]),l=e.computed(()=>s.value.title),d=e.computed(()=>s.value.icon),u=e.computed(()=>s.value.isActive()),a=()=>{s.value.command()};return(i,o)=>(e.openBlock(),e.createElementBlock("button",{class:e.normalizeClass(["tiptap-button",{"is-active":u.value,"is-disabled":t.disabled}]),disabled:t.disabled,title:l.value,onClick:a},[e.createElementVNode("span",{innerHTML:d.value},null,8,r)],10,c))}},s=o.default(n,[["__scopeId","data-v-a6375281"]]);exports.default=s;