@bbki.ng/components 5.1.1 → 5.1.2

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.
Files changed (2) hide show
  1. package/dist/link/Link.mjs +40 -37
  2. package/package.json +2 -2
@@ -1,31 +1,34 @@
1
- import s from "../node_modules/.pnpm/classnames@2.3.1/node_modules/classnames/index.mjs";
2
- import { Link as y } from "react-router-dom";
1
+ import n from "../node_modules/.pnpm/classnames@2.3.1/node_modules/classnames/index.mjs";
2
+ import { Link as p } from "react-router-dom";
3
3
  import { BlinkDot as l } from "../blink-dot/BlinkDot.mjs";
4
- import { jsx as t, jsxs as c, Fragment as d } from "../_virtual/jsx-runtime.mjs";
4
+ import { jsx as r, jsxs as c, Fragment as i } from "../_virtual/jsx-runtime.mjs";
5
5
  var x = /* @__PURE__ */ ((e) => (e.BLUE = "blue", e.RED = "red", e.GRAY = "gray", e))(x || {});
6
6
  const h = {
7
7
  blue: "text-blue-600",
8
- red: "text-red-500",
8
+ red: "text-yy-pink-150",
9
9
  gray: "text-gray-400"
10
- }, p = {
10
+ }, N = {
11
11
  blue: "md:not-focus:hover:bg-blue-100 md:not-focus:hover:text-blue-600",
12
- red: "md:not-focus:hover:bg-red-100 md:not-focus:hover:text-red-500",
12
+ red: "md:not-focus:hover:bg-yy-pink-50 md:not-focus:hover:text-yy-pink-150",
13
13
  gray: "md:not-focus:hover:bg-gray-100 md:not-focus:hover:text-gray-400"
14
- }, N = {
14
+ }, k = {
15
15
  blue: "focus:bg-blue-100",
16
- red: "focus:bg-red-100",
16
+ red: "focus:bg-yy-pink-50",
17
17
  gray: "focus:bg-gray-100"
18
18
  }, R = (e) => {
19
19
  const {
20
- color: o = "blue",
21
- external: u,
22
- className: i,
23
- children: r,
24
- status: n,
25
- readonly: m,
26
- ...f
27
- } = e, a = s(
28
- i,
20
+ color: u = "blue",
21
+ external: d,
22
+ className: f,
23
+ children: t,
24
+ status: s,
25
+ readonly: g,
26
+ ...m
27
+ } = e;
28
+ let o = u;
29
+ typeof t == "string" && t.includes("小乌鸦") && (o = "red");
30
+ const a = n(
31
+ f,
29
32
  "rounded-sm",
30
33
  "no-underline!",
31
34
  "inline-block",
@@ -33,11 +36,11 @@ const h = {
33
36
  "active:scale-[0.97]",
34
37
  // "focus:text-white",
35
38
  h[o],
36
- p[o],
37
- N[o]
39
+ N[o],
40
+ k[o]
38
41
  );
39
- if (u)
40
- return /* @__PURE__ */ t("a", {
42
+ if (d)
43
+ return /* @__PURE__ */ r("a", {
41
44
  href: e.to,
42
45
  className: a,
43
46
  target: "_blank",
@@ -45,35 +48,35 @@ const h = {
45
48
  style: {
46
49
  padding: 4
47
50
  },
48
- children: r
51
+ children: t
49
52
  });
50
- if (m) {
51
- const g = !/^[a-zA-Z~]+$/.test(r), b = s({
52
- "relative top-[2px]": g
53
+ if (g) {
54
+ const y = !/^[a-zA-Z~]+$/.test(t), b = n({
55
+ "relative top-[2px]": y
53
56
  });
54
- return /* @__PURE__ */ c(d, {
55
- children: [/* @__PURE__ */ t("span", {
56
- className: s("text-gray-400", b),
57
+ return /* @__PURE__ */ c(i, {
58
+ children: [/* @__PURE__ */ r("span", {
59
+ className: n("text-gray-400", b),
57
60
  style: {
58
61
  padding: 4
59
62
  },
60
- children: r
61
- }), /* @__PURE__ */ t(l, {
62
- status: n
63
+ children: t
64
+ }), /* @__PURE__ */ r(l, {
65
+ status: s
63
66
  })]
64
67
  });
65
68
  }
66
- return /* @__PURE__ */ c(d, {
67
- children: [/* @__PURE__ */ t(y, {
68
- ...f,
69
+ return /* @__PURE__ */ c(i, {
70
+ children: [/* @__PURE__ */ r(p, {
71
+ ...m,
69
72
  className: a,
70
73
  style: {
71
74
  padding: 4
72
75
  },
73
- children: r
74
- }), /* @__PURE__ */ t(l, {
76
+ children: t
77
+ }), /* @__PURE__ */ r(l, {
75
78
  className: "-top-3 left-1",
76
- status: n
79
+ status: s
77
80
  })]
78
81
  });
79
82
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bbki.ng/components",
3
- "version": "5.1.1",
3
+ "version": "5.1.2",
4
4
  "type": "module",
5
5
  "files": [
6
6
  "dist"
@@ -35,7 +35,7 @@
35
35
  "classnames": "2.3.1",
36
36
  "phenomenon": "^1.6.0",
37
37
  "react-hook-form": "7.54.2",
38
- "@bbki.ng/stylebase": "3.0.0"
38
+ "@bbki.ng/stylebase": "3.0.1"
39
39
  },
40
40
  "devDependencies": {
41
41
  "@babel/core": "^7.18.9",