beca-ui 0.1.6 → 0.1.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/beca-ui.js +35 -24
- package/package.json +1 -1
package/dist/beca-ui.js
CHANGED
|
@@ -57397,16 +57397,21 @@ function AWe(e) {
|
|
|
57397
57397
|
}, r);
|
|
57398
57398
|
}
|
|
57399
57399
|
const WA = () => ({ t: IWe().t }), $We = (e) => {
|
|
57400
|
-
const { t } = WA(), {
|
|
57400
|
+
const { t } = WA(), {
|
|
57401
|
+
applicationsCardData: n,
|
|
57402
|
+
data: r,
|
|
57403
|
+
title: a = t("Notifications"),
|
|
57404
|
+
onClickNotificationItem: i
|
|
57405
|
+
} = e, [o, l] = Yt(
|
|
57401
57406
|
[]
|
|
57402
|
-
), [
|
|
57407
|
+
), [s, u] = Yt([]), [d, p] = Yt([]);
|
|
57403
57408
|
mn(() => {
|
|
57404
|
-
const
|
|
57405
|
-
r.forEach((
|
|
57406
|
-
|
|
57407
|
-
}),
|
|
57409
|
+
const y = [], b = [], w = [];
|
|
57410
|
+
r.forEach((S) => {
|
|
57411
|
+
S.type === "Chat" ? b.push(S) : y.push(S), S.isSeen !== !0 && w.push(S);
|
|
57412
|
+
}), l(y), u(b), p(w);
|
|
57408
57413
|
}, [r]);
|
|
57409
|
-
const
|
|
57414
|
+
const v = [
|
|
57410
57415
|
{
|
|
57411
57416
|
key: "all",
|
|
57412
57417
|
label: t("All"),
|
|
@@ -57414,12 +57419,13 @@ const WA = () => ({ t: IWe().t }), $We = (e) => {
|
|
|
57414
57419
|
v9,
|
|
57415
57420
|
{
|
|
57416
57421
|
itemLayout: "horizontal",
|
|
57417
|
-
dataSource:
|
|
57418
|
-
renderItem: (
|
|
57422
|
+
dataSource: o,
|
|
57423
|
+
renderItem: (y) => /* @__PURE__ */ L(
|
|
57419
57424
|
K_,
|
|
57420
57425
|
{
|
|
57421
|
-
item:
|
|
57422
|
-
applicationsCardData: n
|
|
57426
|
+
item: y,
|
|
57427
|
+
applicationsCardData: n,
|
|
57428
|
+
onClickNotificationItem: i
|
|
57423
57429
|
}
|
|
57424
57430
|
)
|
|
57425
57431
|
}
|
|
@@ -57430,18 +57436,19 @@ const WA = () => ({ t: IWe().t }), $We = (e) => {
|
|
|
57430
57436
|
label: /* @__PURE__ */ pn("div", { children: [
|
|
57431
57437
|
t("Unread"),
|
|
57432
57438
|
" ",
|
|
57433
|
-
/* @__PURE__ */ L(a9, { count:
|
|
57439
|
+
/* @__PURE__ */ L(a9, { count: d.length })
|
|
57434
57440
|
] }),
|
|
57435
57441
|
children: /* @__PURE__ */ L("div", { className: "notification-popup-body", children: /* @__PURE__ */ L(
|
|
57436
57442
|
v9,
|
|
57437
57443
|
{
|
|
57438
57444
|
itemLayout: "horizontal",
|
|
57439
|
-
dataSource:
|
|
57440
|
-
renderItem: (
|
|
57445
|
+
dataSource: d,
|
|
57446
|
+
renderItem: (y) => /* @__PURE__ */ L(
|
|
57441
57447
|
K_,
|
|
57442
57448
|
{
|
|
57443
|
-
item:
|
|
57444
|
-
applicationsCardData: n
|
|
57449
|
+
item: y,
|
|
57450
|
+
applicationsCardData: n,
|
|
57451
|
+
onClickNotificationItem: i
|
|
57445
57452
|
}
|
|
57446
57453
|
)
|
|
57447
57454
|
}
|
|
@@ -57454,12 +57461,13 @@ const WA = () => ({ t: IWe().t }), $We = (e) => {
|
|
|
57454
57461
|
v9,
|
|
57455
57462
|
{
|
|
57456
57463
|
itemLayout: "horizontal",
|
|
57457
|
-
dataSource:
|
|
57458
|
-
renderItem: (
|
|
57464
|
+
dataSource: s,
|
|
57465
|
+
renderItem: (y) => /* @__PURE__ */ L(
|
|
57459
57466
|
K_,
|
|
57460
57467
|
{
|
|
57461
|
-
item:
|
|
57462
|
-
applicationsCardData: n
|
|
57468
|
+
item: y,
|
|
57469
|
+
applicationsCardData: n,
|
|
57470
|
+
onClickNotificationItem: i
|
|
57463
57471
|
}
|
|
57464
57472
|
)
|
|
57465
57473
|
}
|
|
@@ -57468,15 +57476,18 @@ const WA = () => ({ t: IWe().t }), $We = (e) => {
|
|
|
57468
57476
|
];
|
|
57469
57477
|
return /* @__PURE__ */ pn("div", { className: "notification-popup", children: [
|
|
57470
57478
|
/* @__PURE__ */ L("div", { className: "notification-popup-header", children: /* @__PURE__ */ L("div", { className: "notification-popup-header__title", children: a }) }),
|
|
57471
|
-
/* @__PURE__ */ L(vit, { defaultActiveKey: "1", items:
|
|
57479
|
+
/* @__PURE__ */ L(vit, { defaultActiveKey: "1", items: v })
|
|
57472
57480
|
] });
|
|
57473
57481
|
}, K_ = (e) => {
|
|
57474
|
-
var
|
|
57475
|
-
const { applicationsCardData: t, item: n } = e;
|
|
57482
|
+
var a, i;
|
|
57483
|
+
const { applicationsCardData: t, item: n, onClickNotificationItem: r } = e;
|
|
57476
57484
|
return /* @__PURE__ */ L(
|
|
57477
57485
|
v9.Item,
|
|
57478
57486
|
{
|
|
57479
57487
|
className: "notification-item" + (n.isSeen ? " is-read" : ""),
|
|
57488
|
+
onClick: () => {
|
|
57489
|
+
r && r(n);
|
|
57490
|
+
},
|
|
57480
57491
|
children: /* @__PURE__ */ L("a", { href: n.url ?? "#", children: /* @__PURE__ */ L(
|
|
57481
57492
|
v9.Item.Meta,
|
|
57482
57493
|
{
|
|
@@ -57486,7 +57497,7 @@ const WA = () => ({ t: IWe().t }), $We = (e) => {
|
|
|
57486
57497
|
"img",
|
|
57487
57498
|
{
|
|
57488
57499
|
className: "notification-item__icon",
|
|
57489
|
-
src: (
|
|
57500
|
+
src: (i = (a = t.find((o) => o.appId === n.type)) == null ? void 0 : a.image) == null ? void 0 : i.toString()
|
|
57490
57501
|
}
|
|
57491
57502
|
),
|
|
57492
57503
|
n.from
|