UNPKG

@vrx-arco/pro-components

Version:

<p align="center"> <img src="https://vrx-arco.github.io/arco-design-pro/favicon.svg" width="200" height="250"> </p>

53 lines (52 loc) 1.25 kB
"use strict"; Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" }); const vue = require("vue"); const webVue = require("@arco-design/web-vue"); const _var = require("../style/var.js"); const context = require("./context.js"); const SearchLayout = /* @__PURE__ */ vue.defineComponent({ name: "vrx-arco-search-layout", props: { /** * 布局类型 * card: 整体布局作为一个卡片类型 * normal: 分体式卡片布局 */ type: { type: String, default: "normal" }, /** * 设置标题 */ title: String }, setup: (props, { slots }) => { const { bemClass } = _var.style("search-layout"); const type = vue.toRef(props, "type"); const title = vue.toRef(props, "title"); context.provideSearchLayout({ type, title, bemClass }); return () => { return vue.createVNode(webVue.Layout, { "class": { [bemClass()]: true, [bemClass("--card")]: props.type === "card" } }, { default: () => { var _a; return [(_a = slots.default) == null ? void 0 : _a.call(slots)]; } }); }; } }); exports.SearchLayout = SearchLayout;