| 12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838 |
- var se = (e, t, n) => new Promise((a, l) => {
- var u = (S) => {
- try {
- s(n.next(S));
- } catch (d) {
- l(d);
- }
- }, f = (S) => {
- try {
- s(n.throw(S));
- } catch (d) {
- l(d);
- }
- }, s = (S) => S.done ? a(S.value) : Promise.resolve(S.value).then(u, f);
- s((n = n.apply(e, t)).next());
- });
- import { defineComponent as q, computed as H, createVNode as o, isVNode as je, inject as rt, ref as j, provide as st, toRef as Me, watch as Ue, resolveComponent as Re, openBlock as P, createBlock as k, withCtx as B, createElementBlock as U, Fragment as be, renderList as Se, normalizeStyle as ct, unref as de, resolveDynamicComponent as qe, createTextVNode as ve, toDisplayString as _, onMounted as dt, createElementVNode as G, createCommentVNode as ye, normalizeClass as We } from "vue";
- import { useRouter as ut } from "vue-router";
- import { g as Le, m as Je, d as b, r as Xe, aH as xe, t as Qe, u as J, c as oe, _ as W, i as Ce, o as Oe, dp as pe, aN as _e, h as gt, dq as mt, bb as pt, dr as Ye, P as X, bQ as Pe, dd as le, F as vt, ds as ft, cv as ht, dt as yt, bs as Ge, cO as bt, ao as Ze, e as $e, ax as Ve, av as St, aw as Be, l as $t, b as xt, bo as Ct, L as It, aL as At, aM as Et, a3 as Tt, du as wt, bD as zt, bg as Pt, cU as ke, B as Ke, bE as Bt, f as ce, ay as Mt, K as Rt, ad as Dt, dv as ue, dw as Lt, n as Ot, C as _t, dx as Ht, dy as Nt, dz as jt, dA as Wt, dB as Gt, dC as Vt } from "./index2.js";
- import { T as He, _ as kt } from "./index11.js";
- import { u as Ie, E as Ne, s as Ae, S as V, a as et } from "./Skeleton.js";
- import { _ as Ft } from "./index5.js";
- import { A as Ut } from "./ActionButton.js";
- import { C as qt, A as Jt } from "./Col.js";
- import { T as Xt } from "./index13.js";
- const Qt = (e) => {
- const {
- antCls: t,
- componentCls: n,
- cardHeadHeight: a,
- cardPaddingBase: l,
- cardHeadTabsMarginBottom: u
- } = e;
- return b(b({
- display: "flex",
- justifyContent: "center",
- flexDirection: "column",
- minHeight: a,
- marginBottom: -1,
- padding: `0 ${l}px`,
- color: e.colorTextHeading,
- fontWeight: e.fontWeightStrong,
- fontSize: e.fontSizeLG,
- background: "transparent",
- borderBottom: `${e.lineWidth}px ${e.lineType} ${e.colorBorderSecondary}`,
- borderRadius: `${e.borderRadiusLG}px ${e.borderRadiusLG}px 0 0`
- }, xe()), {
- "&-wrapper": {
- width: "100%",
- display: "flex",
- alignItems: "center"
- },
- "&-title": b(b({
- display: "inline-block",
- flex: 1
- }, Qe), {
- [`
- > ${n}-typography,
- > ${n}-typography-edit-content
- `]: {
- insetInlineStart: 0,
- marginTop: 0,
- marginBottom: 0
- }
- }),
- [`${t}-tabs-top`]: {
- clear: "both",
- marginBottom: u,
- color: e.colorText,
- fontWeight: "normal",
- fontSize: e.fontSize,
- "&-bar": {
- borderBottom: `${e.lineWidth}px ${e.lineType} ${e.colorBorderSecondary}`
- }
- }
- });
- }, Yt = (e) => {
- const {
- cardPaddingBase: t,
- colorBorderSecondary: n,
- cardShadow: a,
- lineWidth: l
- } = e;
- return {
- width: "33.33%",
- padding: t,
- border: 0,
- borderRadius: 0,
- boxShadow: `
- ${l}px 0 0 0 ${n},
- 0 ${l}px 0 0 ${n},
- ${l}px ${l}px 0 0 ${n},
- ${l}px 0 0 0 ${n} inset,
- 0 ${l}px 0 0 ${n} inset;
- `,
- transition: `all ${e.motionDurationMid}`,
- "&-hoverable:hover": {
- position: "relative",
- zIndex: 1,
- boxShadow: a
- }
- };
- }, Zt = (e) => {
- const {
- componentCls: t,
- iconCls: n,
- cardActionsLiMargin: a,
- cardActionsIconSize: l,
- colorBorderSecondary: u
- } = e;
- return b(b({
- margin: 0,
- padding: 0,
- listStyle: "none",
- background: e.colorBgContainer,
- borderTop: `${e.lineWidth}px ${e.lineType} ${u}`,
- display: "flex",
- borderRadius: `0 0 ${e.borderRadiusLG}px ${e.borderRadiusLG}px `
- }, xe()), {
- "& > li": {
- margin: a,
- color: e.colorTextDescription,
- textAlign: "center",
- "> span": {
- position: "relative",
- display: "block",
- minWidth: e.cardActionsIconSize * 2,
- fontSize: e.fontSize,
- lineHeight: e.lineHeight,
- cursor: "pointer",
- "&:hover": {
- color: e.colorPrimary,
- transition: `color ${e.motionDurationMid}`
- },
- [`a:not(${t}-btn), > ${n}`]: {
- display: "inline-block",
- width: "100%",
- color: e.colorTextDescription,
- lineHeight: `${e.fontSize * e.lineHeight}px`,
- transition: `color ${e.motionDurationMid}`,
- "&:hover": {
- color: e.colorPrimary
- }
- },
- [`> ${n}`]: {
- fontSize: l,
- lineHeight: `${l * e.lineHeight}px`
- }
- },
- "&:not(:last-child)": {
- borderInlineEnd: `${e.lineWidth}px ${e.lineType} ${u}`
- }
- }
- });
- }, Kt = (e) => b(b({
- margin: `-${e.marginXXS}px 0`,
- display: "flex"
- }, xe()), {
- "&-avatar": {
- paddingInlineEnd: e.padding
- },
- "&-detail": {
- overflow: "hidden",
- flex: 1,
- "> div:not(:last-child)": {
- marginBottom: e.marginXS
- }
- },
- "&-title": b({
- color: e.colorTextHeading,
- fontWeight: e.fontWeightStrong,
- fontSize: e.fontSizeLG
- }, Qe),
- "&-description": {
- color: e.colorTextDescription
- }
- }), en = (e) => {
- const {
- componentCls: t,
- cardPaddingBase: n,
- colorFillAlter: a
- } = e;
- return {
- [`${t}-head`]: {
- padding: `0 ${n}px`,
- background: a,
- "&-title": {
- fontSize: e.fontSize
- }
- },
- [`${t}-body`]: {
- padding: `${e.padding}px ${n}px`
- }
- };
- }, tn = (e) => {
- const {
- componentCls: t
- } = e;
- return {
- overflow: "hidden",
- [`${t}-body`]: {
- userSelect: "none"
- }
- };
- }, nn = (e) => {
- const {
- componentCls: t,
- cardShadow: n,
- cardHeadPadding: a,
- colorBorderSecondary: l,
- boxShadow: u,
- cardPaddingBase: f
- } = e;
- return {
- [t]: b(b({}, Xe(e)), {
- position: "relative",
- background: e.colorBgContainer,
- borderRadius: e.borderRadiusLG,
- [`&:not(${t}-bordered)`]: {
- boxShadow: u
- },
- [`${t}-head`]: Qt(e),
- [`${t}-extra`]: {
- // https://stackoverflow.com/a/22429853/3040605
- marginInlineStart: "auto",
- color: "",
- fontWeight: "normal",
- fontSize: e.fontSize
- },
- [`${t}-body`]: b({
- padding: f,
- borderRadius: ` 0 0 ${e.borderRadiusLG}px ${e.borderRadiusLG}px`
- }, xe()),
- [`${t}-grid`]: Yt(e),
- [`${t}-cover`]: {
- "> *": {
- display: "block",
- width: "100%"
- },
- img: {
- borderRadius: `${e.borderRadiusLG}px ${e.borderRadiusLG}px 0 0`
- }
- },
- [`${t}-actions`]: Zt(e),
- [`${t}-meta`]: Kt(e)
- }),
- [`${t}-bordered`]: {
- border: `${e.lineWidth}px ${e.lineType} ${l}`,
- [`${t}-cover`]: {
- marginTop: -1,
- marginInlineStart: -1,
- marginInlineEnd: -1
- }
- },
- [`${t}-hoverable`]: {
- cursor: "pointer",
- transition: `box-shadow ${e.motionDurationMid}, border-color ${e.motionDurationMid}`,
- "&:hover": {
- borderColor: "transparent",
- boxShadow: n
- }
- },
- [`${t}-contain-grid`]: {
- [`${t}-body`]: {
- display: "flex",
- flexWrap: "wrap"
- },
- [`&:not(${t}-loading) ${t}-body`]: {
- marginBlockStart: -e.lineWidth,
- marginInlineStart: -e.lineWidth,
- padding: 0
- }
- },
- [`${t}-contain-tabs`]: {
- [`> ${t}-head`]: {
- [`${t}-head-title, ${t}-extra`]: {
- paddingTop: a
- }
- }
- },
- [`${t}-type-inner`]: en(e),
- [`${t}-loading`]: tn(e),
- [`${t}-rtl`]: {
- direction: "rtl"
- }
- };
- }, an = (e) => {
- const {
- componentCls: t,
- cardPaddingSM: n,
- cardHeadHeightSM: a
- } = e;
- return {
- [`${t}-small`]: {
- [`> ${t}-head`]: {
- minHeight: a,
- padding: `0 ${n}px`,
- fontSize: e.fontSize,
- [`> ${t}-head-wrapper`]: {
- [`> ${t}-extra`]: {
- fontSize: e.fontSize
- }
- }
- },
- [`> ${t}-body`]: {
- padding: n
- }
- },
- [`${t}-small${t}-contain-tabs`]: {
- [`> ${t}-head`]: {
- [`${t}-head-title, ${t}-extra`]: {
- minHeight: a,
- paddingTop: 0,
- display: "flex",
- alignItems: "center"
- }
- }
- }
- };
- }, ln = Le("Card", (e) => {
- const t = Je(e, {
- cardShadow: e.boxShadowCard,
- cardHeadHeight: e.fontSizeLG * e.lineHeightLG + e.padding * 2,
- cardHeadHeightSM: e.fontSize * e.lineHeight + e.paddingXS * 2,
- cardHeadPadding: e.padding,
- cardPaddingBase: e.paddingLG,
- cardHeadTabsMarginBottom: -e.padding - e.lineWidth,
- cardActionsLiMargin: `${e.paddingSM}px 0`,
- cardActionsIconSize: e.fontSize,
- cardPaddingSM: 12
- // Fixed padding.
- });
- return [
- // Style
- nn(t),
- // Size
- an(t)
- ];
- }), on = () => b(b({}, Ae()), {
- size: String,
- block: Boolean
- }), tt = q({
- compatConfig: {
- MODE: 3
- },
- name: "ASkeletonButton",
- props: Ce(on(), {
- size: "default"
- }),
- setup(e) {
- const {
- prefixCls: t
- } = J("skeleton", e), [n, a] = Ie(t), l = H(() => oe(t.value, `${t.value}-element`, {
- [`${t.value}-active`]: e.active,
- [`${t.value}-block`]: e.block
- }, a.value));
- return () => n(o("div", {
- class: l.value
- }, [o(Ne, W(W({}, e), {}, {
- prefixCls: `${t.value}-button`
- }), null)]));
- }
- }), nt = q({
- compatConfig: {
- MODE: 3
- },
- name: "ASkeletonInput",
- props: b(b({}, Oe(Ae(), ["shape"])), {
- size: String,
- block: Boolean
- }),
- setup(e) {
- const {
- prefixCls: t
- } = J("skeleton", e), [n, a] = Ie(t), l = H(() => oe(t.value, `${t.value}-element`, {
- [`${t.value}-active`]: e.active,
- [`${t.value}-block`]: e.block
- }, a.value));
- return () => n(o("div", {
- class: l.value
- }, [o(Ne, W(W({}, e), {}, {
- prefixCls: `${t.value}-input`
- }), null)]));
- }
- }), rn = "M365.714286 329.142857q0 45.714286-32.036571 77.677714t-77.677714 32.036571-77.677714-32.036571-32.036571-77.677714 32.036571-77.677714 77.677714-32.036571 77.677714 32.036571 32.036571 77.677714zM950.857143 548.571429l0 256-804.571429 0 0-109.714286 182.857143-182.857143 91.428571 91.428571 292.571429-292.571429zM1005.714286 146.285714l-914.285714 0q-7.460571 0-12.873143 5.412571t-5.412571 12.873143l0 694.857143q0 7.460571 5.412571 12.873143t12.873143 5.412571l914.285714 0q7.460571 0 12.873143-5.412571t5.412571-12.873143l0-694.857143q0-7.460571-5.412571-12.873143t-12.873143-5.412571zM1097.142857 164.571429l0 694.857143q0 37.741714-26.843429 64.585143t-64.585143 26.843429l-914.285714 0q-37.741714 0-64.585143-26.843429t-26.843429-64.585143l0-694.857143q0-37.741714 26.843429-64.585143t64.585143-26.843429l914.285714 0q37.741714 0 64.585143 26.843429t26.843429 64.585143z", at = q({
- compatConfig: {
- MODE: 3
- },
- name: "ASkeletonImage",
- props: Oe(Ae(), ["size", "shape", "active"]),
- setup(e) {
- const {
- prefixCls: t
- } = J("skeleton", e), [n, a] = Ie(t), l = H(() => oe(t.value, `${t.value}-element`, a.value));
- return () => n(o("div", {
- class: l.value
- }, [o("div", {
- class: `${t.value}-image`
- }, [o("svg", {
- viewBox: "0 0 1098 1024",
- xmlns: "http://www.w3.org/2000/svg",
- class: `${t.value}-image-svg`
- }, [o("path", {
- d: rn,
- class: `${t.value}-image-path`
- }, null)])])]));
- }
- }), sn = () => b(b({}, Ae()), {
- shape: String
- }), lt = q({
- compatConfig: {
- MODE: 3
- },
- name: "ASkeletonAvatar",
- props: Ce(sn(), {
- size: "default",
- shape: "circle"
- }),
- setup(e) {
- const {
- prefixCls: t
- } = J("skeleton", e), [n, a] = Ie(t), l = H(() => oe(t.value, `${t.value}-element`, {
- [`${t.value}-active`]: e.active
- }, a.value));
- return () => n(o("div", {
- class: l.value
- }, [o(Ne, W(W({}, e), {}, {
- prefixCls: `${t.value}-avatar`
- }), null)]));
- }
- });
- V.Button = tt;
- V.Avatar = lt;
- V.Input = nt;
- V.Image = at;
- V.Title = et;
- V.install = function(e) {
- return e.component(V.name, V), e.component(V.Button.name, tt), e.component(V.Avatar.name, lt), e.component(V.Input.name, nt), e.component(V.Image.name, at), e.component(V.Title.name, et), e;
- };
- const {
- TabPane: cn
- } = He, dn = () => ({
- prefixCls: String,
- title: X.any,
- extra: X.any,
- bordered: {
- type: Boolean,
- default: !0
- },
- bodyStyle: {
- type: Object,
- default: void 0
- },
- headStyle: {
- type: Object,
- default: void 0
- },
- loading: {
- type: Boolean,
- default: !1
- },
- hoverable: {
- type: Boolean,
- default: !1
- },
- type: {
- type: String
- },
- size: {
- type: String
- },
- actions: X.any,
- tabList: {
- type: Array
- },
- tabBarExtraContent: X.any,
- activeTabKey: String,
- defaultActiveTabKey: String,
- cover: X.any,
- onTabChange: {
- type: Function
- }
- }), ie = q({
- compatConfig: {
- MODE: 3
- },
- name: "ACard",
- inheritAttrs: !1,
- props: dn(),
- slots: Object,
- setup(e, t) {
- let {
- slots: n,
- attrs: a
- } = t;
- const {
- prefixCls: l,
- direction: u,
- size: f
- } = J("card", e), [s, S] = ln(l), d = (g) => g.map(($, E) => je($) && !Ye($) || !je($) ? o("li", {
- style: {
- width: `${100 / g.length}%`
- },
- key: `action-${E}`
- }, [o("span", null, [$])]) : null), I = (g) => {
- var x;
- (x = e.onTabChange) === null || x === void 0 || x.call(e, g);
- }, h = function() {
- let g = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : [], x;
- return g.forEach(($) => {
- $ && pt($.type) && $.type.__ANT_CARD_GRID && (x = !0);
- }), x;
- };
- return () => {
- var g, x, $, E, z, O;
- const {
- headStyle: A = {},
- bodyStyle: m = {},
- loading: w,
- bordered: i = !0,
- type: r,
- tabList: c,
- hoverable: T,
- activeTabKey: D,
- defaultActiveTabKey: y,
- tabBarExtraContent: M = pe((g = n.tabBarExtraContent) === null || g === void 0 ? void 0 : g.call(n)),
- title: R = pe((x = n.title) === null || x === void 0 ? void 0 : x.call(n)),
- extra: p = pe(($ = n.extra) === null || $ === void 0 ? void 0 : $.call(n)),
- actions: v = pe((E = n.actions) === null || E === void 0 ? void 0 : E.call(n)),
- cover: L = pe((z = n.cover) === null || z === void 0 ? void 0 : z.call(n))
- } = e, N = _e((O = n.default) === null || O === void 0 ? void 0 : O.call(n)), C = l.value, F = {
- [`${C}`]: !0,
- [S.value]: !0,
- [`${C}-loading`]: w,
- [`${C}-bordered`]: i,
- [`${C}-hoverable`]: !!T,
- [`${C}-contain-grid`]: h(N),
- [`${C}-contain-tabs`]: c && c.length,
- [`${C}-${f.value}`]: f.value,
- [`${C}-type-${r}`]: !!r,
- [`${C}-rtl`]: u.value === "rtl"
- }, te = o(V, {
- loading: !0,
- active: !0,
- paragraph: {
- rows: 4
- },
- title: !1
- }, {
- default: () => [N]
- }), Q = D !== void 0, ne = {
- size: "large",
- [Q ? "activeKey" : "defaultActiveKey"]: Q ? D : y,
- onChange: I,
- class: `${C}-head-tabs`
- };
- let Y;
- const ae = c && c.length ? o(He, ne, {
- default: () => [c.map((K) => {
- const {
- tab: re,
- slots: Z
- } = K, ge = Z == null ? void 0 : Z.tab;
- gt(!Z, "Card", "tabList slots is deprecated, Please use `customTab` instead.");
- let me = re !== void 0 ? re : n[ge] ? n[ge](K) : null;
- return me = mt(n, "customTab", K, () => [me]), o(cn, {
- tab: me,
- key: K.key,
- disabled: K.disabled
- }, null);
- })],
- rightExtra: M ? () => M : null
- }) : null;
- (R || p || ae) && (Y = o("div", {
- class: `${C}-head`,
- style: A
- }, [o("div", {
- class: `${C}-head-wrapper`
- }, [R && o("div", {
- class: `${C}-head-title`
- }, [R]), p && o("div", {
- class: `${C}-extra`
- }, [p])]), ae]));
- const he = L ? o("div", {
- class: `${C}-cover`
- }, [L]) : null, Ee = o("div", {
- class: `${C}-body`,
- style: m
- }, [w ? te : N]), Te = v && v.length ? o("ul", {
- class: `${C}-actions`
- }, [d(v)]) : null;
- return s(o("div", W(W({
- ref: "cardContainerRef"
- }, a), {}, {
- class: [F, a.class]
- }), [Y, he, N && N.length ? Ee : null, Te]));
- };
- }
- }), un = () => ({
- prefixCls: String,
- title: le(),
- description: le(),
- avatar: le()
- }), De = q({
- compatConfig: {
- MODE: 3
- },
- name: "ACardMeta",
- props: un(),
- slots: Object,
- setup(e, t) {
- let {
- slots: n
- } = t;
- const {
- prefixCls: a
- } = J("card", e);
- return () => {
- const l = {
- [`${a.value}-meta`]: !0
- }, u = Pe(n, e, "avatar"), f = Pe(n, e, "title"), s = Pe(n, e, "description"), S = u ? o("div", {
- class: `${a.value}-meta-avatar`
- }, [u]) : null, d = f ? o("div", {
- class: `${a.value}-meta-title`
- }, [f]) : null, I = s ? o("div", {
- class: `${a.value}-meta-description`
- }, [s]) : null, h = d || I ? o("div", {
- class: `${a.value}-meta-detail`
- }, [d, I]) : null;
- return o("div", {
- class: l
- }, [S, h]);
- };
- }
- }), gn = () => ({
- prefixCls: String,
- hoverable: {
- type: Boolean,
- default: !0
- }
- }), fe = q({
- compatConfig: {
- MODE: 3
- },
- name: "ACardGrid",
- __ANT_CARD_GRID: !0,
- props: gn(),
- setup(e, t) {
- let {
- slots: n
- } = t;
- const {
- prefixCls: a
- } = J("card", e), l = H(() => ({
- [`${a.value}-grid`]: !0,
- [`${a.value}-grid-hoverable`]: e.hoverable
- }));
- return () => {
- var u;
- return o("div", {
- class: l.value
- }, [(u = n.default) === null || u === void 0 ? void 0 : u.call(n)]);
- };
- }
- });
- ie.Meta = De;
- ie.Grid = fe;
- ie.install = function(e) {
- return e.component(ie.name, ie), e.component(De.name, De), e.component(fe.name, fe), e;
- };
- const mn = () => ({
- avatar: X.any,
- description: X.any,
- prefixCls: String,
- title: X.any
- }), pn = q({
- compatConfig: {
- MODE: 3
- },
- name: "AListItemMeta",
- props: mn(),
- displayName: "AListItemMeta",
- __ANT_LIST_ITEM_META: !0,
- slots: Object,
- setup(e, t) {
- let {
- slots: n
- } = t;
- const {
- prefixCls: a
- } = J("list", e);
- return () => {
- var l, u, f, s, S, d;
- const I = `${a.value}-item-meta`, h = (l = e.title) !== null && l !== void 0 ? l : (u = n.title) === null || u === void 0 ? void 0 : u.call(n), g = (f = e.description) !== null && f !== void 0 ? f : (s = n.description) === null || s === void 0 ? void 0 : s.call(n), x = (S = e.avatar) !== null && S !== void 0 ? S : (d = n.avatar) === null || d === void 0 ? void 0 : d.call(n), $ = o("div", {
- class: `${a.value}-item-meta-content`
- }, [h && o("h4", {
- class: `${a.value}-item-meta-title`
- }, [h]), g && o("div", {
- class: `${a.value}-item-meta-description`
- }, [g])]);
- return o("div", {
- class: I
- }, [x && o("div", {
- class: `${a.value}-item-meta-avatar`
- }, [x]), (h || g) && $]);
- };
- }
- }), it = Symbol("ListContextKey");
- var vn = function(e, t) {
- var n = {};
- for (var a in e) Object.prototype.hasOwnProperty.call(e, a) && t.indexOf(a) < 0 && (n[a] = e[a]);
- if (e != null && typeof Object.getOwnPropertySymbols == "function") for (var l = 0, a = Object.getOwnPropertySymbols(e); l < a.length; l++)
- t.indexOf(a[l]) < 0 && Object.prototype.propertyIsEnumerable.call(e, a[l]) && (n[a[l]] = e[a[l]]);
- return n;
- };
- const fn = () => ({
- prefixCls: String,
- extra: X.any,
- actions: X.array,
- grid: Object,
- colStyle: {
- type: Object,
- default: void 0
- }
- }), ot = q({
- compatConfig: {
- MODE: 3
- },
- name: "AListItem",
- inheritAttrs: !1,
- Meta: pn,
- props: fn(),
- slots: Object,
- setup(e, t) {
- let {
- slots: n,
- attrs: a
- } = t;
- const {
- itemLayout: l,
- grid: u
- } = rt(it, {
- grid: j(),
- itemLayout: j()
- }), {
- prefixCls: f
- } = J("list", e), s = () => {
- var d;
- const I = ((d = n.default) === null || d === void 0 ? void 0 : d.call(n)) || [];
- let h;
- return I.forEach((g) => {
- ft(g) && !Ye(g) && (h = !0);
- }), h && I.length > 1;
- }, S = () => {
- var d, I;
- const h = (d = e.extra) !== null && d !== void 0 ? d : (I = n.extra) === null || I === void 0 ? void 0 : I.call(n);
- return l.value === "vertical" ? !!h : !s();
- };
- return () => {
- var d, I, h, g, x;
- const {
- class: $
- } = a, E = vn(a, ["class"]), z = f.value, O = (d = e.extra) !== null && d !== void 0 ? d : (I = n.extra) === null || I === void 0 ? void 0 : I.call(n), A = (h = n.default) === null || h === void 0 ? void 0 : h.call(n);
- let m = (g = e.actions) !== null && g !== void 0 ? g : _e((x = n.actions) === null || x === void 0 ? void 0 : x.call(n));
- m = m && !Array.isArray(m) ? [m] : m;
- const w = m && m.length > 0 && o("ul", {
- class: `${z}-item-action`,
- key: "actions"
- }, [m.map((c, T) => o("li", {
- key: `${z}-item-action-${T}`
- }, [c, T !== m.length - 1 && o("em", {
- class: `${z}-item-action-split`
- }, null)]))]), i = u.value ? "div" : "li", r = o(i, W(W({}, E), {}, {
- class: oe(`${z}-item`, {
- [`${z}-item-no-flex`]: !S()
- }, $)
- }), {
- default: () => [l.value === "vertical" && O ? [o("div", {
- class: `${z}-item-main`,
- key: "content"
- }, [A, w]), o("div", {
- class: `${z}-item-extra`,
- key: "extra"
- }, [O])] : [A, w, vt(O, {
- key: "extra"
- })]]
- });
- return u.value ? o(qt, {
- flex: 1,
- style: e.colStyle
- }, {
- default: () => [r]
- }) : r;
- };
- }
- }), hn = (e) => {
- const {
- listBorderedCls: t,
- componentCls: n,
- paddingLG: a,
- margin: l,
- padding: u,
- listItemPaddingSM: f,
- marginLG: s,
- borderRadiusLG: S
- } = e;
- return {
- [`${t}`]: {
- border: `${e.lineWidth}px ${e.lineType} ${e.colorBorder}`,
- borderRadius: S,
- [`${n}-header,${n}-footer,${n}-item`]: {
- paddingInline: a
- },
- [`${n}-pagination`]: {
- margin: `${l}px ${s}px`
- }
- },
- [`${t}${n}-sm`]: {
- [`${n}-item,${n}-header,${n}-footer`]: {
- padding: f
- }
- },
- [`${t}${n}-lg`]: {
- [`${n}-item,${n}-header,${n}-footer`]: {
- padding: `${u}px ${a}px`
- }
- }
- };
- }, yn = (e) => {
- const {
- componentCls: t,
- screenSM: n,
- screenMD: a,
- marginLG: l,
- marginSM: u,
- margin: f
- } = e;
- return {
- [`@media screen and (max-width:${a})`]: {
- [`${t}`]: {
- [`${t}-item`]: {
- [`${t}-item-action`]: {
- marginInlineStart: l
- }
- }
- },
- [`${t}-vertical`]: {
- [`${t}-item`]: {
- [`${t}-item-extra`]: {
- marginInlineStart: l
- }
- }
- }
- },
- [`@media screen and (max-width: ${n})`]: {
- [`${t}`]: {
- [`${t}-item`]: {
- flexWrap: "wrap",
- [`${t}-action`]: {
- marginInlineStart: u
- }
- }
- },
- [`${t}-vertical`]: {
- [`${t}-item`]: {
- flexWrap: "wrap-reverse",
- [`${t}-item-main`]: {
- minWidth: e.contentWidth
- },
- [`${t}-item-extra`]: {
- margin: `auto auto ${f}px`
- }
- }
- }
- }
- };
- }, bn = (e) => {
- const {
- componentCls: t,
- antCls: n,
- controlHeight: a,
- minHeight: l,
- paddingSM: u,
- marginLG: f,
- padding: s,
- listItemPadding: S,
- colorPrimary: d,
- listItemPaddingSM: I,
- listItemPaddingLG: h,
- paddingXS: g,
- margin: x,
- colorText: $,
- colorTextDescription: E,
- motionDurationSlow: z,
- lineWidth: O
- } = e;
- return {
- [`${t}`]: b(b({}, Xe(e)), {
- position: "relative",
- "*": {
- outline: "none"
- },
- [`${t}-header, ${t}-footer`]: {
- background: "transparent",
- paddingBlock: u
- },
- [`${t}-pagination`]: {
- marginBlockStart: f,
- textAlign: "end",
- // https://github.com/ant-design/ant-design/issues/20037
- [`${n}-pagination-options`]: {
- textAlign: "start"
- }
- },
- [`${t}-spin`]: {
- minHeight: l,
- textAlign: "center"
- },
- [`${t}-items`]: {
- margin: 0,
- padding: 0,
- listStyle: "none"
- },
- [`${t}-item`]: {
- display: "flex",
- alignItems: "center",
- justifyContent: "space-between",
- padding: S,
- color: $,
- [`${t}-item-meta`]: {
- display: "flex",
- flex: 1,
- alignItems: "flex-start",
- maxWidth: "100%",
- [`${t}-item-meta-avatar`]: {
- marginInlineEnd: s
- },
- [`${t}-item-meta-content`]: {
- flex: "1 0",
- width: 0,
- color: $
- },
- [`${t}-item-meta-title`]: {
- marginBottom: e.marginXXS,
- color: $,
- fontSize: e.fontSize,
- lineHeight: e.lineHeight,
- "> a": {
- color: $,
- transition: `all ${z}`,
- "&:hover": {
- color: d
- }
- }
- },
- [`${t}-item-meta-description`]: {
- color: E,
- fontSize: e.fontSize,
- lineHeight: e.lineHeight
- }
- },
- [`${t}-item-action`]: {
- flex: "0 0 auto",
- marginInlineStart: e.marginXXL,
- padding: 0,
- fontSize: 0,
- listStyle: "none",
- "& > li": {
- position: "relative",
- display: "inline-block",
- padding: `0 ${g}px`,
- color: E,
- fontSize: e.fontSize,
- lineHeight: e.lineHeight,
- textAlign: "center",
- "&:first-child": {
- paddingInlineStart: 0
- }
- },
- [`${t}-item-action-split`]: {
- position: "absolute",
- insetBlockStart: "50%",
- insetInlineEnd: 0,
- width: O,
- height: Math.ceil(e.fontSize * e.lineHeight) - e.marginXXS * 2,
- transform: "translateY(-50%)",
- backgroundColor: e.colorSplit
- }
- }
- },
- [`${t}-empty`]: {
- padding: `${s}px 0`,
- color: E,
- fontSize: e.fontSizeSM,
- textAlign: "center"
- },
- [`${t}-empty-text`]: {
- padding: s,
- color: e.colorTextDisabled,
- fontSize: e.fontSize,
- textAlign: "center"
- },
- // ============================ without flex ============================
- [`${t}-item-no-flex`]: {
- display: "block"
- }
- }),
- [`${t}-grid ${n}-col > ${t}-item`]: {
- display: "block",
- maxWidth: "100%",
- marginBlockEnd: x,
- paddingBlock: 0,
- borderBlockEnd: "none"
- },
- [`${t}-vertical ${t}-item`]: {
- alignItems: "initial",
- [`${t}-item-main`]: {
- display: "block",
- flex: 1
- },
- [`${t}-item-extra`]: {
- marginInlineStart: f
- },
- [`${t}-item-meta`]: {
- marginBlockEnd: s,
- [`${t}-item-meta-title`]: {
- marginBlockEnd: u,
- color: $,
- fontSize: e.fontSizeLG,
- lineHeight: e.lineHeightLG
- }
- },
- [`${t}-item-action`]: {
- marginBlockStart: s,
- marginInlineStart: "auto",
- "> li": {
- padding: `0 ${s}px`,
- "&:first-child": {
- paddingInlineStart: 0
- }
- }
- }
- },
- [`${t}-split ${t}-item`]: {
- borderBlockEnd: `${e.lineWidth}px ${e.lineType} ${e.colorSplit}`,
- "&:last-child": {
- borderBlockEnd: "none"
- }
- },
- [`${t}-split ${t}-header`]: {
- borderBlockEnd: `${e.lineWidth}px ${e.lineType} ${e.colorSplit}`
- },
- [`${t}-split${t}-empty ${t}-footer`]: {
- borderTop: `${e.lineWidth}px ${e.lineType} ${e.colorSplit}`
- },
- [`${t}-loading ${t}-spin-nested-loading`]: {
- minHeight: a
- },
- [`${t}-split${t}-something-after-last-item ${n}-spin-container > ${t}-items > ${t}-item:last-child`]: {
- borderBlockEnd: `${e.lineWidth}px ${e.lineType} ${e.colorSplit}`
- },
- [`${t}-lg ${t}-item`]: {
- padding: h
- },
- [`${t}-sm ${t}-item`]: {
- padding: I
- },
- // Horizontal
- [`${t}:not(${t}-vertical)`]: {
- [`${t}-item-no-flex`]: {
- [`${t}-item-action`]: {
- float: "right"
- }
- }
- }
- };
- }, Sn = Le("List", (e) => {
- const t = Je(e, {
- listBorderedCls: `${e.componentCls}-bordered`,
- minHeight: e.controlHeightLG,
- listItemPadding: `${e.paddingContentVertical}px ${e.paddingContentHorizontalLG}px`,
- listItemPaddingSM: `${e.paddingContentVerticalSM}px ${e.paddingContentHorizontal}px`,
- listItemPaddingLG: `${e.paddingContentVerticalLG}px ${e.paddingContentHorizontalLG}px`
- });
- return [bn(t), hn(t), yn(t)];
- }, {
- contentWidth: 220
- }), $n = () => ({
- bordered: Ve(),
- dataSource: $t(),
- extra: le(),
- grid: $e(),
- itemLayout: String,
- loading: Be([Boolean, Object]),
- loadMore: le(),
- pagination: Be([Boolean, Object]),
- prefixCls: String,
- rowKey: Be([String, Number, Function]),
- renderItem: St(),
- size: String,
- split: Ve(),
- header: le(),
- footer: le(),
- locale: $e()
- }), ee = q({
- compatConfig: {
- MODE: 3
- },
- name: "AList",
- inheritAttrs: !1,
- Item: ot,
- props: Ce($n(), {
- dataSource: [],
- bordered: !1,
- split: !0,
- loading: !1,
- pagination: !1
- }),
- slots: Object,
- setup(e, t) {
- let {
- slots: n,
- attrs: a
- } = t;
- var l, u;
- st(it, {
- grid: Me(e, "grid"),
- itemLayout: Me(e, "itemLayout")
- });
- const f = {
- current: 1,
- total: 0
- }, {
- prefixCls: s,
- direction: S,
- renderEmpty: d
- } = J("list", e), [I, h] = Sn(s), g = H(() => e.pagination && typeof e.pagination == "object" ? e.pagination : {}), x = j((l = g.value.defaultCurrent) !== null && l !== void 0 ? l : 1), $ = j((u = g.value.defaultPageSize) !== null && u !== void 0 ? u : 10);
- Ue(g, () => {
- "current" in g.value && (x.value = g.value.current), "pageSize" in g.value && ($.value = g.value.pageSize);
- });
- const E = [], z = (p) => (v, L) => {
- x.value = v, $.value = L, g.value[p] && g.value[p](v, L);
- }, O = z("onChange"), A = z("onShowSizeChange"), m = H(() => typeof e.loading == "boolean" ? {
- spinning: e.loading
- } : e.loading), w = H(() => m.value && m.value.spinning), i = H(() => {
- let p = "";
- switch (e.size) {
- case "large":
- p = "lg";
- break;
- case "small":
- p = "sm";
- break;
- }
- return p;
- }), r = H(() => ({
- [`${s.value}`]: !0,
- [`${s.value}-vertical`]: e.itemLayout === "vertical",
- [`${s.value}-${i.value}`]: i.value,
- [`${s.value}-split`]: e.split,
- [`${s.value}-bordered`]: e.bordered,
- [`${s.value}-loading`]: w.value,
- [`${s.value}-grid`]: !!e.grid,
- [`${s.value}-rtl`]: S.value === "rtl"
- })), c = H(() => {
- const p = b(b(b({}, f), {
- total: e.dataSource.length,
- current: x.value,
- pageSize: $.value
- }), e.pagination || {}), v = Math.ceil(p.total / p.pageSize);
- return p.current > v && (p.current = v), p;
- }), T = H(() => {
- let p = [...e.dataSource];
- return e.pagination && e.dataSource.length > (c.value.current - 1) * c.value.pageSize && (p = [...e.dataSource].splice((c.value.current - 1) * c.value.pageSize, c.value.pageSize)), p;
- }), D = ht(), y = yt(() => {
- for (let p = 0; p < Ge.length; p += 1) {
- const v = Ge[p];
- if (D.value[v])
- return v;
- }
- }), M = H(() => {
- if (!e.grid)
- return;
- const p = y.value && e.grid[y.value] ? e.grid[y.value] : e.grid.column;
- if (p)
- return {
- width: `${100 / p}%`,
- maxWidth: `${100 / p}%`
- };
- }), R = (p, v) => {
- var L;
- const N = (L = e.renderItem) !== null && L !== void 0 ? L : n.renderItem;
- if (!N) return null;
- let C;
- const F = typeof e.rowKey;
- return F === "function" ? C = e.rowKey(p) : F === "string" || F === "number" ? C = p[e.rowKey] : C = p.key, C || (C = `list-item-${v}`), E[v] = C, N({
- item: p,
- index: v
- });
- };
- return () => {
- var p, v, L, N, C, F, te, Q;
- const ne = (p = e.loadMore) !== null && p !== void 0 ? p : (v = n.loadMore) === null || v === void 0 ? void 0 : v.call(n), Y = (L = e.footer) !== null && L !== void 0 ? L : (N = n.footer) === null || N === void 0 ? void 0 : N.call(n), ae = (C = e.header) !== null && C !== void 0 ? C : (F = n.header) === null || F === void 0 ? void 0 : F.call(n), he = _e((te = n.default) === null || te === void 0 ? void 0 : te.call(n)), Ee = !!(ne || e.pagination || Y), Te = oe(b(b({}, r.value), {
- [`${s.value}-something-after-last-item`]: Ee
- }), a.class, h.value), K = e.pagination ? o("div", {
- class: `${s.value}-pagination`
- }, [o(bt, W(W({}, c.value), {}, {
- onChange: O,
- onShowSizeChange: A
- }), null)]) : null;
- let re = w.value && o("div", {
- style: {
- minHeight: "53px"
- }
- }, null);
- if (T.value.length > 0) {
- E.length = 0;
- const ge = T.value.map((we, ze) => R(we, ze)), me = ge.map((we, ze) => o("div", {
- key: E[ze],
- style: M.value
- }, [we]));
- re = e.grid ? o(Jt, {
- gutter: e.grid.gutter
- }, {
- default: () => [me]
- }) : o("ul", {
- class: `${s.value}-items`
- }, [ge]);
- } else !he.length && !w.value && (re = o("div", {
- class: `${s.value}-empty-text`
- }, [((Q = e.locale) === null || Q === void 0 ? void 0 : Q.emptyText) || d("List")]));
- const Z = c.value.position || "bottom";
- return I(o("div", W(W({}, a), {}, {
- class: Te
- }), [(Z === "top" || Z === "both") && K, ae && o("div", {
- class: `${s.value}-header`
- }, [ae]), o(Ze, m.value, {
- default: () => [re, he]
- }), Y && o("div", {
- class: `${s.value}-footer`
- }, [Y]), ne || (Z === "bottom" || Z === "both") && K]));
- };
- }
- });
- ee.install = function(e) {
- return e.component(ee.name, ee), e.component(ee.Item.name, ee.Item), e.component(ee.Item.Meta.name, ee.Item.Meta), e;
- };
- const xn = (e) => {
- const {
- componentCls: t,
- iconCls: n,
- zIndexPopup: a,
- colorText: l,
- colorWarning: u,
- marginXS: f,
- fontSize: s,
- fontWeightStrong: S,
- lineHeight: d
- } = e;
- return {
- [t]: {
- zIndex: a,
- [`${t}-inner-content`]: {
- color: l
- },
- [`${t}-message`]: {
- position: "relative",
- marginBottom: f,
- color: l,
- fontSize: s,
- display: "flex",
- flexWrap: "nowrap",
- alignItems: "start",
- [`> ${t}-message-icon ${n}`]: {
- color: u,
- fontSize: s,
- flex: "none",
- lineHeight: 1,
- paddingTop: (Math.round(s * d) - s) / 2
- },
- "&-title": {
- flex: "auto",
- marginInlineStart: f
- },
- "&-title-only": {
- fontWeight: S
- }
- },
- [`${t}-description`]: {
- position: "relative",
- marginInlineStart: s + f,
- marginBottom: f,
- color: l,
- fontSize: s
- },
- [`${t}-buttons`]: {
- textAlign: "end",
- button: {
- marginInlineStart: f
- }
- }
- }
- };
- }, Cn = Le("Popconfirm", (e) => xn(e), (e) => {
- const {
- zIndexPopupBase: t
- } = e;
- return {
- zIndexPopup: t + 60
- };
- });
- var In = function(e, t) {
- var n = {};
- for (var a in e) Object.prototype.hasOwnProperty.call(e, a) && t.indexOf(a) < 0 && (n[a] = e[a]);
- if (e != null && typeof Object.getOwnPropertySymbols == "function") for (var l = 0, a = Object.getOwnPropertySymbols(e); l < a.length; l++)
- t.indexOf(a[l]) < 0 && Object.prototype.propertyIsEnumerable.call(e, a[l]) && (n[a[l]] = e[a[l]]);
- return n;
- };
- const An = () => b(b({}, Bt()), {
- prefixCls: String,
- content: ce(),
- title: ce(),
- description: ce(),
- okType: Mt("primary"),
- disabled: {
- type: Boolean,
- default: !1
- },
- okText: ce(),
- cancelText: ce(),
- icon: ce(),
- okButtonProps: $e(),
- cancelButtonProps: $e(),
- showCancel: {
- type: Boolean,
- default: !0
- },
- onConfirm: Function,
- onCancel: Function
- }), En = q({
- compatConfig: {
- MODE: 3
- },
- name: "APopconfirm",
- inheritAttrs: !1,
- props: Ce(An(), b(b({}, zt()), {
- trigger: "click",
- placement: "top",
- mouseEnterDelay: 0.1,
- mouseLeaveDelay: 0.1,
- arrowPointAtCenter: !1,
- autoAdjustOverflow: !0,
- okType: "primary",
- disabled: !1
- })),
- slots: Object,
- // emits: ['update:open', 'visibleChange'],
- setup(e, t) {
- let {
- slots: n,
- emit: a,
- expose: l,
- attrs: u
- } = t;
- const f = j();
- Ct(e.visible === void 0, "Popconfirm", "`visible` will be removed in next major version, please use `open` instead."), l({
- getPopupDomNode: () => {
- var r, c;
- return (c = (r = f.value) === null || r === void 0 ? void 0 : r.getPopupDomNode) === null || c === void 0 ? void 0 : c.call(r);
- }
- });
- const [s, S] = It(!1, {
- value: Me(e, "open")
- }), d = (r, c) => {
- e.open === void 0 && S(r), a("update:open", r), a("openChange", r, c);
- }, I = (r) => {
- d(!1, r);
- }, h = (r) => {
- var c;
- return (c = e.onConfirm) === null || c === void 0 ? void 0 : c.call(e, r);
- }, g = (r) => {
- var c;
- d(!1, r), (c = e.onCancel) === null || c === void 0 || c.call(e, r);
- }, x = (r) => {
- r.keyCode === Rt.ESC && s && d(!1, r);
- }, $ = (r) => {
- const {
- disabled: c
- } = e;
- c || d(r);
- }, {
- prefixCls: E,
- getPrefixCls: z
- } = J("popconfirm", e), O = H(() => z()), A = H(() => z("btn")), [m] = Cn(E), [w] = At("Popconfirm", Et.Popconfirm), i = () => {
- var r, c, T, D, y;
- const {
- okButtonProps: M,
- cancelButtonProps: R,
- title: p = (r = n.title) === null || r === void 0 ? void 0 : r.call(n),
- description: v = (c = n.description) === null || c === void 0 ? void 0 : c.call(n),
- cancelText: L = (T = n.cancel) === null || T === void 0 ? void 0 : T.call(n),
- okText: N = (D = n.okText) === null || D === void 0 ? void 0 : D.call(n),
- okType: C,
- icon: F = ((y = n.icon) === null || y === void 0 ? void 0 : y.call(n)) || o(Pt, null, null),
- showCancel: te = !0
- } = e, {
- cancelButton: Q,
- okButton: ne
- } = n, Y = b({
- onClick: g,
- size: "small"
- }, R), ae = b(b(b({
- onClick: h
- }, ke(C)), {
- size: "small"
- }), M);
- return o("div", {
- class: `${E.value}-inner-content`
- }, [o("div", {
- class: `${E.value}-message`
- }, [F && o("span", {
- class: `${E.value}-message-icon`
- }, [F]), o("div", {
- class: [`${E.value}-message-title`, {
- [`${E.value}-message-title-only`]: !!v
- }]
- }, [p])]), v && o("div", {
- class: `${E.value}-description`
- }, [v]), o("div", {
- class: `${E.value}-buttons`
- }, [te ? Q ? Q(Y) : o(Ke, Y, {
- default: () => [L || w.value.cancelText]
- }) : null, ne ? ne(ae) : o(Ut, {
- buttonProps: b(b({
- size: "small"
- }, ke(C)), M),
- actionFn: h,
- close: I,
- prefixCls: A.value,
- quitOnNullishReturnValue: !0,
- emitEvent: !0
- }, {
- default: () => [N || w.value.okText]
- })])]);
- };
- return () => {
- var r;
- const {
- placement: c,
- overlayClassName: T,
- trigger: D = "click"
- } = e, y = In(e, ["placement", "overlayClassName", "trigger"]), M = Oe(y, ["title", "content", "cancelText", "okText", "onUpdate:open", "onConfirm", "onCancel", "prefixCls"]), R = oe(E.value, T);
- return m(o(Ft, W(W(W({}, M), u), {}, {
- trigger: D,
- placement: c,
- onOpenChange: $,
- open: s.value,
- overlayClassName: R,
- transitionName: Tt(O.value, "zoom-big", e.transitionName),
- ref: f,
- "data-popover-inject": !0
- }), {
- default: () => [wt(((r = n.default) === null || r === void 0 ? void 0 : r.call(n)) || [], {
- onKeydown: (p) => {
- x(p);
- }
- }, !1)],
- content: i
- }));
- };
- }
- }), Tn = xt(En), wn = {
- __name: "workplace-selector",
- props: {
- value: {
- type: Boolean,
- default: !1
- },
- selectedList: {
- type: Array,
- default: () => []
- }
- },
- emits: ["update:value", "done"],
- setup(e, { emit: t }) {
- const n = e, a = t, l = Dt(), u = (A) => {
- if (!A) return ue;
- const m = A.split("-").map((i) => i.charAt(0).toUpperCase() + i.slice(1)).join("") + "Outlined", w = Re(m);
- return typeof w == "string" ? ue : w;
- }, f = H({
- get: () => n.value,
- set: (A) => a("update:value", A)
- }), s = j("mm0001"), S = j([]), d = j([]), I = H(() => l.menus), h = H(() => l.clients), g = () => {
- h.value && h.value.length && (S.value = h.value.map((A) => ({ id: A.id, clientId: A.clientId, clientName: A.clientName })));
- }, x = () => {
- f.value = !1;
- }, $ = (A) => {
- A.forEach((m) => {
- m.children && m.children.length > 0 ? $(m.children) : m.href && m.isShow && d.value.push({
- id: m.id,
- name: m.name,
- icon: m.icon,
- href: m.href,
- hoverable: z(m, n.selectedList)
- });
- });
- }, E = (A) => {
- a("done", A);
- }, z = (A = {}, m = []) => !m || m.length < 1 ? !0 : !m.some((w) => w.menu.id === A.id), O = (A) => se(this, null, function* () {
- var i;
- d.value = [];
- const m = window.$utils.ls.get("USER-TOKEN"), w = yield Lt({
- baseURL: window.$utils.env.VITE_APP_API_BASE_URL,
- url: `/${window.$utils.env.VITE_APP_PORTAL_SERVER_NAME}/v1/users/menus`,
- timeout: 60 * 1e3,
- headers: {
- "Content-Type": "application/json;charset=UTF-8",
- "user-token": m,
- "client-id": A
- },
- method: "get",
- data: {}
- });
- $((i = w == null ? void 0 : w.data) == null ? void 0 : i.data);
- });
- return Ue(
- () => n.selectedList,
- () => {
- d.value = [], $(I.value);
- }
- ), g(), (A, m) => {
- const w = kt, i = He, r = fe, c = ie, T = Ke, D = Re("s-modal");
- return P(), k(D, {
- value: f.value,
- "onUpdate:value": m[1] || (m[1] = (y) => f.value = y),
- title: A.$l("添加快捷导航菜单"),
- width: "80%",
- maskClosable: !1
- }, {
- footer: B(() => [
- o(T, {
- key: "back",
- onClick: x
- }, {
- default: B(() => [
- ve(_(A.$l("关闭")), 1)
- ]),
- _: 1
- })
- ]),
- default: B(() => [
- o(i, {
- activeKey: s.value,
- "onUpdate:activeKey": m[0] || (m[0] = (y) => s.value = y),
- onChange: O
- }, {
- default: B(() => [
- (P(!0), U(be, null, Se(S.value, (y) => (P(), k(w, {
- key: y.clientId,
- tab: y.clientName
- }, null, 8, ["tab"]))), 128))
- ]),
- _: 1
- }, 8, ["activeKey"]),
- o(c, {
- style: { "margin-bottom": "6px" },
- bordered: !1
- }, {
- default: B(() => [
- (P(!0), U(be, null, Se(d.value, (y, M) => (P(), k(r, {
- style: ct({ width: "20%", textAlign: "center", cursor: y.hoverable ? "pointer" : "" }),
- key: y.id + M,
- hoverable: y.hoverable,
- onClick: (R) => y.hoverable ? E(y) : ""
- }, {
- default: B(() => [
- y.icon ? (P(), k(qe(u(y.icon)), { key: 1 })) : (P(), k(de(ue), { key: 0 })),
- ve(" " + _(y.name), 1)
- ]),
- _: 2
- }, 1032, ["style", "hoverable", "onClick"]))), 128))
- ]),
- _: 1
- })
- ]),
- _: 1
- }, 8, ["value", "title"]);
- };
- }
- }, Fe = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAIwAAAB0CAIAAADYY00dAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAyNpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuNi1jMTQ4IDc5LjE2NDAzNiwgMjAxOS8wOC8xMy0wMTowNjo1NyAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJod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czTDgJQZPHJxOAC3VUrHaxO0NdzV9D6Dqyqt7T/cPbCrYjhIWcIzPT2FAaVxApP7x2rrUNeLi3NX+3u5oKq0tynanP8My0EgZQ7PXKWS1gnJKT77nGFlgFxxClul1Tt6kCuN7wdJBMQ+PyjV2EO+yGXTfhZU6g+o10Pjrq4ukzN1IpPd4lm6XeYh7i6QsDruQnbsP7AlDXj0bFU8WzYzZOXM0ns91vf6mn+dhFC128cnJ6eB99fW1trtdnrwoA3T0x5ZNm4t49nLcvaTBXpgOW6q07lOYl79j4tPAx6MxvP413sOcV4H0ZbzndFRUDFo9SQS12DEbJXWITxcRDtzwYY/RTghuFyoaTc9f96gZWXEVD2DKEJhN1lG8pxTRqBn/BE8BTy3uVz8aWw9rN7+DcjtV359V52Snd2++J9MTQma3t9xee5t+eY+b1cYE5l6GILiy38CDADXoxCrjDZe8wAAAABJRU5ErkJggg==", zn = { class: "board-layout" }, Pn = {
- key: 0,
- class: "flex-grid-5"
- }, Bn = ["onClick"], Mn = {
- key: 1,
- class: "empty project-content"
- }, Rn = ["src"], Dn = { class: "tabs-wrap" }, Ln = { class: "list-content" }, On = { class: "list-content-item" }, _n = ["onClick"], Hn = { style: { float: "right" } }, Nn = {
- key: 1,
- class: "empty project-content"
- }, jn = ["src"], Wn = {
- __name: "workplace",
- setup(e) {
- const t = ut(), n = (i) => {
- if (!i) return ue;
- const r = i.split("-").map((T) => T.charAt(0).toUpperCase() + T.slice(1)).join("") + "Outlined", c = Re(r);
- return typeof c == "string" ? ue : c;
- }, a = j(1), l = { padding: 0 }, u = j(0), f = j(0), s = j(!1), S = j(!1), d = j([]), I = j(!1), h = j(!1), g = j([]), x = () => se(this, null, function* () {
- s.value = !0;
- const i = yield Ht();
- d.value = i || [], d.value.length < 1 && (h.value = !1), s.value = !1;
- }), $ = (i, r) => {
- try {
- const c = new URL(i);
- c.search = "", c.hash = "";
- let T = c.toString();
- return T.endsWith("/") || (T += "/"), T + r;
- } catch (c) {
- return i + r;
- }
- }, E = (i) => {
- if (i.menu.clientId && i.menu.clientId !== `${window.$utils.env.VITE_APP_CLIENT_ID}`) {
- const r = i.menu.hrefs ? i.menu.hrefs.substring(1, i.menu.hrefs.length) : "";
- window.open($(i.clientRedirectUri, r));
- } else
- t.push({ path: i.menu.hrefs });
- }, z = (i) => {
- a.value = i, O();
- }, O = () => se(this, null, function* () {
- S.value = !0;
- try {
- const i = yield Nt();
- a.value === 1 ? g.value = i.toDealList || [] : g.value = i.toReadList || [], u.value = i.toDealCount || 0, f.value = i.toReadCount || 0;
- } catch (i) {
- g.value = [], console.warn("[workplace] 待办消息获取失败:", i);
- } finally {
- S.value = !1;
- }
- }), A = (i) => se(this, null, function* () {
- I.value = !1, s.value = !0, yield Vt(i).then(() => {
- s.value = !1;
- }), x();
- }), m = (i) => se(this, null, function* () {
- s.value = !0, yield jt({ id: i.id }).then(() => {
- s.value = !1;
- }), x();
- }), w = (i = {}) => {
- if (i.messageTypeCode === "toRead" && Wt([i.id]), i.clientId === "flow") {
- const r = {
- client_id: `${window.$utils.env.VITE_APP_CLIENT_ID}`,
- scope: "snsapi_base"
- };
- Gt(r).then((c) => {
- const T = c && typeof c == "object" ? c.data : c;
- if (!T) {
- location.reload();
- return;
- }
- const D = `code=${T}`, y = r.state ? `&state=${r.state}` : "";
- let M = "";
- if (i.messageTypeCode === "toDeal" ? M = i.toDealUrl : i.messageTypeCode === "toRead" && (M = i.toReadUrl), M && M.includes("?")) {
- let R = `${D}${y}`;
- R && (R = `&${D}${y}`), window.open(M + R);
- } else {
- let R = `${D}${y}`;
- R && (R = `?${D}${y}`), window.open(M + R);
- }
- });
- } else {
- let r = "";
- i.messageTypeCode === "toDeal" ? r = i.toDealUrl : i.messageTypeCode === "toRead" && (r = i.toReadUrl), window.open(r);
- }
- };
- return dt(() => {
- x(), O();
- }), (i, r) => {
- const c = Tn, T = ie, D = fe, y = Ze, M = Xt, R = ot, p = ee;
- return P(), U("div", zn, [
- o(y, { spinning: s.value }, {
- default: B(() => [
- o(T, { class: "project-list" }, {
- title: B(() => [
- ve(_(i.$l("快捷导航")), 1)
- ]),
- extra: B(() => [
- !h.value && d.value.length > 0 ? (P(), U("a", {
- key: 0,
- onClick: r[0] || (r[0] = (v) => h.value = !0)
- }, _(i.$l("修改")), 1)) : ye("", !0),
- h.value ? (P(), U("a", {
- key: 1,
- onClick: r[1] || (r[1] = (v) => h.value = !1)
- }, _(i.$l("返回")), 1)) : ye("", !0),
- !h.value && d.value.length < 10 ? (P(), U("a", {
- key: 2,
- style: { "margin-left": "24px" },
- onClick: r[2] || (r[2] = (v) => I.value = !0)
- }, _(i.$l("添加")), 1)) : ye("", !0)
- ]),
- default: B(() => [
- d.value.length > 0 ? (P(), U("div", Pn, [
- (P(!0), U(be, null, Se(d.value, (v, L) => (P(), k(D, {
- class: "card-grid",
- key: L
- }, {
- default: B(() => [
- o(T, {
- bordered: !1,
- "body-style": { padding: 0, position: "relative" }
- }, {
- default: B(() => [
- G("div", {
- class: "card-item",
- onClick: (N) => E(v)
- }, [
- v.menu.icon ? (P(), k(qe(n(v.menu.icon)), { key: 1 })) : (P(), k(de(ue), { key: 0 })),
- G("a", null, _(v.menu.name), 1)
- ], 8, Bn),
- o(c, {
- title: i.$l("确认要移除此快捷导航吗?"),
- onConfirm: (N) => m(v),
- okText: i.$l("删除"),
- cancelText: i.$l("取消")
- }, {
- icon: B(() => [...r[7] || (r[7] = [
- G("span", null, null, -1)
- ])]),
- default: B(() => [
- h.value ? (P(), k(de(_t), {
- key: 0,
- class: "delete-menu"
- })) : ye("", !0)
- ]),
- _: 1
- }, 8, ["title", "onConfirm", "okText", "cancelText"])
- ]),
- _: 2
- }, 1024)
- ]),
- _: 2
- }, 1024))), 128))
- ])) : (P(), U("div", Mn, [
- G("img", { src: de(Fe) }, null, 8, Rn),
- G("h4", null, _(i.$l("您没有设置快捷导航")), 1)
- ]))
- ]),
- _: 1
- })
- ]),
- _: 1
- }, 8, ["spinning"]),
- o(y, { spinning: S.value }, {
- default: B(() => [
- o(T, {
- class: "project-list margin-top-20",
- "body-style": l
- }, {
- title: B(() => [
- G("div", Dn, [
- G("div", {
- class: We(["item", { "s-theme-color": a.value === 1 }]),
- onClick: r[3] || (r[3] = (v) => z(1))
- }, _(i.$l("待处理")) + "(" + _(u.value) + ") ", 3),
- G("div", {
- class: We(["item", { "s-theme-color": a.value === 2 }]),
- onClick: r[4] || (r[4] = (v) => z(2))
- }, _(i.$l("待阅读")) + "(" + _(f.value) + ") ", 3)
- ])
- ]),
- extra: B(() => [
- G("a", {
- onClick: r[5] || (r[5] = (v) => de(t).push({ path: "/message/index" }))
- }, _(i.$l("更多")), 1)
- ]),
- default: B(() => [
- g.value.length > 0 ? (P(), k(p, {
- key: 0,
- style: { "overflow-y": "scroll" },
- size: "large",
- class: "project-content"
- }, {
- default: B(() => [
- (P(!0), U(be, null, Se(g.value, (v, L) => (P(), k(R, { key: L }, {
- default: B(() => [
- G("div", Ln, [
- G("div", On, [
- G("span", null, [
- a.value === 1 ? (P(), k(M, {
- key: 0,
- color: "#2db7f5"
- }, {
- default: B(() => [
- ve(_(i.$l("待处理")), 1)
- ]),
- _: 1
- })) : (P(), k(M, {
- key: 1,
- color: "#2db7f5"
- }, {
- default: B(() => [
- ve(_(i.$l("待阅读")), 1)
- ]),
- _: 1
- })),
- G("a", {
- onClick: (N) => w(v),
- class: "pull-right"
- }, _(v.contentTitle), 9, _n)
- ]),
- G("span", Hn, _(v.createDate), 1)
- ])
- ])
- ]),
- _: 2
- }, 1024))), 128))
- ]),
- _: 1
- })) : (P(), U("div", Nn, [
- G("img", { src: de(Fe) }, null, 8, jn),
- G("h4", null, _(i.$l("没有消息")), 1)
- ]))
- ]),
- _: 1
- })
- ]),
- _: 1
- }, 8, ["spinning"]),
- o(wn, {
- value: I.value,
- "onUpdate:value": r[6] || (r[6] = (v) => I.value = v),
- selectedList: d.value,
- onDone: A
- }, null, 8, ["value", "selectedList"])
- ]);
- };
- }
- }, Zn = /* @__PURE__ */ Ot(Wn, [["__scopeId", "data-v-d2094ddd"]]);
- export {
- Zn as default
- };
|