PageSourceSearch

https://assets.mizui.com.br/322ad2a8-7037-4d0c-b51f-52c22c65a305/build/assets/history-Di3IbSTY.js

js mizui.com.br collected 2026-10-06 16:49:16 UTC 12,019 bytes, 259 lines download raw bytes

1import { A as e, At as t, F as n, Ft as r, I as i, M as a, Nt as o, Ot as s, Q as c, T as l, X as u, dt as d, et as f, j as p, k as m, nt as h, p as g } from "./app-D2qqcQOB.js";
2import { t as _ } from "./createLucideIcon-R12IKn2t.js";
3import { t as v } from "./arrow-left-BeqHchr9.js";
4import { o as ee } from "./UI-VJG4HnL6.js";
5import { i as y, r as te } from "./subscriptions-DLceZhmW.js";
6import { t as b } from "./circle-alert-6aX-mVE0.js";
7import { t as x } from "./circle-check-BvqIZBof.js";
8import { t as ne } from "./circle-x-CmvWtRVM.js";
9import { t as S } from "./clock-CQ76MNJ8.js";
10import { l as C, t as w } from "./AppShell-DrcR4qAx.js";
11import { t as T } from "./ProfileLayout-YPUPpFm-.js";
12import { t as re } from "./loader-circle-CiRUE-Sy.js";
13import { t as E } from "./package-BJZsXEWe.js";
14import { a as ie, i as ae, n as oe, r as se, t as ce } from "./TooltipTrigger-B20_syQZ.js";
15import { s as le } from "./user-U27cr3-Q.js";
16import { t as ue } from "./formatPrice-DJH1SHL0.js";
17import { t as de } from "./formatDate-BSzLB1bL.js";
18//#region node_modules/lucide-vue-next/dist/esm/icons/download.js
19var D = _("download", [
20	["path", {
21		d: "M12 15V3",
22		key: "m9g1x1"
23	}],
24	["path", {
25		d: "M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4",
26		key: "ih7n3h"
27	}],
28	["path", {
29		d: "m7 10 5 5 5-5",
30		key: "brsn70"
31	}]
32]), O = _("file-check-corner", [
33	["path", {
34		d: "M10.5 22H6a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.706.706l3.588 3.588A2.4 2.4 0 0 1 20 8v6",
35		key: "g5mvt7"
36	}],
37	["path", {
38		d: "M14 2v5a1 1 0 0 0 1 1h5",
39		key: "wfsgrz"
40	}],
41	["path", {
42		d: "m14 20 2 2 4-4",
43		key: "15kota"
44	}]
45]), k = _("file-x-corner", [
46	["path", {
47		d: "M11 22H6a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.706.706l3.588 3.588A2.4 2.4 0 0 1 20 8v5",
48		key: "1jo35a"
49	}],
50	["path", {
51		d: "M14 2v5a1 1 0 0 0 1 1h5",
52		key: "wfsgrz"
53	}],
54	["path", {
55		d: "m15 17 5 5",
56		key: "36xl1x"
57	}],
58	["path", {
59		d: "m20 17-5 5",
60		key: "vdz27y"
61	}]
62]), A = { class: "flex items-center gap-3 mb-6" }, j = { class: "text-2xl font-bold text-gray-900" }, M = { class: "mt-1 text-sm text-gray-400" }, N = {
63	key: 0,
64	class: "hidden sm:block overflow-x-auto rounded-xl border border-gray-200"
65}, P = { class: "w-full text-sm" }, F = { class: "border-b border-gray-100 bg-gray-50/80" }, I = { class: "px-4 py-3 text-left text-[11px] font-semibold text-gray-500 uppercase tracking-wide" }, L = { class: "px-4 py-3 text-left text-[11px] font-semibold text-gray-500 uppercase tracking-wide" }, R = { class: "px-4 py-3 text-left text-[11px] font-semibold text-gray-500 uppercase tracking-wide" }, z = { class: "px-4 py-3 text-left text-[11px] font-semibold text-gray-500 uppercase tracking-wide" }, B = { class: "px-4 py-3 text-left text-[11px] font-semibold text-gray-500 uppercase tracking-wide" }, V = { class: "px-4 py-3 text-left text-[11px] font-semibold text-gray-500 uppercase tracking-wide" }, H = { class: "px-4 py-3 text-left text-[11px] font-semibold text-gray-500 uppercase tracking-wide" }, fe = { class: "px-4 py-3 font-mono text-xs text-gray-500" }, pe = { class: "px-4 py-3" }, me = { class: "flex items-center -space-x-2" }, he = ["src", "alt"], ge = { class: "px-4 py-3 text-gray-500" }, _e = { class: "px-4 py-3 font-semibold text-gray-900" }, ve = { class: "px-4 py-3" }, ye = { class: "px-4 py-3" }, be = [
66	"href",
67	"title",
68	"aria-label"
69], xe = { class: "px-4 py-3 text-gray-500" }, Se = {
70	key: 1,
71	class: "sm:hidden space-y-3"
72}, Ce = { class: "flex items-center justify-between gap-3" }, we = { class: "flex items-center gap-2.5 min-w-0" }, Te = { class: "flex items-center -space-x-2 shrink-0" }, Ee = ["src", "alt"], De = { class: "min-w-0" }, Oe = { class: "text-sm font-semibold text-gray-900 truncate" }, ke = { class: "text-xs text-gray-400" }, Ae = { class: "font-mono" }, je = { class: "text-sm font-bold text-gray-900 shrink-0" }, Me = { class: "flex items-center justify-between gap-2 mt-3 pt-3 border-t border-gray-100" }, Ne = { class: "flex items-center gap-1.5 flex-wrap" }, Pe = [
73	"href",
74	"title",
75	"aria-label"
76], Fe = { class: "text-xs text-gray-400 shrink-0" }, Ie = {
77	key: 3,
78	class: "flex flex-col items-center justify-center gap-3 rounded-xl border border-dashed border-gray-200 py-16 text-center"
79}, Le = { class: "flex h-14 w-14 items-center justify-center rounded-full bg-gray-100 text-gray-400" }, U = { class: "text-base font-semibold text-gray-900" }, Re = { class: "text-sm text-gray-400" }, W = Object.assign({ layout: [w, T] }, {
80	__name: "history",
81	props: { charges: {
82		type: Object,
83		default: () => ({
84			data: [],
85			links: []
86		})
87	} },
88	setup(_) {
89		let { formatPrice: w } = ue(), T = g(), W = {
90			paid: x,
91			refunded: v,
92			failed: ne,
93			processing: S,
94			pending: b
95		}, G = Object.fromEntries(Object.entries(te).map(([e, t]) => [e, {
96			...t,
97			icon: W[e] || b
98		}])), K = (e) => G[e] || G.pending, ze = {
99			issued: O,
100			processing: re,
101			pending: C,
102			error: k,
103			cancelled: k
104		}, Be = { processing: "animate-spin" }, q = Object.fromEntries(Object.entries(y).map(([e, t]) => [e, {
105			...t,
106			icon: ze[e] || C,
107			iconClass: Be[e] ?? ""
108		}])), J = (e) => q[e] || q.pending, Y = (e) => !e && e !== 0 ? "—" : w(e, { is_free: !1 }), X = (e) => de(e, T.props.locale) ?? "—", Z = (e) => {
109			e && r.get(e);
110		}, Q = (e) => e.apps?.length ? e.apps : [{
111			name: e.app_name,
112			logo: e.app_logo
113		}], $ = (e) => Q(e).map((e) => e.name).join(", ");
114		return (r, g) => {
115			let y = f("Link");
116			return u(), a(l, null, [
117				m("div", A, [i(y, {
118					href: s(le).url(),
119					class: "flex h-8 w-8 items-center justify-center rounded-lg text-gray-400 hover:bg-gray-100 hover:text-gray-600 transition"
120				}, {
121					default: d(() => [i(s(v), { size: 18 })]),
122					_: 1
123				}, 8, ["href"]), m("div", null, [m("h1", j, o(r.$t("profile.history.title")), 1), m("p", M, o(r.$t("profile.history.subtitle")), 1)])]),
124				_.charges.data?.length ? (u(), a("div", N, [m("table", P, [m("thead", null, [m("tr", F, [
125					m("th", I, o(r.$t("profile.history.order")), 1),
126					m("th", L, o(r.$t("profile.history.app")), 1),
127					m("th", R, o(r.$t("profile.history.plan")), 1),
128					m("th", z, o(r.$t("profile.history.value")), 1),
129					m("th", B, o(r.$t("profile.history.status")), 1),
130					m("th", V, o(r.$t("profile.history.invoice")), 1),
131					m("th", H, o(r.$t("profile.history.date")), 1)
132				])]), m("tbody", null, [(u(!0), a(l, null, c(_.charges.data, (f) => (u(), a("tr", {
133					key: f.id,
134					class: "border-b border-gray-50 last:border-0 hover:bg-gray-50/50 transition-colors"
135				}, [
136					m("td", fe, "#" + o(f.id), 1),
137					m("td", pe, [i(s(ae), null, {
138						default: d(() => [i(s(ce), { "as-child": "" }, {
139							default: d(() => [m("div", me, [(u(!0), a(l, null, c(Q(f), (t, n) => (u(), a("div", {
140								key: n,
141								class: "flex h-8 w-8 shrink-0 items-center justify-center rounded-lg bg-gray-50 border border-white overflow-hidden"
142							}, [t.logo ? (u(), a("img", {
143								key: 0,
144								src: t.logo,
145								alt: t.name,
146								class: "h-full w-full object-contain"
147							}, null, 8, he)) : (u(), e(s(E), {
148								key: 1,
149								size: 16,
150								class: "text-gray-300"
151							}))]))), 128))])]),
152							_: 2
153						}, 1024), i(s(oe), null, {
154							default: d(() => [i(s(se), {
155								side: "top",
156								"side-offset": 6,
157								class: "rounded-lg bg-gray-900 px-3 py-1.5 text-xs font-medium text-white shadow-lg select-none animate-in fade-in-0 zoom-in-95"
158							}, {
159								default: d(() => [n(o($(f)) + " ", 1), i(s(ie), { class: "fill-gray-900" })]),
160								_: 2
161							}, 1024)]),
162							_: 2
163						}, 1024)]),
164						_: 2
165					}, 1024)]),
166					m("td", ge, o(f.plan_name || "—"), 1),
167					m("td", _e, o(Y(f.amount)), 1),
168					m("td", ve, [m("span", { class: t(["inline-flex items-center gap-1 rounded-md px-2 py-0.5 text-[11px] font-semibold", K(f.status).class]) }, [(u(), e(h(K(f.status).icon), { size: 11 })), n(" " + o(r.$t(K(f.status).label)), 1)], 2)]),
169					m("td", ye, [f.nfse_url ? (u(), a("a", {
170						key: 0,
171						href: f.nfse_url,
172						target: "_blank",
173						rel: "noopener noreferrer",
174						class: t(["inline-flex items-center gap-1 rounded-md px-2 py-0.5 text-[11px] font-semibold transition hover:opacity-80 cursor-pointer", J(f.nfse_status).class]),
175						title: r.$t("profile.history.download"),
176						"aria-label": r.$t("profile.history.download")
177					}, [
178						(u(), e(h(J(f.nfse_status).icon), {
179							size: 11,
180							class: t(J(f.nfse_status).iconClass)
181						}, null, 8, ["class"])),
182						n(" " + o(r.$t(J(f.nfse_status).label)) + " ", 1),
183						i(s(D), {
184							size: 11,
185							class: "ml-0.5 opacity-70"
186						})
187					], 10, be)) : (u(), a("span", {
188						key: 1,
189						class: t(["inline-flex items-center gap-1 rounded-md px-2 py-0.5 text-[11px] font-semibold", J(f.nfse_status).class])
190					}, [(u(), e(h(J(f.nfse_status).icon), {
191						size: 11,
192						class: t(J(f.nfse_status).iconClass)
193					}, null, 8, ["class"])), n(" " + o(r.$t(J(f.nfse_status).label)), 1)], 2))]),
194					m("td", xe, o(X(f.paid_at || f.created_at)), 1)
195				]))), 128))])])])) : p("", !0),
196				_.charges.data?.length ? (u(), a("div", Se, [(u(!0), a(l, null, c(_.charges.data, (d) => (u(), a("div", {
197					key: d.id,
198					class: "rounded-xl border border-gray-200 bg-white p-3"
199				}, [m("div", Ce, [m("div", we, [m("div", Te, [(u(!0), a(l, null, c(Q(d), (t, n) => (u(), a("div", {
200					key: n,
201					class: "flex h-9 w-9 shrink-0 items-center justify-center rounded-lg bg-gray-50 border border-white overflow-hidden"
202				}, [t.logo ? (u(), a("img", {
203					key: 0,
204					src: t.logo,
205					alt: t.name,
206					class: "h-full w-full object-contain"
207				}, null, 8, Ee)) : (u(), e(s(E), {
208					key: 1,
209					size: 16,
210					class: "text-gray-300"
211				}))]))), 128))]), m("div", De, [m("p", Oe, o($(d)), 1), m("p", ke, [
212					n(o(d.plan_name || "—") + " ", 1),
213					g[2] ||= m("span", { class: "text-gray-300 mx-0.5" }, "·", -1),
214					m("span", Ae, "#" + o(d.id), 1)
215				])])]), m("p", je, o(Y(d.amount)), 1)]), m("div", Me, [m("div", Ne, [m("span", { class: t(["inline-flex items-center gap-1 rounded-md px-2 py-0.5 text-[11px] font-semibold", K(d.status).class]) }, [(u(), e(h(K(d.status).icon), { size: 11 })), n(" " + o(r.$t(K(d.status).label)), 1)], 2), d.nfse_url ? (u(), a("a", {
216					key: 0,
217					href: d.nfse_url,
218					target: "_blank",
219					rel: "noopener noreferrer",
220					class: t(["inline-flex items-center gap-1 rounded-md px-2 py-0.5 text-[11px] font-semibold transition hover:opacity-80 curs
220or-pointer", J(d.nfse_status).class]),
221					title: r.$t("profile.history.download"),
222					"aria-label": r.$t("profile.history.download")
223				}, [
224					(u(), e(h(J(d.nfse_status).icon), {
225						size: 11,
226						class: t(J(d.nfse_status).iconClass)
227					}, null, 8, ["class"])),
228					n(" " + o(r.$t(J(d.nfse_status).label)) + " ", 1),
229					i(s(D), {
230						size: 11,
231						class: "ml-0.5 opacity-70"
232					})
233				], 10, Pe)) : (u(), a("span", {
234					key: 1,
235					class: t(["inline-flex items-center gap-1 rounded-md px-2 py-0.5 text-[11px] font-semibold", J(d.nfse_status).class])
236				}, [(u(), e(h(J(d.nfse_status).icon), {
237					size: 11,
238					class: t(J(d.nfse_status).iconClass)
239				}, null, 8, ["class"])), n(" " + o(r.$t(J(d.nfse_status).label)), 1)], 2))]), m("p", Fe, o(X(d.paid_at || d.created_at)), 1)])]))), 128))])) : p("", !0),
240				_.charges.last_page > 1 ? (u(), e(s(ee), {
241					key: 2,
242					"current-page": _.charges.current_page,
243					"total-pages": _.charges.last_page,
244					variant: "full",
245					class: "mt-4",
246					onPrev: g[0] ||= (e) => Z(_.charges.prev_page_url),
247					onNext: g[1] ||= (e) => Z(_.charges.next_page_url)
248				}, null, 8, ["current-page", "total-pages"])) : p("", !0),
249				_.charges.data?.length ? p("", !0) : (u(), a("div", Ie, [
250					m("div", Le, [i(s(S), { size: 24 })]),
251					m("h3", U, o(r.$t("profile.history.no_charges")), 1),
252					m("p", Re, o(r.$t("profile.history.no_charges_description")), 1)
253				]))
254			], 64);
255		};
256	}
257});
258//#endregion
259export { W as default };

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.