"use strict";
Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
require("../../../../node_modules/.pnpm/vue@3.3.4/node_modules/vue/dist/vue.runtime.esm-bundler.js");
require("./SettingItem.vue.js");
const SettingItemBox = require("./SettingItemBox.vue.js");
require("../../../../node_modules/.pnpm/vue3-lazyload@0.2.5-beta_a6dezdz3je235ci4e3tu4rayna/node_modules/vue3-lazyload/dist/vue3-lazyload.esm.js");
require("../../../../node_modules/.pnpm/screenfull@6.0.2/node_modules/screenfull/index.js");
require("../../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/_root.js");
require("../../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/_baseGetTag.js");
require("../../../../node_modules/.pnpm/html2canvas@1.4.1/node_modules/html2canvas/dist/html2canvas.esm.js");
require("../../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/_baseClone.js");
require("../../../../node_modules/.pnpm/crypto-js@4.1.1/node_modules/crypto-js/index.js");
require("../../../enums/pageEnum.js");
require("../../../router/index.js");
require("../../../store/modules/designStore/designStore.js");
require("../../../settings/designSetting.js");
require("../../GoLoading/index.js");
require("../../GoSkeleton/index.vue.js");
require("../../../store/modules/chartEditStore/chartEditStore.js");
require("./StylesSetting.vue.js");
const runtimeCore_esmBundler = require("../../../../node_modules/.pnpm/@vue_runtime-core@3.3.4/node_modules/@vue/runtime-core/dist/runtime-core.esm-bundler.js");
const reactivity_esmBundler = require("../../../../node_modules/.pnpm/@vue_reactivity@3.3.4/node_modules/@vue/reactivity/dist/reactivity.esm-bundler.js");
const _sfc_main = /* @__PURE__ */ runtimeCore_esmBundler.defineComponent({
  __name: "NameSetting",
  props: {
    chartConfig: {
      type: Object,
      required: true
    }
  },
  setup(__props) {
    const props = __props;
    let valueCatch = "";
    const handleFocus = () => {
      valueCatch = props.chartConfig.title;
    };
    const handleBlur = () => {
      if (!props.chartConfig.title.length) {
        window["$message"].warning("请输入至少一个字符!");
        props.chartConfig.title = valueCatch;
      }
    };
    return (_ctx, _cache) => {
      const _component_n_input = runtimeCore_esmBundler.resolveComponent("n-input");
      return runtimeCore_esmBundler.openBlock(), runtimeCore_esmBundler.createBlock(reactivity_esmBundler.unref(SettingItemBox.default), {
        name: "名称",
        alone: true
      }, {
        default: runtimeCore_esmBundler.withCtx(() => [
          runtimeCore_esmBundler.createVNode(_component_n_input, {
            type: "text",
            maxlength: "12",
            minlength: "1",
            placeholder: "请输入图表名称",
            size: "small",
            clearable: "",
            "show-count": "",
            value: __props.chartConfig.title,
            "onUpdate:value": _cache[0] || (_cache[0] = ($event) => __props.chartConfig.title = $event),
            onFocus: handleFocus,
            onBlur: handleBlur
          }, null, 8, ["value"])
        ]),
        _: 1
      });
    };
  }
});
exports.default = _sfc_main;
