@haklex/rich-renderer-linkcard 0.6.2 → 0.8.0

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.
@@ -1,4 +1,4 @@
1
- import { Globe, Star } from "lucide-react";
1
+ import { BookText, CheckCircle2, CircleDot, Disc3, Flame, GitCommitHorizontal, GitMerge, GitPullRequest, GitPullRequestClosed, Globe, MessagesSquare, Mic2, Percent, Star, Tag, ThumbsUp, Unlink, Users } from "lucide-react";
2
2
  import { createContext, use, useCallback, useEffect, useMemo, useRef, useState } from "react";
3
3
  import { vars } from "@haklex/rich-style-token";
4
4
  import { Fragment, jsx, jsxs } from "react/jsx-runtime";
@@ -8,7 +8,7 @@ var arxivPlugin = {
8
8
  name: "arxiv",
9
9
  displayName: "arXiv Paper",
10
10
  priority: 80,
11
- typeClass: "academic",
11
+ shape: "expanded",
12
12
  matchUrl(url) {
13
13
  if (url.hostname !== "arxiv.org") return null;
14
14
  const match = url.pathname.match(/\/(abs|pdf)\/(\d{4}\.\d+(?:v\d+)?)/i);
@@ -39,25 +39,35 @@ var arxivPlugin = {
39
39
  children: title
40
40
  }), /* @__PURE__ */ jsx("span", {
41
41
  style: { flexShrink: 0 },
42
- children: /* @__PURE__ */ jsx("span", {
42
+ children: /* @__PURE__ */ jsxs("span", {
43
43
  style: {
44
44
  display: "inline-flex",
45
45
  alignItems: "center",
46
46
  gap: "4px",
47
- fontSize: vars.typography.fontSizeMd,
48
- color: "#fb923c"
47
+ fontSize: vars.typography.fontSizeXs,
48
+ fontFamily: vars.typography.fontMono,
49
+ color: "#a3a3a3"
49
50
  },
50
- children: /* @__PURE__ */ jsx("span", {
51
- style: {
52
- fontFamily: "sans-serif",
53
- fontWeight: 500
54
- },
55
- children: id
56
- })
51
+ children: [/* @__PURE__ */ jsx(BookText, {
52
+ "aria-hidden": true,
53
+ size: 12,
54
+ strokeWidth: 2
55
+ }), id]
57
56
  })
58
57
  })]
59
58
  }),
60
- desc: authorNames.length > 1 ? `${authorNames[0]} et al.` : authorNames[0]
59
+ desc: /* @__PURE__ */ jsxs("span", {
60
+ style: {
61
+ display: "inline-flex",
62
+ alignItems: "center",
63
+ gap: "6px"
64
+ },
65
+ children: [/* @__PURE__ */ jsx(Users, {
66
+ "aria-hidden": true,
67
+ size: 13,
68
+ strokeWidth: 2
69
+ }), authorNames.length > 1 ? `${authorNames[0]} et al.` : authorNames[0]]
70
+ })
61
71
  };
62
72
  }
63
73
  };
@@ -159,7 +169,7 @@ var leetcodePlugin = {
159
169
  name: "leetcode",
160
170
  displayName: "LeetCode",
161
171
  priority: 65,
162
- typeClass: "wide",
172
+ shape: "wide",
163
173
  provider: "leetcode",
164
174
  matchUrl(url) {
165
175
  if (url.hostname !== "leetcode.cn" && url.hostname !== "leetcode.com") return null;
@@ -203,7 +213,11 @@ var leetcodePlugin = {
203
213
  fontSize: vars.typography.fontSizeMd,
204
214
  color: "#fb923c"
205
215
  },
206
- children: ["👍", /* @__PURE__ */ jsx("span", {
216
+ children: [/* @__PURE__ */ jsx(ThumbsUp, {
217
+ "aria-hidden": true,
218
+ size: 13,
219
+ strokeWidth: 2
220
+ }), /* @__PURE__ */ jsx("span", {
207
221
  style: {
208
222
  fontFamily: "sans-serif",
209
223
  fontWeight: 500
@@ -213,27 +227,58 @@ var leetcodePlugin = {
213
227
  })
214
228
  })]
215
229
  }),
216
- desc: /* @__PURE__ */ jsxs(Fragment, { children: [
217
- /* @__PURE__ */ jsx("span", {
218
- style: {
219
- marginRight: "16px",
220
- fontWeight: "bold",
221
- color: getDifficultyColor(questionTitleData.difficulty)
222
- },
223
- children: questionTitleData.difficulty
224
- }),
225
- /* @__PURE__ */ jsx("span", {
226
- style: { overflow: "hidden" },
227
- children: questionTitleData.topicTags.map((tag) => tag.translatedName).join(" / ")
228
- }),
229
- /* @__PURE__ */ jsxs("span", {
230
- style: {
231
- float: "right",
232
- overflow: "hidden"
233
- },
234
- children: ["AR: ", stats.acRate]
235
- })
236
- ] }),
230
+ desc: /* @__PURE__ */ jsxs("span", {
231
+ style: {
232
+ display: "flex",
233
+ alignItems: "center",
234
+ gap: "14px",
235
+ flexWrap: "wrap"
236
+ },
237
+ children: [
238
+ /* @__PURE__ */ jsxs("span", {
239
+ style: {
240
+ display: "inline-flex",
241
+ alignItems: "center",
242
+ gap: "4px",
243
+ fontWeight: 600,
244
+ color: getDifficultyColor(questionTitleData.difficulty)
245
+ },
246
+ children: [/* @__PURE__ */ jsx(Flame, {
247
+ "aria-hidden": true,
248
+ size: 13,
249
+ strokeWidth: 2
250
+ }), questionTitleData.difficulty]
251
+ }),
252
+ /* @__PURE__ */ jsxs("span", {
253
+ style: {
254
+ display: "inline-flex",
255
+ alignItems: "center",
256
+ gap: "4px",
257
+ overflow: "hidden",
258
+ textOverflow: "ellipsis"
259
+ },
260
+ children: [/* @__PURE__ */ jsx(Tag, {
261
+ "aria-hidden": true,
262
+ size: 12,
263
+ strokeWidth: 2
264
+ }), questionTitleData.topicTags.map((tag) => tag.translatedName).join(" / ")]
265
+ }),
266
+ /* @__PURE__ */ jsxs("span", {
267
+ style: {
268
+ marginLeft: "auto",
269
+ display: "inline-flex",
270
+ alignItems: "center",
271
+ gap: "4px",
272
+ color: "#a3a3a3"
273
+ },
274
+ children: [/* @__PURE__ */ jsx(Percent, {
275
+ "aria-hidden": true,
276
+ size: 12,
277
+ strokeWidth: 2
278
+ }), stats.acRate]
279
+ })
280
+ ]
281
+ }),
237
282
  image: "https://upload.wikimedia.org/wikipedia/commons/1/19/LeetCode_logo_black.png",
238
283
  color: getDifficultyColor(questionTitleData.difficulty)
239
284
  };
@@ -245,7 +290,7 @@ var githubCommitPlugin = {
245
290
  name: "gh-commit",
246
291
  displayName: "GitHub Commit",
247
292
  priority: 95,
248
- typeClass: "github",
293
+ shape: "compact",
249
294
  provider: "github",
250
295
  matchUrl(url) {
251
296
  if (url.hostname !== "github.com") return null;
@@ -292,9 +337,18 @@ var githubCommitPlugin = {
292
337
  children: ["-", data.stats.deletions]
293
338
  })]
294
339
  }),
295
- /* @__PURE__ */ jsx("span", {
296
- style: { fontSize: vars.typography.fontSizeMd },
297
- children: data.sha.slice(0, 7)
340
+ /* @__PURE__ */ jsxs("span", {
341
+ style: {
342
+ display: "inline-flex",
343
+ alignItems: "center",
344
+ gap: "4px",
345
+ fontSize: vars.typography.fontSizeMd
346
+ },
347
+ children: [/* @__PURE__ */ jsx(GitCommitHorizontal, {
348
+ "aria-hidden": true,
349
+ size: 13,
350
+ strokeWidth: 2
351
+ }), data.sha.slice(0, 7)]
298
352
  }),
299
353
  /* @__PURE__ */ jsxs("span", {
300
354
  style: {
@@ -319,7 +373,7 @@ var githubDiscussionPlugin = {
319
373
  name: "gh-discussion",
320
374
  displayName: "GitHub Discussion",
321
375
  priority: 95,
322
- typeClass: "github",
376
+ shape: "compact",
323
377
  provider: "github",
324
378
  matchUrl(url) {
325
379
  if (url.hostname !== "github.com") return null;
@@ -352,14 +406,21 @@ var githubDiscussionPlugin = {
352
406
  gap: "4px 12px",
353
407
  fontFamily: vars.typography.fontMono
354
408
  },
355
- children: [/* @__PURE__ */ jsx("span", {
409
+ children: [/* @__PURE__ */ jsxs("span", {
356
410
  style: {
411
+ display: "inline-flex",
412
+ alignItems: "center",
413
+ gap: "4px",
357
414
  borderRadius: "4px",
358
415
  backgroundColor: "rgba(128,128,128,0.15)",
359
416
  padding: "2px 6px",
360
417
  fontSize: vars.typography.fontSizeXs
361
418
  },
362
- children: categoryName
419
+ children: [/* @__PURE__ */ jsx(MessagesSquare, {
420
+ "aria-hidden": true,
421
+ size: 11,
422
+ strokeWidth: 2
423
+ }), categoryName]
363
424
  }), /* @__PURE__ */ jsxs("span", {
364
425
  style: {
365
426
  fontSize: vars.typography.fontSizeMd,
@@ -383,7 +444,7 @@ var githubDiscussionPlugin = {
383
444
  //#region src/plugins/github/issue.tsx
384
445
  var stateColors = {
385
446
  open: "#238636",
386
- closed: "#f85149"
447
+ closed: "#8957e5"
387
448
  };
388
449
  var stateTextMap$1 = {
389
450
  open: "Open",
@@ -393,7 +454,7 @@ var githubIssuePlugin = {
393
454
  name: "gh-issue",
394
455
  displayName: "GitHub Issue",
395
456
  priority: 95,
396
- typeClass: "github",
457
+ shape: "compact",
397
458
  provider: "github",
398
459
  matchUrl(url) {
399
460
  if (url.hostname !== "github.com") return null;
@@ -417,6 +478,7 @@ var githubIssuePlugin = {
417
478
  const data = camelcaseKeys(await fetchGitHubApi(`https://api.github.com/repos/${owner}/${repo}/issues/${issueNumber}`, context));
418
479
  const color = stateColors[data.state] || "#6b7280";
419
480
  const stateText = stateTextMap$1[data.state] || data.state;
481
+ const StateIcon = data.state === "closed" ? CheckCircle2 : CircleDot;
420
482
  return {
421
483
  title: `Issue: ${data.title}`,
422
484
  color,
@@ -428,9 +490,18 @@ var githubIssuePlugin = {
428
490
  gap: "4px 12px",
429
491
  fontFamily: vars.typography.fontMono
430
492
  },
431
- children: [/* @__PURE__ */ jsx("span", {
432
- style: { color },
433
- children: stateText
493
+ children: [/* @__PURE__ */ jsxs("span", {
494
+ style: {
495
+ display: "inline-flex",
496
+ alignItems: "center",
497
+ gap: "4px",
498
+ color
499
+ },
500
+ children: [/* @__PURE__ */ jsx(StateIcon, {
501
+ "aria-hidden": true,
502
+ size: 13,
503
+ strokeWidth: 2
504
+ }), stateText]
434
505
  }), /* @__PURE__ */ jsxs("span", {
435
506
  style: {
436
507
  fontSize: vars.typography.fontSizeMd,
@@ -466,11 +537,16 @@ var stateTextMap = {
466
537
  merged: "Merged",
467
538
  closed: "Closed"
468
539
  };
540
+ var stateIconMap = {
541
+ open: GitPullRequest,
542
+ merged: GitMerge,
543
+ closed: GitPullRequestClosed
544
+ };
469
545
  var githubPrPlugin = {
470
546
  name: "gh-pr",
471
547
  displayName: "GitHub Pull Request",
472
548
  priority: 95,
473
- typeClass: "github",
549
+ shape: "compact",
474
550
  provider: "github",
475
551
  matchUrl(url) {
476
552
  if (url.hostname !== "github.com") return null;
@@ -493,6 +569,7 @@ var githubPrPlugin = {
493
569
  const state = getPrState(data);
494
570
  const color = stateColorMap[state];
495
571
  const stateText = stateTextMap[state];
572
+ const StateIcon = stateIconMap[state];
496
573
  return {
497
574
  title: `PR: ${data.title}`,
498
575
  color,
@@ -505,9 +582,18 @@ var githubPrPlugin = {
505
582
  fontFamily: vars.typography.fontMono
506
583
  },
507
584
  children: [
508
- /* @__PURE__ */ jsx("span", {
509
- style: { color },
510
- children: stateText
585
+ /* @__PURE__ */ jsxs("span", {
586
+ style: {
587
+ display: "inline-flex",
588
+ alignItems: "center",
589
+ gap: "4px",
590
+ color
591
+ },
592
+ children: [/* @__PURE__ */ jsx(StateIcon, {
593
+ "aria-hidden": true,
594
+ size: 13,
595
+ strokeWidth: 2
596
+ }), stateText]
511
597
  }),
512
598
  /* @__PURE__ */ jsxs("span", {
513
599
  style: {
@@ -550,7 +636,7 @@ var githubRepoPlugin = {
550
636
  name: "gh-repo",
551
637
  displayName: "GitHub Repository",
552
638
  priority: 100,
553
- typeClass: "github",
639
+ shape: "compact",
554
640
  provider: "github",
555
641
  matchUrl(url) {
556
642
  if (url.hostname !== "github.com") return null;
@@ -616,7 +702,7 @@ var bangumiPlugin = {
616
702
  name: "bangumi",
617
703
  displayName: "Bangumi",
618
704
  priority: 70,
619
- typeClass: "media",
705
+ shape: "poster",
620
706
  provider: "bangumi",
621
707
  matchUrl(url) {
622
708
  if (url.hostname !== "bgm.tv" && url.hostname !== "bangumi.tv") return null;
@@ -658,7 +744,7 @@ var bangumiPlugin = {
658
744
  }
659
745
  });
660
746
  }
661
- const starStyle = {
747
+ const ratingStyle = {
662
748
  display: "inline-flex",
663
749
  flexShrink: 0,
664
750
  alignItems: "center",
@@ -667,6 +753,15 @@ var bangumiPlugin = {
667
753
  fontSize: vars.typography.fontSizeXs,
668
754
  color: "#fb923c"
669
755
  };
756
+ const collectStyle = {
757
+ display: "inline-flex",
758
+ flexShrink: 0,
759
+ alignItems: "center",
760
+ gap: "4px",
761
+ alignSelf: "center",
762
+ fontSize: vars.typography.fontSizeXs,
763
+ color: "#a3a3a3"
764
+ };
670
765
  return {
671
766
  title: /* @__PURE__ */ jsxs("span", {
672
767
  style: {
@@ -697,8 +792,12 @@ var bangumiPlugin = {
697
792
  alignSelf: "center"
698
793
  },
699
794
  children: [/* @__PURE__ */ jsxs("span", {
700
- style: starStyle,
701
- children: ["★", /* @__PURE__ */ jsx("span", {
795
+ style: ratingStyle,
796
+ children: [/* @__PURE__ */ jsx(Star, {
797
+ "aria-hidden": true,
798
+ size: 13,
799
+ strokeWidth: 2
800
+ }), /* @__PURE__ */ jsx("span", {
702
801
  style: {
703
802
  fontFamily: "sans-serif",
704
803
  fontWeight: 500
@@ -706,8 +805,12 @@ var bangumiPlugin = {
706
805
  children: json.rating.score > 0 && json.rating.score.toFixed(1)
707
806
  })]
708
807
  }), /* @__PURE__ */ jsxs("span", {
709
- style: starStyle,
710
- children: ["☆", /* @__PURE__ */ jsx("span", {
808
+ style: collectStyle,
809
+ children: [/* @__PURE__ */ jsx(Users, {
810
+ "aria-hidden": true,
811
+ size: 13,
812
+ strokeWidth: 2
813
+ }), /* @__PURE__ */ jsx("span", {
711
814
  style: {
712
815
  fontFamily: "sans-serif",
713
816
  fontWeight: 500
@@ -717,8 +820,12 @@ var bangumiPlugin = {
717
820
  })]
718
821
  }),
719
822
  (type === "character" || type === "person") && /* @__PURE__ */ jsxs("span", {
720
- style: starStyle,
721
- children: ["☆", /* @__PURE__ */ jsx("span", {
823
+ style: collectStyle,
824
+ children: [/* @__PURE__ */ jsx(Users, {
825
+ "aria-hidden": true,
826
+ size: 13,
827
+ strokeWidth: 2
828
+ }), /* @__PURE__ */ jsx("span", {
722
829
  style: {
723
830
  fontFamily: "sans-serif",
724
831
  fontWeight: 500
@@ -736,11 +843,7 @@ var bangumiPlugin = {
736
843
  children: json.summary
737
844
  }),
738
845
  image: json.images.grid,
739
- color: generateColor(title),
740
- classNames: {
741
- image: "link-card__image--poster",
742
- cardRoot: "link-card--poster"
743
- }
846
+ color: generateColor(title)
744
847
  };
745
848
  }
746
849
  };
@@ -750,7 +853,7 @@ var neteaseMusicPlugin = {
750
853
  name: "netease-music-song",
751
854
  displayName: "Netease Music Song",
752
855
  priority: 60,
753
- typeClass: "wide",
856
+ shape: "wide",
754
857
  provider: "netease-music",
755
858
  matchUrl(url) {
756
859
  if (url.hostname !== "music.163.com") return null;
@@ -780,17 +883,48 @@ var neteaseMusicPlugin = {
780
883
  children: songInfo.tns[0]
781
884
  })] }),
782
885
  desc: /* @__PURE__ */ jsxs(Fragment, { children: [/* @__PURE__ */ jsxs("span", {
783
- style: { display: "block" },
784
- children: [/* @__PURE__ */ jsx("span", {
785
- style: { fontWeight: "bold" },
786
- children: "歌手:"
787
- }), /* @__PURE__ */ jsx("span", { children: singerInfo.map((p) => p.name).join(" / ") })]
886
+ style: {
887
+ display: "inline-flex",
888
+ alignItems: "center",
889
+ gap: "6px"
890
+ },
891
+ children: [
892
+ /* @__PURE__ */ jsx(Mic2, {
893
+ "aria-hidden": true,
894
+ size: 12,
895
+ strokeWidth: 2
896
+ }),
897
+ /* @__PURE__ */ jsx("span", {
898
+ style: {
899
+ color: "#525252",
900
+ fontWeight: 500
901
+ },
902
+ children: "歌手"
903
+ }),
904
+ /* @__PURE__ */ jsx("span", { children: singerInfo.map((p) => p.name).join(" / ") })
905
+ ]
788
906
  }), /* @__PURE__ */ jsxs("span", {
789
- style: { display: "block" },
790
- children: [/* @__PURE__ */ jsx("span", {
791
- style: { fontWeight: "bold" },
792
- children: "专辑:"
793
- }), /* @__PURE__ */ jsx("span", { children: albumInfo.name })]
907
+ style: {
908
+ display: "inline-flex",
909
+ alignItems: "center",
910
+ gap: "6px",
911
+ marginTop: "2px"
912
+ },
913
+ children: [
914
+ /* @__PURE__ */ jsx(Disc3, {
915
+ "aria-hidden": true,
916
+ size: 12,
917
+ strokeWidth: 2
918
+ }),
919
+ /* @__PURE__ */ jsx("span", {
920
+ style: {
921
+ color: "#525252",
922
+ fontWeight: 500
923
+ },
924
+ children: "专辑"
925
+ }),
926
+ /* @__PURE__ */ jsx("span", { children: albumInfo.name })
927
+ ]
794
928
  })] }),
795
929
  image: albumInfo.picUrl,
796
930
  color: "#e72d2c"
@@ -803,7 +937,7 @@ var qqMusicPlugin = {
803
937
  name: "qq-music-song",
804
938
  displayName: "QQ Music Song",
805
939
  priority: 60,
806
- typeClass: "wide",
940
+ shape: "wide",
807
941
  provider: "qq-music",
808
942
  matchUrl(url) {
809
943
  if (url.hostname !== "y.qq.com") return null;
@@ -832,17 +966,48 @@ var qqMusicPlugin = {
832
966
  children: songInfo.subtitle
833
967
  })] }),
834
968
  desc: /* @__PURE__ */ jsxs(Fragment, { children: [/* @__PURE__ */ jsxs("span", {
835
- style: { display: "block" },
836
- children: [/* @__PURE__ */ jsx("span", {
837
- style: { fontWeight: "bold" },
838
- children: "歌手:"
839
- }), /* @__PURE__ */ jsx("span", { children: songInfo.singer.map((p) => p.name).join(" / ") })]
969
+ style: {
970
+ display: "inline-flex",
971
+ alignItems: "center",
972
+ gap: "6px"
973
+ },
974
+ children: [
975
+ /* @__PURE__ */ jsx(Mic2, {
976
+ "aria-hidden": true,
977
+ size: 12,
978
+ strokeWidth: 2
979
+ }),
980
+ /* @__PURE__ */ jsx("span", {
981
+ style: {
982
+ color: "#525252",
983
+ fontWeight: 500
984
+ },
985
+ children: "歌手"
986
+ }),
987
+ /* @__PURE__ */ jsx("span", { children: songInfo.singer.map((p) => p.name).join(" / ") })
988
+ ]
840
989
  }), /* @__PURE__ */ jsxs("span", {
841
- style: { display: "block" },
842
- children: [/* @__PURE__ */ jsx("span", {
843
- style: { fontWeight: "bold" },
844
- children: "专辑:"
845
- }), /* @__PURE__ */ jsx("span", { children: songInfo.album.name })]
990
+ style: {
991
+ display: "inline-flex",
992
+ alignItems: "center",
993
+ gap: "6px",
994
+ marginTop: "2px"
995
+ },
996
+ children: [
997
+ /* @__PURE__ */ jsx(Disc3, {
998
+ "aria-hidden": true,
999
+ size: 12,
1000
+ strokeWidth: 2
1001
+ }),
1002
+ /* @__PURE__ */ jsx("span", {
1003
+ style: {
1004
+ color: "#525252",
1005
+ fontWeight: 500
1006
+ },
1007
+ children: "专辑"
1008
+ }),
1009
+ /* @__PURE__ */ jsx("span", { children: songInfo.album.name })
1010
+ ]
846
1011
  })] }),
847
1012
  image: `https://y.gtimg.cn/music/photo_new/T002R300x300M000${albumId}.jpg?max_age=2592000`,
848
1013
  color: "#31c27c"
@@ -871,7 +1036,7 @@ var tmdbPlugin = {
871
1036
  name: "tmdb",
872
1037
  displayName: "The Movie Database",
873
1038
  priority: 70,
874
- typeClass: "media",
1039
+ shape: "poster",
875
1040
  provider: "tmdb",
876
1041
  matchUrl(url) {
877
1042
  if (!url.hostname.includes("themoviedb.org")) return null;
@@ -925,7 +1090,11 @@ var tmdbPlugin = {
925
1090
  fontSize: vars.typography.fontSizeXs,
926
1091
  color: "#fb923c"
927
1092
  },
928
- children: ["★", /* @__PURE__ */ jsx("span", {
1093
+ children: [/* @__PURE__ */ jsx(Star, {
1094
+ "aria-hidden": true,
1095
+ size: 13,
1096
+ strokeWidth: 2
1097
+ }), /* @__PURE__ */ jsx("span", {
929
1098
  style: {
930
1099
  fontFamily: "sans-serif",
931
1100
  fontWeight: 500
@@ -943,11 +1112,7 @@ var tmdbPlugin = {
943
1112
  children: json.overview
944
1113
  }),
945
1114
  image: `https://image.tmdb.org/t/p/w500${json.poster_path}`,
946
- color: generateColor(title || originalTitle || id),
947
- classNames: {
948
- image: "link-card__image--poster",
949
- cardRoot: "link-card--poster"
950
- }
1115
+ color: generateColor(title || originalTitle || id)
951
1116
  };
952
1117
  }
953
1118
  };
@@ -959,6 +1124,7 @@ function createMxSpacePlugin(config) {
959
1124
  name: "self",
960
1125
  displayName: "MxSpace Article",
961
1126
  priority: 10,
1127
+ shape: "compact",
962
1128
  provider: "mx-space",
963
1129
  matchUrl(url) {
964
1130
  if (webHost !== url.hostname) return null;
@@ -1046,20 +1212,21 @@ var semanticClassNames = {
1046
1212
  cardShortDesc: "link-card--short-desc",
1047
1213
  cardSkeleton: "link-card--skeleton",
1048
1214
  cardError: "link-card--error",
1049
- cardPoster: "link-card--poster",
1215
+ cardCompact: "link-card--compact",
1216
+ cardExpanded: "link-card--expanded",
1050
1217
  cardWide: "link-card--wide",
1051
- cardMedia: "link-card--media",
1052
- cardGithub: "link-card--github",
1053
- cardAcademic: "link-card--academic",
1218
+ cardPoster: "link-card--poster",
1054
1219
  bg: "link-card__bg",
1055
1220
  image: "link-card__image",
1056
- imagePoster: "link-card__image--poster",
1057
1221
  icon: "link-card__icon",
1058
1222
  content: "link-card__content",
1059
1223
  title: "link-card__title",
1060
1224
  titleText: "link-card__title-text",
1061
1225
  desc: "link-card__desc",
1062
1226
  desc2: "link-card__desc-2",
1227
+ errorContent: "link-card__error-content",
1228
+ errorUrl: "link-card__error-url",
1229
+ errorHint: "link-card__error-hint",
1063
1230
  editWrapper: "rich-link-card-edit-wrapper",
1064
1231
  editPanel: "rich-link-card-edit-panel",
1065
1232
  editUrlRow: "rich-link-card-edit-url-row",
@@ -1068,40 +1235,34 @@ var semanticClassNames = {
1068
1235
  };
1069
1236
  var card = "_13weebv0";
1070
1237
  var image = "_13weebv3";
1071
- var icon = "_13weebv5";
1072
- var content = "_13weebv6";
1073
- var title = "_13weebv7";
1074
- var titleText = "_13weebv8";
1075
- var desc = "_13weebv9";
1076
- var desc2 = "_13weebva";
1077
- var cardSkeleton = "_13weebvg";
1078
- var editWrapper = "_13weebvj";
1079
- var editPanel = "_13weebvk";
1080
- var editUrlRow = "_13weebvl";
1081
- var editLinkIcon = "_13weebvm";
1082
- var editInput = "_13weebvn";
1083
- var typeCardModifier = {
1084
- media: "_13weebvd",
1085
- github: "_13weebve",
1086
- academic: "_13weebvf",
1087
- wide: "_13weebvc"
1088
- };
1089
- var semanticTypeClassNames = {
1090
- media: "link-card--media",
1091
- github: "link-card--github",
1092
- academic: "link-card--academic",
1093
- wide: "link-card--wide"
1238
+ var icon = "_13weebv4";
1239
+ var content = "_13weebv5";
1240
+ var title = "_13weebv6";
1241
+ var titleText = "_13weebv7";
1242
+ var desc = "_13weebv8";
1243
+ var desc2 = "_13weebv9";
1244
+ var cardSkeleton = "_13weebve";
1245
+ var cardError = "_13weebvg";
1246
+ var errorIcon = "_13weebvh";
1247
+ var errorContent = "_13weebvi";
1248
+ var errorUrl = "_13weebvj";
1249
+ var errorHint = "_13weebvk";
1250
+ var editWrapper = "_13weebvl";
1251
+ var editPanel = "_13weebvm";
1252
+ var editUrlRow = "_13weebvn";
1253
+ var editLinkIcon = "_13weebvo";
1254
+ var editInput = "_13weebvp";
1255
+ var shapeClass = {
1256
+ compact: "_13weebva",
1257
+ expanded: "_13weebvb",
1258
+ wide: "_13weebvc",
1259
+ poster: "_13weebvd"
1094
1260
  };
1095
- var semanticClassToStyle = {
1096
- "link-card--short-desc": "_13weebv1",
1097
- "link-card--skeleton": "_13weebvg",
1098
- "link-card--error": "_13weebvi",
1099
- "link-card--poster": "_13weebvb",
1100
- "link-card--wide": "_13weebvc",
1101
- "link-card--media": "_13weebvd",
1102
- "link-card--github": "_13weebve",
1103
- "link-card--academic": "_13weebvf",
1104
- "link-card__image--poster": "_13weebv4"
1261
+ var semanticShapeClass = {
1262
+ compact: "link-card--compact",
1263
+ expanded: "link-card--expanded",
1264
+ wide: "link-card--wide",
1265
+ poster: "link-card--poster"
1105
1266
  };
1106
1267
  //#endregion
1107
1268
  //#region src/FetchContext.tsx
@@ -1164,9 +1325,9 @@ function useCardFetcher(options) {
1164
1325
  //#endregion
1165
1326
  //#region src/LinkCardSkeleton.tsx
1166
1327
  function LinkCardSkeleton({ source, className }) {
1167
- const typeClass = (source ? pluginMap.get(source) : void 0)?.typeClass;
1168
- const typeStyleClass = typeClass ? typeCardModifier[typeClass] : "";
1169
- const typeSemanticClass = typeClass ? semanticTypeClassNames[typeClass] : "";
1328
+ const shape = (source ? pluginMap.get(source) : void 0)?.shape ?? "compact";
1329
+ const shapeStyleClass = shapeClass[shape];
1330
+ const shapeSemanticClass = semanticShapeClass[shape];
1170
1331
  return /* @__PURE__ */ jsxs("span", {
1171
1332
  "data-hide-print": true,
1172
1333
  "data-source": source || void 0,
@@ -1175,8 +1336,8 @@ function LinkCardSkeleton({ source, className }) {
1175
1336
  semanticClassNames.card,
1176
1337
  cardSkeleton,
1177
1338
  semanticClassNames.cardSkeleton,
1178
- typeStyleClass,
1179
- typeSemanticClass,
1339
+ shapeStyleClass,
1340
+ shapeSemanticClass,
1180
1341
  className
1181
1342
  ].filter(Boolean).join(" "),
1182
1343
  children: [/* @__PURE__ */ jsx("span", { className: `${image} ${semanticClassNames.image}` }), /* @__PURE__ */ jsxs("span", {
@@ -1205,9 +1366,13 @@ function FallbackIcon({ favicon }) {
1205
1366
  }) : /* @__PURE__ */ jsx(Globe, { "aria-hidden": "true" })
1206
1367
  });
1207
1368
  }
1208
- function mapSemanticClasses(classNames) {
1209
- if (!classNames) return "";
1210
- return classNames.split(/\s+/).filter(Boolean).map((cls) => semanticClassToStyle[cls] ? `${semanticClassToStyle[cls]} ${cls}` : cls).join(" ");
1369
+ function displayHost(url) {
1370
+ try {
1371
+ const u = new URL(url);
1372
+ return `${u.hostname}${u.pathname === "/" ? "" : u.pathname}`;
1373
+ } catch {
1374
+ return url;
1375
+ }
1211
1376
  }
1212
1377
  var LinkCardRenderer = (props) => {
1213
1378
  const { url, title: title$1, description, favicon, image: image$1, source: explicitSource, id: explicitId, className, plugins: extraPlugins, fetchContext: fetchContextProp } = props;
@@ -1234,17 +1399,13 @@ var LinkCardRenderer = (props) => {
1234
1399
  enabled: useDynamicFetch,
1235
1400
  context: fetchContext
1236
1401
  });
1237
- const typeClass = selectedPlugin?.typeClass;
1238
- const typeStyleClass = typeClass ? typeCardModifier[typeClass] : "";
1239
- const typeSemanticClass = typeClass ? semanticTypeClassNames[typeClass] : "";
1240
- const isErrorState = useDynamicFetch && isError;
1241
- const finalTitle = cardInfo?.title || title$1 || (isErrorState ? "" : url);
1402
+ const shape = selectedPlugin?.shape ?? "compact";
1403
+ const shapeStyleClass = shapeClass[shape];
1404
+ const shapeSemanticClass = semanticShapeClass[shape];
1405
+ const finalTitle = cardInfo?.title || title$1 || url;
1242
1406
  const finalDesc = cardInfo?.desc || description;
1243
1407
  const finalImage = cardInfo?.image || image$1;
1244
1408
  const finalColor = cardInfo?.color;
1245
- const classNames = cardInfo?.classNames || {};
1246
- const mappedCardRootClass = mapSemanticClasses(classNames.cardRoot);
1247
- const mappedImageClass = mapSemanticClasses(classNames.image);
1248
1409
  const [shortDesc, setShortDesc] = useState(false);
1249
1410
  const descRef = useRef(null);
1250
1411
  useEffect(() => {
@@ -1266,8 +1427,34 @@ var LinkCardRenderer = (props) => {
1266
1427
  target: "_blank",
1267
1428
  children: /* @__PURE__ */ jsx(LinkCardSkeleton, { source })
1268
1429
  });
1430
+ if (useDynamicFetch && isError) return /* @__PURE__ */ jsxs("a", {
1431
+ "data-hide-print": true,
1432
+ "data-source": source || void 0,
1433
+ href: fullUrl,
1434
+ ref,
1435
+ rel: "noopener noreferrer",
1436
+ target: "_blank",
1437
+ className: [
1438
+ cardError,
1439
+ semanticClassNames.cardError,
1440
+ "not-prose",
1441
+ className
1442
+ ].filter(Boolean).join(" "),
1443
+ children: [/* @__PURE__ */ jsx("span", {
1444
+ className: errorIcon,
1445
+ children: /* @__PURE__ */ jsx(Unlink, { "aria-hidden": "true" })
1446
+ }), /* @__PURE__ */ jsxs("span", {
1447
+ className: `${errorContent} ${semanticClassNames.errorContent}`,
1448
+ children: [/* @__PURE__ */ jsx("span", {
1449
+ className: `${errorUrl} ${semanticClassNames.errorUrl}`,
1450
+ children: displayHost(fullUrl)
1451
+ }), /* @__PURE__ */ jsx("span", {
1452
+ className: `${errorHint} ${semanticClassNames.errorHint}`,
1453
+ children: "无法预览 · 仍可访问"
1454
+ })]
1455
+ })]
1456
+ });
1269
1457
  const hasImage = !!finalImage;
1270
- const showImagePlaceholder = isErrorState && !hasImage;
1271
1458
  const shouldCenterContent = !finalDesc || shortDesc;
1272
1459
  return /* @__PURE__ */ jsxs("a", {
1273
1460
  "data-hide-print": true,
@@ -1279,17 +1466,12 @@ var LinkCardRenderer = (props) => {
1279
1466
  className: [
1280
1467
  card,
1281
1468
  semanticClassNames.card,
1282
- typeStyleClass,
1283
- typeSemanticClass,
1469
+ shapeStyleClass,
1470
+ shapeSemanticClass,
1284
1471
  shouldCenterContent && "_13weebv1",
1285
1472
  shouldCenterContent && semanticClassNames.cardShortDesc,
1286
- useDynamicFetch && (loading || isError) && "_13weebvg",
1287
- useDynamicFetch && (loading || isError) && semanticClassNames.cardSkeleton,
1288
- useDynamicFetch && isError && "_13weebvi",
1289
- useDynamicFetch && isError && semanticClassNames.cardError,
1290
1473
  "not-prose",
1291
- className,
1292
- mappedCardRootClass
1474
+ className
1293
1475
  ].filter(Boolean).join(" "),
1294
1476
  style: { borderColor: finalColor ? `${finalColor}30` : void 0 },
1295
1477
  children: [
@@ -1300,14 +1482,10 @@ var LinkCardRenderer = (props) => {
1300
1482
  opacity: .04
1301
1483
  }
1302
1484
  }),
1303
- hasImage || showImagePlaceholder ? /* @__PURE__ */ jsx("span", {
1485
+ hasImage ? /* @__PURE__ */ jsx("span", {
1486
+ className: `${image} ${semanticClassNames.image}`,
1304
1487
  "data-image": finalImage || "",
1305
- className: [
1306
- image,
1307
- semanticClassNames.image,
1308
- mappedImageClass
1309
- ].filter(Boolean).join(" "),
1310
- style: { backgroundImage: finalImage ? `url(${finalImage})` : void 0 }
1488
+ style: { backgroundImage: `url(${finalImage})` }
1311
1489
  }) : /* @__PURE__ */ jsx(FallbackIcon, { favicon }),
1312
1490
  /* @__PURE__ */ jsxs("span", {
1313
1491
  className: `${content} ${semanticClassNames.content}`,
@@ -1318,7 +1496,7 @@ var LinkCardRenderer = (props) => {
1318
1496
  children: finalTitle
1319
1497
  })
1320
1498
  }), finalDesc && /* @__PURE__ */ jsx("span", {
1321
- className: `_13weebv9 ${semanticClassNames.desc}`,
1499
+ className: `_13weebv8 ${semanticClassNames.desc}`,
1322
1500
  ref: descRef,
1323
1501
  children: finalDesc
1324
1502
  })]
@@ -1 +1 @@
1
- {"version":3,"file":"LinkCardRenderer.d.ts","sourceRoot":"","sources":["../src/LinkCardRenderer.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,+BAA+B,CAAC;AAE3E,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,OAAO,CAAC;AAS3C,OAAO,KAAK,EAAE,oBAAoB,EAAE,cAAc,EAAE,MAAM,SAAS,CAAC;AAEpE,MAAM,WAAW,qBAAsB,SAAQ,qBAAqB;IAClE,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,YAAY,CAAC,EAAE,oBAAoB,CAAC;IACpC,EAAE,CAAC,EAAE,MAAM,CAAC;IACZ;;OAEG;IACH,OAAO,CAAC,EAAE,cAAc,CAAC;IACzB,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AA2BD,eAAO,MAAM,gBAAgB,EAAE,aAAa,CAAC,qBAAqB,CA4JjE,CAAC"}
1
+ {"version":3,"file":"LinkCardRenderer.d.ts","sourceRoot":"","sources":["../src/LinkCardRenderer.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,+BAA+B,CAAC;AAE3E,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,OAAO,CAAC;AAS3C,OAAO,KAAK,EAAE,oBAAoB,EAAE,cAAc,EAAE,MAAM,SAAS,CAAC;AAEpE,MAAM,WAAW,qBAAsB,SAAQ,qBAAqB;IAClE,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,YAAY,CAAC,EAAE,oBAAoB,CAAC;IACpC,EAAE,CAAC,EAAE,MAAM,CAAC;IACZ;;OAEG;IACH,OAAO,CAAC,EAAE,cAAc,CAAC;IACzB,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AAyBD,eAAO,MAAM,gBAAgB,EAAE,aAAa,CAAC,qBAAqB,CA4KjE,CAAC"}
@@ -1,4 +1,4 @@
1
- export declare function LinkCardSkeleton({ source, className, }: {
1
+ export declare function LinkCardSkeleton({ source, className }: {
2
2
  source?: string;
3
3
  className?: string;
4
4
  }): import("react/jsx-runtime").JSX.Element;
@@ -1 +1 @@
1
- {"version":3,"file":"LinkCardSkeleton.d.ts","sourceRoot":"","sources":["../src/LinkCardSkeleton.tsx"],"names":[],"mappings":"AAGA,wBAAgB,gBAAgB,CAAC,EAC/B,MAAM,EACN,SAAS,GACV,EAAE;IACD,MAAM,CAAC,EAAE,MAAM,CAAA;IACf,SAAS,CAAC,EAAE,MAAM,CAAA;CACnB,2CAwCA"}
1
+ {"version":3,"file":"LinkCardSkeleton.d.ts","sourceRoot":"","sources":["../src/LinkCardSkeleton.tsx"],"names":[],"mappings":"AAGA,wBAAgB,gBAAgB,CAAC,EAAE,MAAM,EAAE,SAAS,EAAE,EAAE;IAAE,MAAM,CAAC,EAAE,MAAM,CAAC;IAAC,SAAS,CAAC,EAAE,MAAM,CAAA;CAAE,2CAkC9F"}
package/dist/index.d.ts CHANGED
@@ -4,7 +4,7 @@ export { LinkCardFetchProvider, useLinkCardFetchContext } from './FetchContext';
4
4
  export type { UrlMatchInfo } from './hooks/useUrlMatcher';
5
5
  export { matchUrl, useUrlMatcher } from './hooks/useUrlMatcher';
6
6
  export { LinkCardEditDecorator } from './LinkCardEditDecorator';
7
- export { $createLinkCardEditNode, LinkCardEditNode, linkCardEditNodes, } from './LinkCardEditNode';
7
+ export { $createLinkCardEditNode, LinkCardEditNode, linkCardEditNodes } from './LinkCardEditNode';
8
8
  export type { EnhancedLinkCardProps } from './LinkCardRenderer';
9
9
  export { LinkCardRenderer } from './LinkCardRenderer';
10
10
  export { LinkCardSkeleton } from './LinkCardSkeleton';
@@ -14,6 +14,6 @@ export { getPluginByName, pluginMap, plugins } from './plugins';
14
14
  export { arxivPlugin, bangumiPlugin, githubCommitPlugin, githubDiscussionPlugin, githubIssuePlugin, githubPrPlugin, githubRepoPlugin, leetcodePlugin, neteaseMusicPlugin, qqMusicPlugin, tmdbPlugin, } from './plugins';
15
15
  export { createMxSpacePlugin } from './plugins';
16
16
  export type { MxSpacePluginConfig } from './plugins/self';
17
- export type { LinkCardApiAdapter, LinkCardData, LinkCardFetchContext, LinkCardPlugin, LinkCardTypeClass, PluginRegistry, UrlMatchResult, } from './types';
17
+ export type { LinkCardApiAdapter, LinkCardData, LinkCardFetchContext, LinkCardPlugin, LinkCardShape, PluginRegistry, UrlMatchResult, } from './types';
18
18
  export { camelcaseKeys, fetchGitHubApi, fetchJsonWithContext, generateColor, LanguageToColorMap, } from './utils';
19
19
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,YAAY,EAAE,4BAA4B,EAAE,MAAM,2BAA2B,CAAA;AAC7E,OAAO,EAAE,uBAAuB,EAAE,MAAM,2BAA2B,CAAA;AACnE,OAAO,EAAE,qBAAqB,EAAE,uBAAuB,EAAE,MAAM,gBAAgB,CAAA;AAC/E,YAAY,EAAE,YAAY,EAAE,MAAM,uBAAuB,CAAA;AACzD,OAAO,EAAE,QAAQ,EAAE,aAAa,EAAE,MAAM,uBAAuB,CAAA;AAC/D,OAAO,EAAE,qBAAqB,EAAE,MAAM,yBAAyB,CAAA;AAC/D,OAAO,EACL,uBAAuB,EACvB,gBAAgB,EAChB,iBAAiB,GAClB,MAAM,oBAAoB,CAAA;AAC3B,YAAY,EAAE,qBAAqB,EAAE,MAAM,oBAAoB,CAAA;AAC/D,OAAO,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAA;AACrD,OAAO,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAA;AACrD,YAAY,EAAE,wBAAwB,EAAE,MAAM,uBAAuB,CAAA;AACrE,OAAO,EAAE,mBAAmB,EAAE,MAAM,uBAAuB,CAAA;AAC3D,OAAO,EAAE,eAAe,EAAE,SAAS,EAAE,OAAO,EAAE,MAAM,WAAW,CAAA;AAC/D,OAAO,EACL,WAAW,EACX,aAAa,EACb,kBAAkB,EAClB,sBAAsB,EACtB,iBAAiB,EACjB,cAAc,EACd,gBAAgB,EAChB,cAAc,EACd,kBAAkB,EAClB,aAAa,EACb,UAAU,GACX,MAAM,WAAW,CAAA;AAClB,OAAO,EAAE,mBAAmB,EAAE,MAAM,WAAW,CAAA;AAC/C,YAAY,EAAE,mBAAmB,EAAE,MAAM,gBAAgB,CAAA;AACzD,YAAY,EACV,kBAAkB,EAClB,YAAY,EACZ,oBAAoB,EACpB,cAAc,EACd,iBAAiB,EACjB,cAAc,EACd,cAAc,GACf,MAAM,SAAS,CAAA;AAChB,OAAO,EACL,aAAa,EACb,cAAc,EACd,oBAAoB,EACpB,aAAa,EACb,kBAAkB,GACnB,MAAM,SAAS,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,YAAY,EAAE,4BAA4B,EAAE,MAAM,2BAA2B,CAAC;AAC9E,OAAO,EAAE,uBAAuB,EAAE,MAAM,2BAA2B,CAAC;AACpE,OAAO,EAAE,qBAAqB,EAAE,uBAAuB,EAAE,MAAM,gBAAgB,CAAC;AAChF,YAAY,EAAE,YAAY,EAAE,MAAM,uBAAuB,CAAC;AAC1D,OAAO,EAAE,QAAQ,EAAE,aAAa,EAAE,MAAM,uBAAuB,CAAC;AAChE,OAAO,EAAE,qBAAqB,EAAE,MAAM,yBAAyB,CAAC;AAChE,OAAO,EAAE,uBAAuB,EAAE,gBAAgB,EAAE,iBAAiB,EAAE,MAAM,oBAAoB,CAAC;AAClG,YAAY,EAAE,qBAAqB,EAAE,MAAM,oBAAoB,CAAC;AAChE,OAAO,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAC;AACtD,OAAO,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAC;AACtD,YAAY,EAAE,wBAAwB,EAAE,MAAM,uBAAuB,CAAC;AACtE,OAAO,EAAE,mBAAmB,EAAE,MAAM,uBAAuB,CAAC;AAC5D,OAAO,EAAE,eAAe,EAAE,SAAS,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAChE,OAAO,EACL,WAAW,EACX,aAAa,EACb,kBAAkB,EAClB,sBAAsB,EACtB,iBAAiB,EACjB,cAAc,EACd,gBAAgB,EAChB,cAAc,EACd,kBAAkB,EAClB,aAAa,EACb,UAAU,GACX,MAAM,WAAW,CAAC;AACnB,OAAO,EAAE,mBAAmB,EAAE,MAAM,WAAW,CAAC;AAChD,YAAY,EAAE,mBAAmB,EAAE,MAAM,gBAAgB,CAAC;AAC1D,YAAY,EACV,kBAAkB,EAClB,YAAY,EACZ,oBAAoB,EACpB,cAAc,EACd,aAAa,EACb,cAAc,EACd,cAAc,GACf,MAAM,SAAS,CAAC;AACjB,OAAO,EACL,aAAa,EACb,cAAc,EACd,oBAAoB,EACpB,aAAa,EACb,kBAAkB,GACnB,MAAM,SAAS,CAAC"}
package/dist/index.mjs CHANGED
@@ -1,4 +1,4 @@
1
- import { A as fetchJsonWithContext, C as githubIssuePlugin, D as LanguageToColorMap, E as leetcodePlugin, M as arxivPlugin, O as camelcaseKeys, S as githubPrPlugin, T as githubCommitPlugin, _ as tmdbPlugin, a as editInput, b as bangumiPlugin, c as editUrlRow, d as matchUrl, f as useUrlMatcher, g as createMxSpacePlugin, h as plugins, i as useLinkCardFetchContext, j as generateColor, k as fetchGitHubApi, l as editWrapper, m as pluginMap, n as LinkCardSkeleton, o as editLinkIcon, p as getPluginByName, r as LinkCardFetchProvider, s as editPanel, t as LinkCardRenderer, u as semanticClassNames, v as qqMusicPlugin, w as githubDiscussionPlugin, x as githubRepoPlugin, y as neteaseMusicPlugin } from "./LinkCardRenderer-DqaMJub3.js";
1
+ import { A as fetchJsonWithContext, C as githubIssuePlugin, D as LanguageToColorMap, E as leetcodePlugin, M as arxivPlugin, O as camelcaseKeys, S as githubPrPlugin, T as githubCommitPlugin, _ as tmdbPlugin, a as editInput, b as bangumiPlugin, c as editUrlRow, d as matchUrl, f as useUrlMatcher, g as createMxSpacePlugin, h as plugins, i as useLinkCardFetchContext, j as generateColor, k as fetchGitHubApi, l as editWrapper, m as pluginMap, n as LinkCardSkeleton, o as editLinkIcon, p as getPluginByName, r as LinkCardFetchProvider, s as editPanel, t as LinkCardRenderer, u as semanticClassNames, v as qqMusicPlugin, w as githubDiscussionPlugin, x as githubRepoPlugin, y as neteaseMusicPlugin } from "./LinkCardRenderer-D_FokwfU.js";
2
2
  import { $createLinkNode, $isLinkNode } from "@lexical/link";
3
3
  import { useLexicalComposerContext } from "@lexical/react/LexicalComposerContext";
4
4
  import { $createNodeSelection, $createParagraphNode, $createTextNode, $getNodeByKey, $getSelection, $insertNodes, $isParagraphNode, $isRangeSelection, $setSelection, COMMAND_PRIORITY_LOW, PASTE_COMMAND, REDO_COMMAND, UNDO_COMMAND } from "lexical";
@@ -1 +1 @@
1
- {"version":3,"file":"arxiv.d.ts","sourceRoot":"","sources":["../../../src/plugins/academic/arxiv.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAgB,cAAc,EAAkB,MAAM,aAAa,CAAA;AAE/E,eAAO,MAAM,WAAW,EAAE,cAwDzB,CAAA"}
1
+ {"version":3,"file":"arxiv.d.ts","sourceRoot":"","sources":["../../../src/plugins/academic/arxiv.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAgB,cAAc,EAAkB,MAAM,aAAa,CAAC;AAEhF,eAAO,MAAM,WAAW,EAAE,cAgEzB,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"leetcode.d.ts","sourceRoot":"","sources":["../../../src/plugins/code/leetcode.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAGV,cAAc,EAEf,MAAM,aAAa,CAAC;AAoBrB,eAAO,MAAM,cAAc,EAAE,cAuF5B,CAAC"}
1
+ {"version":3,"file":"leetcode.d.ts","sourceRoot":"","sources":["../../../src/plugins/code/leetcode.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAGV,cAAc,EAEf,MAAM,aAAa,CAAC;AAoBrB,eAAO,MAAM,cAAc,EAAE,cA8G5B,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"commit.d.ts","sourceRoot":"","sources":["../../../src/plugins/github/commit.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAgB,cAAc,EAAkB,MAAM,aAAa,CAAA;AAG/E,eAAO,MAAM,kBAAkB,EAAE,cAwEhC,CAAA"}
1
+ {"version":3,"file":"commit.d.ts","sourceRoot":"","sources":["../../../src/plugins/github/commit.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAgB,cAAc,EAAkB,MAAM,aAAa,CAAC;AAGhF,eAAO,MAAM,kBAAkB,EAAE,cA4EhC,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"discussion.d.ts","sourceRoot":"","sources":["../../../src/plugins/github/discussion.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAgB,cAAc,EAAkB,MAAM,aAAa,CAAC;AAGhF,eAAO,MAAM,sBAAsB,EAAE,cAiEpC,CAAC"}
1
+ {"version":3,"file":"discussion.d.ts","sourceRoot":"","sources":["../../../src/plugins/github/discussion.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAgB,cAAc,EAAkB,MAAM,aAAa,CAAC;AAGhF,eAAO,MAAM,sBAAsB,EAAE,cAqEpC,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"issue.d.ts","sourceRoot":"","sources":["../../../src/plugins/github/issue.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAgB,cAAc,EAAkB,MAAM,aAAa,CAAA;AAa/E,eAAO,MAAM,iBAAiB,EAAE,cA2D/B,CAAA"}
1
+ {"version":3,"file":"issue.d.ts","sourceRoot":"","sources":["../../../src/plugins/github/issue.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAgB,cAAc,EAAkB,MAAM,aAAa,CAAC;AAahF,eAAO,MAAM,iBAAiB,EAAE,cA2D/B,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"pr.d.ts","sourceRoot":"","sources":["../../../src/plugins/github/pr.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAgB,cAAc,EAAkB,MAAM,aAAa,CAAA;AAsB/E,eAAO,MAAM,cAAc,EAAE,cAiE5B,CAAA"}
1
+ {"version":3,"file":"pr.d.ts","sourceRoot":"","sources":["../../../src/plugins/github/pr.tsx"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAgB,cAAc,EAAkB,MAAM,aAAa,CAAC;AA+BhF,eAAO,MAAM,cAAc,EAAE,cAqE5B,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"bangumi.d.ts","sourceRoot":"","sources":["../../../src/plugins/media/bangumi.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAGV,cAAc,EAEf,MAAM,aAAa,CAAA;AAQpB,eAAO,MAAM,aAAa,EAAE,cA8I3B,CAAA"}
1
+ {"version":3,"file":"bangumi.d.ts","sourceRoot":"","sources":["../../../src/plugins/media/bangumi.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAGV,cAAc,EAEf,MAAM,aAAa,CAAC;AAQrB,eAAO,MAAM,aAAa,EAAE,cA2I3B,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"netease-music.d.ts","sourceRoot":"","sources":["../../../src/plugins/media/netease-music.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAGV,cAAc,EAEf,MAAM,aAAa,CAAC;AAGrB,eAAO,MAAM,kBAAkB,EAAE,cAqEhC,CAAC"}
1
+ {"version":3,"file":"netease-music.d.ts","sourceRoot":"","sources":["../../../src/plugins/media/netease-music.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAGV,cAAc,EAEf,MAAM,aAAa,CAAC;AAGrB,eAAO,MAAM,kBAAkB,EAAE,cAyEhC,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"qq-music.d.ts","sourceRoot":"","sources":["../../../src/plugins/media/qq-music.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAGV,cAAc,EAEf,MAAM,aAAa,CAAC;AAGrB,eAAO,MAAM,aAAa,EAAE,cA+D3B,CAAC"}
1
+ {"version":3,"file":"qq-music.d.ts","sourceRoot":"","sources":["../../../src/plugins/media/qq-music.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAGV,cAAc,EAEf,MAAM,aAAa,CAAC;AAGrB,eAAO,MAAM,aAAa,EAAE,cAmE3B,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"tmdb.d.ts","sourceRoot":"","sources":["../../../src/plugins/media/tmdb.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAGV,cAAc,EAEf,MAAM,aAAa,CAAA;AAuBpB,eAAO,MAAM,UAAU,EAAE,cA8FxB,CAAA"}
1
+ {"version":3,"file":"tmdb.d.ts","sourceRoot":"","sources":["../../../src/plugins/media/tmdb.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAGV,cAAc,EAEf,MAAM,aAAa,CAAC;AAqBrB,eAAO,MAAM,UAAU,EAAE,cA+ExB,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"mx-space.d.ts","sourceRoot":"","sources":["../../../src/plugins/self/mx-space.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAGV,cAAc,EAEf,MAAM,aAAa,CAAA;AAGpB,MAAM,WAAW,mBAAmB;IAClC,MAAM,EAAE,MAAM,CAAA;CACf;AAED,wBAAgB,mBAAmB,CACjC,MAAM,EAAE,mBAAmB,GAC1B,cAAc,CAsEhB"}
1
+ {"version":3,"file":"mx-space.d.ts","sourceRoot":"","sources":["../../../src/plugins/self/mx-space.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAGV,cAAc,EAEf,MAAM,aAAa,CAAC;AAGrB,MAAM,WAAW,mBAAmB;IAClC,MAAM,EAAE,MAAM,CAAC;CAChB;AAED,wBAAgB,mBAAmB,CAAC,MAAM,EAAE,mBAAmB,GAAG,cAAc,CA4D/E"}
@@ -1,2 +1,2 @@
1
- :root{--rc-text:#000;--rc-text-secondary:#262626;--rc-text-tertiary:#737373;--rc-text-quaternary:#a3a3a3;--rc-bg:#fff;--rc-bg-secondary:#fafafa;--rc-bg-tertiary:#f5f5f5;--rc-fill:#e8e8e8;--rc-fill-secondary:#eee;--rc-fill-tertiary:#f5f5f5;--rc-fill-quaternary:#fafafa;--rc-border:#f5f5f5;--rc-accent:#2563eb;--rc-accent-light:#2563eb20;--rc-link:#2563eb;--rc-code-text:#404040;--rc-code-bg:#f5f5f5;--rc-hr-border:#e5e5e5;--rc-quote-border:#2563eb;--rc-quote-bg:#f5f5f5;--rc-alert-info:#006bb7;--rc-alert-warning:#c50;--rc-alert-tip:#1c0;--rc-alert-caution:#c01;--rc-alert-important:#50c;--rc-max-width:700px;--rc-shadow-top-bar:0 8px 30px #0000001f, 0 2px 8px #0000000f;--rc-shadow-modal:0 10px 15px -3px #0000001a, 0 4px 6px -4px #0000001a;--rc-shadow-menu:0 1px 4px #0000000a, 0 4px 16px #00000014;--rc-space-xs:4px;--rc-space-sm:8px;--rc-space-md:16px;--rc-space-lg:24px;--rc-space-xl:32px;--rc-font-family-sans:"PingFang SC", "Microsoft YaHei", "Segoe UI", Roboto, Helvetica, "noto sans sc", "hiragino sans gb", -apple-system, system-ui, sans-serif, Apple Color Emoji, Segoe UI Emoji, Not Color Emoji;--rc-font-family-serif:"Noto Serif CJK SC", "Source Han Serif SC", "Source Han Serif", "source-han-serif-sc", "Songti SC", STSong, "华文宋体", serif;--rc-font-family-kai:"楷体", KaiTi, STKaiti, "Kaiti SC", "LXGW WenKai", "霞鹜文楷", "Noto Serif CJK SC", serif;--rc-font-mono:"SF Mono", SFMono-Regular, ui-monospace, "DejaVu Sans Mono", Menlo, Consolas, monospace;--rc-font-size-2xs:.625em;--rc-font-size-xs:.75em;--rc-font-size-sm:.8125em;--rc-font-size-md:.875em;--rc-font-size-lg:1.25em;--rc-font-size-base:16px;--rc-font-size-small:14px;--rc-line-height:1.7;--rc-line-height-tight:1.4;--rc-font-family:"PingFang SC", "Microsoft YaHei", "Segoe UI", Roboto, Helvetica, "noto sans sc", "hiragino sans gb", -apple-system, system-ui, sans-serif, Apple Color Emoji, Segoe UI Emoji, Not Color Emoji;--rc-radius-sm:4px;--rc-radius-md:8px;--rc-radius-lg:12px}:root.dark,[data-theme=dark]{--rc-text:#fafafa;--rc-text-secondary:#a3a3a3;--rc-text-tertiary:#737373;--rc-text-quaternary:#525252;--rc-bg:#0a0a0a;--rc-bg-secondary:#171717;--rc-bg-tertiary:#262626;--rc-fill:#2a2a2a;--rc-fill-secondary:#222;--rc-fill-tertiary:#1a1a1a;--rc-fill-quaternary:#141414;--rc-border:#262626;--rc-accent:#60a5fa;--rc-accent-light:#60a5fa20;--rc-link:#60a5fa;--rc-code-text:#d4d4d4;--rc-code-bg:#262626;--rc-hr-border:#262626;--rc-quote-border:#60a5fa;--rc-quote-bg:#262626;--rc-alert-info:#7db9e5;--rc-alert-warning:#da864a;--rc-alert-tip:#54da48;--rc-alert-caution:#e16973;--rc-alert-important:#9966e0;--rc-max-width:700px;--rc-shadow-top-bar:0 8px 30px #00000073, 0 2px 8px #0000004d;--rc-shadow-modal:0 10px 15px -3px #0006, 0 4px 6px -4px #00000059;--rc-shadow-menu:0 1px 4px #00000040, 0 4px 16px #0006;--rc-space-xs:4px;--rc-space-sm:8px;--rc-space-md:16px;--rc-space-lg:24px;--rc-space-xl:32px;--rc-font-family-sans:"PingFang SC", "Microsoft YaHei", "Segoe UI", Roboto, Helvetica, "noto sans sc", "hiragino sans gb", -apple-system, system-ui, sans-serif, Apple Color Emoji, Segoe UI Emoji, Not Color Emoji;--rc-font-family-serif:"Noto Serif CJK SC", "Source Han Serif SC", "Source Han Serif", "source-han-serif-sc", "Songti SC", STSong, "华文宋体", serif;--rc-font-family-kai:"楷体", KaiTi, STKaiti, "Kaiti SC", "LXGW WenKai", "霞鹜文楷", "Noto Serif CJK SC", serif;--rc-font-mono:"SF Mono", SFMono-Regular, ui-monospace, "DejaVu Sans Mono", Menlo, Consolas, monospace;--rc-font-size-2xs:.625em;--rc-font-size-xs:.75em;--rc-font-size-sm:.8125em;--rc-font-size-md:.875em;--rc-font-size-lg:1.25em;--rc-font-size-base:16px;--rc-font-size-small:14px;--rc-line-height:1.7;--rc-line-height-tight:1.4;--rc-font-family:"PingFang SC", "Microsoft YaHei", "Segoe UI", Roboto, Helvetica, "noto sans sc", "hiragino sans gb", -apple-system, system-ui, sans-serif, Apple Color Emoji, Segoe UI Emoji, Not Color Emoji;--rc-radius-sm:4px;--rc-radius-md:8px;--rc-radius-lg:12px}._1osyxsk0{--rc-text:#000;--rc-text-secondary:#262626;--rc-text-tertiary:#737373;--rc-text-quaternary:#a3a3a3;--rc-bg:#fff;--rc-bg-secondary:#fafafa;--rc-bg-tertiary:#f5f5f5;--rc-fill:#e8e8e8;--rc-fill-secondary:#eee;--rc-fill-tertiary:#f5f5f5;--rc-fill-quaternary:#fafafa;--rc-border:#f5f5f5;--rc-accent:#2563eb;--rc-accent-light:#2563eb20;--rc-link:#2563eb;--rc-code-text:#404040;--rc-code-bg:#f5f5f5;--rc-hr-border:#e5e5e5;--rc-quote-border:#2563eb;--rc-quote-bg:#f5f5f5;--rc-alert-info:#006bb7;--rc-alert-warning:#c50;--rc-alert-tip:#1c0;--rc-alert-caution:#c01;--rc-alert-important:#50c;--rc-max-width:700px;--rc-shadow-top-bar:0 8px 30px #0000001f, 0 2px 8px #0000000f;--rc-shadow-modal:0 10px 15px -3px #0000001a, 0 4px 6px -4px #0000001a;--rc-shadow-menu:0 1px 4px #0000000a, 0 4px 16px #00000014;--rc-space-xs:4px;--rc-space-sm:8px;--rc-space-md:16px;--rc-space-lg:24px;--rc-space-xl:32px;--rc-font-family-sans:"PingFang SC", "Microsoft YaHei", "Segoe UI", Roboto, Helvetica, "noto sans sc", "hiragino sans gb", -apple-system, system-ui, sans-serif, Apple Color Emoji, Segoe UI Emoji, Not Color Emoji;--rc-font-family-serif:"Noto Serif CJK SC", "Source Han Serif SC", "Source Han Serif", "source-han-serif-sc", "Songti SC", STSong, "华文宋体", serif;--rc-font-family-kai:"楷体", KaiTi, STKaiti, "Kaiti SC", "LXGW WenKai", "霞鹜文楷", "Noto Serif CJK SC", serif;--rc-font-mono:"SF Mono", SFMono-Regular, ui-monospace, "DejaVu Sans Mono", Menlo, Consolas, monospace;--rc-font-size-2xs:.625em;--rc-font-size-xs:.75em;--rc-font-size-sm:.8125em;--rc-font-size-md:.875em;--rc-font-size-lg:1.25em;--rc-font-size-base:16px;--rc-font-size-small:14px;--rc-line-height:1.7;--rc-line-height-tight:1.4;--rc-font-family:"PingFang SC", "Microsoft YaHei", "Segoe UI", Roboto, Helvetica, "noto sans sc", "hiragino sans gb", -apple-system, system-ui, sans-serif, Apple Color Emoji, Segoe UI Emoji, Not Color Emoji;--rc-radius-sm:4px;--rc-radius-md:8px;--rc-radius-lg:12px}._1osyxsk1{--rc-text:#000;--rc-text-secondary:#262626;--rc-text-tertiary:#737373;--rc-text-quaternary:#a3a3a3;--rc-bg:#fff;--rc-bg-secondary:#fafafa;--rc-bg-tertiary:#f5f5f5;--rc-fill:#e8e8e8;--rc-fill-secondary:#eee;--rc-fill-tertiary:#f5f5f5;--rc-fill-quaternary:#fafafa;--rc-border:#f5f5f5;--rc-accent:#2563eb;--rc-accent-light:#2563eb20;--rc-link:#2563eb;--rc-code-text:#404040;--rc-code-bg:#f5f5f5;--rc-hr-border:#e5e5e5;--rc-quote-border:#2563eb;--rc-quote-bg:#f5f5f5;--rc-alert-info:#006bb7;--rc-alert-warning:#c50;--rc-alert-tip:#1c0;--rc-alert-caution:#c01;--rc-alert-important:#50c;--rc-max-width:700px;--rc-shadow-top-bar:0 8px 30px #0000001f, 0 2px 8px #0000000f;--rc-shadow-modal:0 10px 15px -3px #0000001a, 0 4px 6px -4px #0000001a;--rc-shadow-menu:0 1px 4px #0000000a, 0 4px 16px #00000014;--rc-space-xs:4px;--rc-space-sm:8px;--rc-space-md:16px;--rc-space-lg:24px;--rc-space-xl:32px;--rc-font-family-sans:"PingFang SC", "Microsoft YaHei", "Segoe UI", Roboto, Helvetica, "noto sans sc", "hiragino sans gb", -apple-system, system-ui, sans-serif, Apple Color Emoji, Segoe UI Emoji, Not Color Emoji;--rc-font-family-serif:"Noto Serif CJK SC", "Source Han Serif SC", "Source Han Serif", "source-han-serif-sc", "Songti SC", STSong, "华文宋体", serif;--rc-font-family-kai:"楷体", KaiTi, STKaiti, "Kaiti SC", "LXGW WenKai", "霞鹜文楷", "Noto Serif CJK SC", serif;--rc-font-mono:"SF Mono", SFMono-Regular, ui-monospace, "DejaVu Sans Mono", Menlo, Consolas, monospace;--rc-font-size-2xs:.625em;--rc-font-size-xs:.75em;--rc-font-size-sm:.8125em;--rc-font-size-md:.875em;--rc-font-size-lg:1.25em;--rc-font-size-base:16px;--rc-font-size-small:14px;--rc-line-height:1.8;--rc-line-height-tight:1.4;--rc-font-family:"Noto Serif CJK SC", "Source Han Serif SC", "Source Han Serif", "source-han-serif-sc", "Songti SC", STSong, "华文宋体", serif;--rc-radius-sm:4px;--rc-radius-md:8px;--rc-radius-lg:12px}._1osyxsk2{--rc-text:#000;--rc-text-secondary:#262626;--rc-text-tertiary:#737373;--rc-text-quaternary:#a3a3a3;--rc-bg:#fff;--rc-bg-secondary:#fafafa;--rc-bg-tertiary:#f5f5f5;--rc-fill:#e8e8e8;--rc-fill-secondary:#eee;--rc-fill-tertiary:#f5f5f5;--rc-fill-quaternary:#fafafa;--rc-border:#f5f5f5;--rc-accent:#2563eb;--rc-accent-light:#2563eb20;--rc-link:#2563eb;--rc-code-text:#404040;--rc-code-bg:#f5f5f5;--rc-hr-border:#e5e5e5;--rc-quote-border:#a3a3a3;--rc-quote-bg:#fafafa;--rc-alert-info:#006bb7;--rc-alert-warning:#c50;--rc-alert-tip:#1c0;--rc-alert-caution:#c01;--rc-alert-important:#50c;--rc-max-width:none;--rc-shadow-top-bar:0 8px 30px #0000001f, 0 2px 8px #0000000f;--rc-shadow-modal:0 10px 15px -3px #0000001a, 0 4px 6px -4px #0000001a;--rc-shadow-menu:0 1px 4px #0000000a, 0 4px 16px #00000014;--rc-space-xs:2px;--rc-space-sm:4px;--rc-space-md:10px;--rc-space-lg:16px;--rc-space-xl:20px;--rc-font-family-sans:"PingFang SC", "Microsoft YaHei", "Segoe UI", Roboto, Helvetica, "noto sans sc", "hiragino sans gb", -apple-system, system-ui, sans-serif, Apple Color Emoji, Segoe UI Emoji, Not Color Emoji;--rc-font-family-serif:"Noto Serif CJK SC", "Source Han Serif SC", "Source Han Serif", "source-han-serif-sc", "Songti SC", STSong, "华文宋体", serif;--rc-font-family-kai:"楷体", KaiTi, STKaiti, "Kaiti SC", "LXGW WenKai", "霞鹜文楷", "Noto Serif CJK SC", serif;--rc-font-mono:"SF Mono", SFMono-Regular, ui-monospace, "DejaVu Sans Mono", Menlo, Consolas, monospace;--rc-font-size-2xs:.625em;--rc-font-size-xs:.75em;--rc-font-size-sm:.8125em;--rc-font-size-md:.875em;--rc-font-size-lg:1.25em;--rc-font-size-base:14px;--rc-font-size-small:12px;--rc-line-height:1.5;--rc-line-height-tight:1.3;--rc-font-family:"PingFang SC", "Microsoft YaHei", "Segoe UI", Roboto, Helvetica, "noto sans sc", "hiragino sans gb", -apple-system, system-ui, sans-serif, Apple Color Emoji, Segoe UI Emoji, Not Color Emoji;--rc-radius-sm:3px;--rc-radius-md:6px;--rc-radius-lg:12px}.dark ._1osyxsk0,[data-theme=dark] ._1osyxsk0,.dark._1osyxsk0,[data-theme=dark]._1osyxsk0,.dark ._1osyxsk1,[data-theme=dark] ._1osyxsk1,.dark._1osyxsk1,[data-theme=dark]._1osyxsk1,.dark ._1osyxsk2,[data-theme=dark] ._1osyxsk2,.dark._1osyxsk2,[data-theme=dark]._1osyxsk2{--rc-text:#fafafa;--rc-text-secondary:#a3a3a3;--rc-text-tertiary:#737373;--rc-text-quaternary:#525252;--rc-bg:#0a0a0a;--rc-bg-secondary:#171717;--rc-bg-tertiary:#262626;--rc-fill:#2a2a2a;--rc-fill-secondary:#222;--rc-fill-tertiary:#1a1a1a;--rc-fill-quaternary:#141414;--rc-border:#262626;--rc-accent:#60a5fa;--rc-accent-light:#60a5fa20;--rc-link:#60a5fa;--rc-code-text:#d4d4d4;--rc-code-bg:#262626;--rc-hr-border:#262626;--rc-quote-border:#60a5fa;--rc-quote-bg:#262626;--rc-alert-info:#7db9e5;--rc-alert-warning:#da864a;--rc-alert-tip:#54da48;--rc-alert-caution:#e16973;--rc-alert-important:#9966e0;--rc-shadow-top-bar:0 8px 30px #00000073, 0 2px 8px #0000004d;--rc-shadow-modal:0 10px 15px -3px #0006, 0 4px 6px -4px #00000059;--rc-shadow-menu:0 1px 4px #00000040, 0 4px 16px #0006}@keyframes _13weebvh{0%,to{opacity:1}50%{opacity:.5}}._13weebv0{box-sizing:border-box;cursor:pointer;width:32rem;max-width:100%;color:inherit;text-indent:0;font-family:var(--rc-font-family-sans);border:1px solid color-mix(in srgb, var(--rc-border) 80%, transparent);background-color:color-mix(in srgb, var(--rc-bg-secondary) 80%, transparent);-webkit-backdrop-filter:blur(12px)saturate(150%);backdrop-filter:blur(12px)saturate(150%);border-radius:.5rem;align-items:flex-start;gap:.75rem;margin:1.25rem auto;padding:1rem;text-decoration:none;transition:background-color .2s;display:flex;position:relative;overflow:hidden}._13weebv0:hover{border-color:var(--rc-border);background-color:var(--rc-fill-tertiary);text-decoration:none}._13weebv0:focus{text-decoration:none}._13weebv0:focus-visible{text-decoration:none}._13weebv0:active{text-decoration:none}._13weebv1{align-items:center}._13weebv0 *{font-style:normal!important}._13weebv0 span{border-bottom:0!important}._13weebv0,._13weebv0:hover,._13weebv0:focus,._13weebv0:active{text-decoration:none!important}._13weebv0:focus-visible{text-decoration:none!important}._13weebv2{z-index:0;pointer-events:none;position:absolute;top:0;bottom:0;left:0;right:0}._13weebv3{background-position:50%;background-repeat:no-repeat;background-size:cover;background-color:var(--rc-bg-secondary);z-index:1;border-radius:.5rem;flex-shrink:0;width:2.5rem;height:2.5rem;position:relative}._13weebv4{aspect-ratio:2/3;align-self:stretch;min-height:8.75rem;width:6.25rem!important;height:auto!important}._13weebv5{background-color:var(--rc-bg-secondary);z-index:1;border-radius:.5rem;flex-shrink:0;justify-content:center;align-items:center;width:2.5rem;height:2.5rem;display:flex}._13weebv5 img{border-radius:.25rem;width:1.25rem;height:1.25rem}._13weebv5 svg{width:1.25rem;height:1.25rem;color:var(--rc-text-secondary)}._13weebv6{z-index:1;flex:1;min-width:0;position:relative}._13weebv7{align-items:center;gap:.5rem;line-height:1.25rem;display:flex}._13weebv8{line-clamp:1;-webkit-line-clamp:1;text-overflow:ellipsis;min-width:0;font-size:var(--rc-font-size-md);-webkit-box-orient:vertical;flex:1;font-weight:500;line-height:1.25rem;display:-webkit-box;overflow:hidden}._13weebv9{-webkit-line-clamp:2;text-overflow:ellipsis;font-size:var(--rc-font-size-md);color:var(--rc-text-secondary);-webkit-box-orient:vertical;min-width:0;margin-top:.375rem;line-height:1.5;display:-webkit-box;overflow:hidden}._13weebvb{max-width:40rem;padding:0;width:100%!important;height:auto!important}._13weebvb ._13weebv3{border-radius:0;align-self:stretch;height:auto!important;margin-left:0!important}._13weebvb ._13weebv3:after{content:"";background:linear-gradient(to right, transparent 60%, var(--rc-bg-secondary));pointer-events:none;position:absolute;top:0;bottom:0;left:0;right:0}._13weebvb ._13weebv6{flex-direction:column;justify-content:center;padding:1rem;display:flex}._13weebvc{width:100%;max-width:40rem}._13weebvd{width:100%!important;max-width:unset!important}._13weebvd ._13weebv9{-webkit-line-clamp:4}._13weebve{width:36rem}._13weebvf{width:38rem}._13weebvf ._13weebv9{-webkit-line-clamp:3}._13weebv0[data-source=gh-repo]{height:6.25rem}._13weebv0[data-source=gh-commit],._13weebv0[data-source=gh-pr],._13weebv0[data-source=gh-issue],._13weebv0[data-source=gh-discussion]{height:5rem}._13weebv0[data-source=gh-discussion] ._13weebv8{-webkit-line-clamp:1;line-clamp:1}._13weebv0[data-source=leetcode]{height:5.25rem}._13weebv0[data-source=arxiv]{height:6rem}._13weebv0[data-source=netease-music-song],._13weebv0[data-source=qq-music-song]{height:5.75rem}._13weebvg{animation-play-state:paused}._13weebvg ._13weebv8{background-color:var(--rc-border);border-radius:.375rem;width:8rem;height:1.25rem}._13weebvg ._13weebv9{background-color:var(--rc-border);border-radius:.375rem;width:100%;height:.875rem;margin-top:.5rem}._13weebvg ._13weebva{width:80%}._13weebvg[data-source=gh-commit] ._13weebva,._13weebvg[data-source=gh-pr] ._13weebva,._13weebvg[data-source=gh-issue] ._13weebva,._13weebvg[data-source=gh-discussion] ._13weebva{display:none}._13weebvg ._13weebv3{background-color:var(--rc-border)}._13weebvg ._13weebv8,._13weebvg ._13weebv9,._13weebvg ._13weebv3{animation:2s cubic-bezier(.4,0,.6,1) infinite _13weebvh}._13weebvg._13weebvi{border:0;background-color:color-mix(in srgb, var(--rc-alert-caution) 12%, transparent)!important}._13weebvg._13weebvi ._13weebv8,._13weebvg._13weebvi ._13weebv9,._13weebvg._13weebvi ._13weebv3{background-color:color-mix(in srgb, var(--rc-alert-caution) 47%, transparent);color:#0000;animation:none}._13weebvg._13weebvi ._13weebv6{min-width:0;overflow:hidden}._13weebvg._13weebvi ._13weebv9{width:80%}._13weebvg._13weebvi ._13weebv3{background-image:none!important}._13weebvj{display:block}._13weebvk{width:340px;font-size:var(--rc-font-size-sm);background-color:var(--rc-bg);border-color:var(--rc-border);color:var(--rc-text);flex-direction:column;gap:8px;padding:12px;display:flex}._13weebvl{background-color:var(--rc-bg-secondary);border-radius:var(--rc-radius-md);align-items:center;gap:8px;min-width:0;padding:8px 12px;display:flex}._13weebvm{color:var(--rc-text-secondary);flex-shrink:0}._13weebvn{-webkit-appearance:none;appearance:none;color:var(--rc-text);font-family:var(--rc-font-mono);font-size:var(--rc-font-size-sm);background-color:#0000;border:none;outline:none;flex:1;min-width:0;padding:0}@media (max-width:640px){._13weebve{width:100%}}
1
+ :root{--rc-text:#000;--rc-text-secondary:#262626;--rc-text-tertiary:#737373;--rc-text-quaternary:#a3a3a3;--rc-bg:#fff;--rc-bg-secondary:#fafafa;--rc-bg-tertiary:#f5f5f5;--rc-fill:#e8e8e8;--rc-fill-secondary:#eee;--rc-fill-tertiary:#f5f5f5;--rc-fill-quaternary:#fafafa;--rc-border:#f5f5f5;--rc-accent:#2563eb;--rc-accent-light:#2563eb20;--rc-link:#2563eb;--rc-code-text:#404040;--rc-code-bg:#f5f5f5;--rc-hr-border:#e5e5e5;--rc-quote-border:#2563eb;--rc-quote-bg:#f5f5f5;--rc-alert-info:#006bb7;--rc-alert-warning:#c50;--rc-alert-tip:#1c0;--rc-alert-caution:#c01;--rc-alert-important:#50c;--rc-max-width:700px;--rc-shadow-top-bar:0 8px 30px #0000001f, 0 2px 8px #0000000f;--rc-shadow-modal:0 10px 15px -3px #0000001a, 0 4px 6px -4px #0000001a;--rc-shadow-menu:0 1px 4px #0000000a, 0 4px 16px #00000014;--rc-space-xs:4px;--rc-space-sm:8px;--rc-space-md:16px;--rc-space-lg:24px;--rc-space-xl:32px;--rc-font-family-sans:"PingFang SC", "Microsoft YaHei", "Segoe UI", Roboto, Helvetica, "noto sans sc", "hiragino sans gb", -apple-system, system-ui, sans-serif, Apple Color Emoji, Segoe UI Emoji, Not Color Emoji;--rc-font-family-serif:"Noto Serif CJK SC", "Source Han Serif SC", "Source Han Serif", "source-han-serif-sc", "Songti SC", STSong, "华文宋体", serif;--rc-font-family-kai:"楷体", KaiTi, STKaiti, "Kaiti SC", "LXGW WenKai", "霞鹜文楷", "Noto Serif CJK SC", serif;--rc-font-mono:"SF Mono", SFMono-Regular, ui-monospace, "DejaVu Sans Mono", Menlo, Consolas, monospace;--rc-font-size-2xs:.625em;--rc-font-size-xs:.75em;--rc-font-size-sm:.8125em;--rc-font-size-md:.875em;--rc-font-size-lg:1.25em;--rc-font-size-base:16px;--rc-font-size-small:14px;--rc-line-height:1.7;--rc-line-height-tight:1.4;--rc-font-family:"PingFang SC", "Microsoft YaHei", "Segoe UI", Roboto, Helvetica, "noto sans sc", "hiragino sans gb", -apple-system, system-ui, sans-serif, Apple Color Emoji, Segoe UI Emoji, Not Color Emoji;--rc-radius-sm:4px;--rc-radius-md:8px;--rc-radius-lg:12px}:root.dark,[data-theme=dark]{--rc-text:#fafafa;--rc-text-secondary:#a3a3a3;--rc-text-tertiary:#737373;--rc-text-quaternary:#525252;--rc-bg:#0a0a0a;--rc-bg-secondary:#171717;--rc-bg-tertiary:#262626;--rc-fill:#2a2a2a;--rc-fill-secondary:#222;--rc-fill-tertiary:#1a1a1a;--rc-fill-quaternary:#141414;--rc-border:#262626;--rc-accent:#60a5fa;--rc-accent-light:#60a5fa20;--rc-link:#60a5fa;--rc-code-text:#d4d4d4;--rc-code-bg:#262626;--rc-hr-border:#262626;--rc-quote-border:#60a5fa;--rc-quote-bg:#262626;--rc-alert-info:#7db9e5;--rc-alert-warning:#da864a;--rc-alert-tip:#54da48;--rc-alert-caution:#e16973;--rc-alert-important:#9966e0;--rc-max-width:700px;--rc-shadow-top-bar:0 8px 30px #00000073, 0 2px 8px #0000004d;--rc-shadow-modal:0 10px 15px -3px #0006, 0 4px 6px -4px #00000059;--rc-shadow-menu:0 1px 4px #00000040, 0 4px 16px #0006;--rc-space-xs:4px;--rc-space-sm:8px;--rc-space-md:16px;--rc-space-lg:24px;--rc-space-xl:32px;--rc-font-family-sans:"PingFang SC", "Microsoft YaHei", "Segoe UI", Roboto, Helvetica, "noto sans sc", "hiragino sans gb", -apple-system, system-ui, sans-serif, Apple Color Emoji, Segoe UI Emoji, Not Color Emoji;--rc-font-family-serif:"Noto Serif CJK SC", "Source Han Serif SC", "Source Han Serif", "source-han-serif-sc", "Songti SC", STSong, "华文宋体", serif;--rc-font-family-kai:"楷体", KaiTi, STKaiti, "Kaiti SC", "LXGW WenKai", "霞鹜文楷", "Noto Serif CJK SC", serif;--rc-font-mono:"SF Mono", SFMono-Regular, ui-monospace, "DejaVu Sans Mono", Menlo, Consolas, monospace;--rc-font-size-2xs:.625em;--rc-font-size-xs:.75em;--rc-font-size-sm:.8125em;--rc-font-size-md:.875em;--rc-font-size-lg:1.25em;--rc-font-size-base:16px;--rc-font-size-small:14px;--rc-line-height:1.7;--rc-line-height-tight:1.4;--rc-font-family:"PingFang SC", "Microsoft YaHei", "Segoe UI", Roboto, Helvetica, "noto sans sc", "hiragino sans gb", -apple-system, system-ui, sans-serif, Apple Color Emoji, Segoe UI Emoji, Not Color Emoji;--rc-radius-sm:4px;--rc-radius-md:8px;--rc-radius-lg:12px}._1osyxsk0{--rc-text:#000;--rc-text-secondary:#262626;--rc-text-tertiary:#737373;--rc-text-quaternary:#a3a3a3;--rc-bg:#fff;--rc-bg-secondary:#fafafa;--rc-bg-tertiary:#f5f5f5;--rc-fill:#e8e8e8;--rc-fill-secondary:#eee;--rc-fill-tertiary:#f5f5f5;--rc-fill-quaternary:#fafafa;--rc-border:#f5f5f5;--rc-accent:#2563eb;--rc-accent-light:#2563eb20;--rc-link:#2563eb;--rc-code-text:#404040;--rc-code-bg:#f5f5f5;--rc-hr-border:#e5e5e5;--rc-quote-border:#2563eb;--rc-quote-bg:#f5f5f5;--rc-alert-info:#006bb7;--rc-alert-warning:#c50;--rc-alert-tip:#1c0;--rc-alert-caution:#c01;--rc-alert-important:#50c;--rc-max-width:700px;--rc-shadow-top-bar:0 8px 30px #0000001f, 0 2px 8px #0000000f;--rc-shadow-modal:0 10px 15px -3px #0000001a, 0 4px 6px -4px #0000001a;--rc-shadow-menu:0 1px 4px #0000000a, 0 4px 16px #00000014;--rc-space-xs:4px;--rc-space-sm:8px;--rc-space-md:16px;--rc-space-lg:24px;--rc-space-xl:32px;--rc-font-family-sans:"PingFang SC", "Microsoft YaHei", "Segoe UI", Roboto, Helvetica, "noto sans sc", "hiragino sans gb", -apple-system, system-ui, sans-serif, Apple Color Emoji, Segoe UI Emoji, Not Color Emoji;--rc-font-family-serif:"Noto Serif CJK SC", "Source Han Serif SC", "Source Han Serif", "source-han-serif-sc", "Songti SC", STSong, "华文宋体", serif;--rc-font-family-kai:"楷体", KaiTi, STKaiti, "Kaiti SC", "LXGW WenKai", "霞鹜文楷", "Noto Serif CJK SC", serif;--rc-font-mono:"SF Mono", SFMono-Regular, ui-monospace, "DejaVu Sans Mono", Menlo, Consolas, monospace;--rc-font-size-2xs:.625em;--rc-font-size-xs:.75em;--rc-font-size-sm:.8125em;--rc-font-size-md:.875em;--rc-font-size-lg:1.25em;--rc-font-size-base:16px;--rc-font-size-small:14px;--rc-line-height:1.7;--rc-line-height-tight:1.4;--rc-font-family:"PingFang SC", "Microsoft YaHei", "Segoe UI", Roboto, Helvetica, "noto sans sc", "hiragino sans gb", -apple-system, system-ui, sans-serif, Apple Color Emoji, Segoe UI Emoji, Not Color Emoji;--rc-radius-sm:4px;--rc-radius-md:8px;--rc-radius-lg:12px}._1osyxsk1{--rc-text:#000;--rc-text-secondary:#262626;--rc-text-tertiary:#737373;--rc-text-quaternary:#a3a3a3;--rc-bg:#fff;--rc-bg-secondary:#fafafa;--rc-bg-tertiary:#f5f5f5;--rc-fill:#e8e8e8;--rc-fill-secondary:#eee;--rc-fill-tertiary:#f5f5f5;--rc-fill-quaternary:#fafafa;--rc-border:#f5f5f5;--rc-accent:#2563eb;--rc-accent-light:#2563eb20;--rc-link:#2563eb;--rc-code-text:#404040;--rc-code-bg:#f5f5f5;--rc-hr-border:#e5e5e5;--rc-quote-border:#2563eb;--rc-quote-bg:#f5f5f5;--rc-alert-info:#006bb7;--rc-alert-warning:#c50;--rc-alert-tip:#1c0;--rc-alert-caution:#c01;--rc-alert-important:#50c;--rc-max-width:700px;--rc-shadow-top-bar:0 8px 30px #0000001f, 0 2px 8px #0000000f;--rc-shadow-modal:0 10px 15px -3px #0000001a, 0 4px 6px -4px #0000001a;--rc-shadow-menu:0 1px 4px #0000000a, 0 4px 16px #00000014;--rc-space-xs:4px;--rc-space-sm:8px;--rc-space-md:16px;--rc-space-lg:24px;--rc-space-xl:32px;--rc-font-family-sans:"PingFang SC", "Microsoft YaHei", "Segoe UI", Roboto, Helvetica, "noto sans sc", "hiragino sans gb", -apple-system, system-ui, sans-serif, Apple Color Emoji, Segoe UI Emoji, Not Color Emoji;--rc-font-family-serif:"Noto Serif CJK SC", "Source Han Serif SC", "Source Han Serif", "source-han-serif-sc", "Songti SC", STSong, "华文宋体", serif;--rc-font-family-kai:"楷体", KaiTi, STKaiti, "Kaiti SC", "LXGW WenKai", "霞鹜文楷", "Noto Serif CJK SC", serif;--rc-font-mono:"SF Mono", SFMono-Regular, ui-monospace, "DejaVu Sans Mono", Menlo, Consolas, monospace;--rc-font-size-2xs:.625em;--rc-font-size-xs:.75em;--rc-font-size-sm:.8125em;--rc-font-size-md:.875em;--rc-font-size-lg:1.25em;--rc-font-size-base:16px;--rc-font-size-small:14px;--rc-line-height:1.8;--rc-line-height-tight:1.4;--rc-font-family:"Noto Serif CJK SC", "Source Han Serif SC", "Source Han Serif", "source-han-serif-sc", "Songti SC", STSong, "华文宋体", serif;--rc-radius-sm:4px;--rc-radius-md:8px;--rc-radius-lg:12px}._1osyxsk2{--rc-text:#000;--rc-text-secondary:#262626;--rc-text-tertiary:#737373;--rc-text-quaternary:#a3a3a3;--rc-bg:#fff;--rc-bg-secondary:#fafafa;--rc-bg-tertiary:#f5f5f5;--rc-fill:#e8e8e8;--rc-fill-secondary:#eee;--rc-fill-tertiary:#f5f5f5;--rc-fill-quaternary:#fafafa;--rc-border:#f5f5f5;--rc-accent:#2563eb;--rc-accent-light:#2563eb20;--rc-link:#2563eb;--rc-code-text:#404040;--rc-code-bg:#f5f5f5;--rc-hr-border:#e5e5e5;--rc-quote-border:#a3a3a3;--rc-quote-bg:#fafafa;--rc-alert-info:#006bb7;--rc-alert-warning:#c50;--rc-alert-tip:#1c0;--rc-alert-caution:#c01;--rc-alert-important:#50c;--rc-max-width:none;--rc-shadow-top-bar:0 8px 30px #0000001f, 0 2px 8px #0000000f;--rc-shadow-modal:0 10px 15px -3px #0000001a, 0 4px 6px -4px #0000001a;--rc-shadow-menu:0 1px 4px #0000000a, 0 4px 16px #00000014;--rc-space-xs:2px;--rc-space-sm:4px;--rc-space-md:10px;--rc-space-lg:16px;--rc-space-xl:20px;--rc-font-family-sans:"PingFang SC", "Microsoft YaHei", "Segoe UI", Roboto, Helvetica, "noto sans sc", "hiragino sans gb", -apple-system, system-ui, sans-serif, Apple Color Emoji, Segoe UI Emoji, Not Color Emoji;--rc-font-family-serif:"Noto Serif CJK SC", "Source Han Serif SC", "Source Han Serif", "source-han-serif-sc", "Songti SC", STSong, "华文宋体", serif;--rc-font-family-kai:"楷体", KaiTi, STKaiti, "Kaiti SC", "LXGW WenKai", "霞鹜文楷", "Noto Serif CJK SC", serif;--rc-font-mono:"SF Mono", SFMono-Regular, ui-monospace, "DejaVu Sans Mono", Menlo, Consolas, monospace;--rc-font-size-2xs:.625em;--rc-font-size-xs:.75em;--rc-font-size-sm:.8125em;--rc-font-size-md:.875em;--rc-font-size-lg:1.25em;--rc-font-size-base:14px;--rc-font-size-small:12px;--rc-line-height:1.5;--rc-line-height-tight:1.3;--rc-font-family:"PingFang SC", "Microsoft YaHei", "Segoe UI", Roboto, Helvetica, "noto sans sc", "hiragino sans gb", -apple-system, system-ui, sans-serif, Apple Color Emoji, Segoe UI Emoji, Not Color Emoji;--rc-radius-sm:3px;--rc-radius-md:6px;--rc-radius-lg:12px}.dark ._1osyxsk0,[data-theme=dark] ._1osyxsk0,.dark._1osyxsk0,[data-theme=dark]._1osyxsk0,.dark ._1osyxsk1,[data-theme=dark] ._1osyxsk1,.dark._1osyxsk1,[data-theme=dark]._1osyxsk1,.dark ._1osyxsk2,[data-theme=dark] ._1osyxsk2,.dark._1osyxsk2,[data-theme=dark]._1osyxsk2{--rc-text:#fafafa;--rc-text-secondary:#a3a3a3;--rc-text-tertiary:#737373;--rc-text-quaternary:#525252;--rc-bg:#0a0a0a;--rc-bg-secondary:#171717;--rc-bg-tertiary:#262626;--rc-fill:#2a2a2a;--rc-fill-secondary:#222;--rc-fill-tertiary:#1a1a1a;--rc-fill-quaternary:#141414;--rc-border:#262626;--rc-accent:#60a5fa;--rc-accent-light:#60a5fa20;--rc-link:#60a5fa;--rc-code-text:#d4d4d4;--rc-code-bg:#262626;--rc-hr-border:#262626;--rc-quote-border:#60a5fa;--rc-quote-bg:#262626;--rc-alert-info:#7db9e5;--rc-alert-warning:#da864a;--rc-alert-tip:#54da48;--rc-alert-caution:#e16973;--rc-alert-important:#9966e0;--rc-shadow-top-bar:0 8px 30px #00000073, 0 2px 8px #0000004d;--rc-shadow-modal:0 10px 15px -3px #0006, 0 4px 6px -4px #00000059;--rc-shadow-menu:0 1px 4px #00000040, 0 4px 16px #0006}@keyframes _13weebvf{0%,to{opacity:1}50%{opacity:.5}}._13weebv0{box-sizing:border-box;cursor:pointer;width:32rem;max-width:100%;color:inherit;text-indent:0;font-family:var(--rc-font-family-sans);border:1px solid var(--rc-border);background-color:color-mix(in srgb, var(--rc-bg-secondary) 60%, transparent);-webkit-backdrop-filter:blur(12px)saturate(150%);backdrop-filter:blur(12px)saturate(150%);border-radius:.625rem;align-items:flex-start;gap:.75rem;margin:1.25rem auto;padding:.875rem 1rem;text-decoration:none;transition:border-color .15s,background-color .15s;display:flex;position:relative;overflow:hidden}._13weebv0:hover{border-color:color-mix(in srgb, var(--rc-border), var(--rc-text) 25%);background-color:var(--rc-fill-tertiary);text-decoration:none}._13weebv0:focus,._13weebv0:active{text-decoration:none}._13weebv0:focus-visible{text-decoration:none}._13weebv1{align-items:center}._13weebv0 *{font-style:normal!important}._13weebv0 span{border-bottom:0!important}._13weebv0,._13weebv0:hover,._13weebv0:focus,._13weebv0:active{text-decoration:none!important}._13weebv0:focus-visible{text-decoration:none!important}._13weebv2{z-index:0;pointer-events:none;position:absolute;top:0;bottom:0;left:0;right:0}._13weebv3{background-position:50%;background-repeat:no-repeat;background-size:cover;background-color:var(--rc-bg-tertiary);z-index:1;border-radius:.5rem;flex-shrink:0;width:2.5rem;height:2.5rem;position:relative;box-shadow:inset 0 0 0 1px #0000000a}._13weebv4{background-color:var(--rc-bg-tertiary);z-index:1;border-radius:.5rem;flex-shrink:0;justify-content:center;align-items:center;width:2.5rem;height:2.5rem;display:flex;box-shadow:inset 0 0 0 1px #0000000a}._13weebv4 img{border-radius:.25rem;width:1.25rem;height:1.25rem}._13weebv4 svg{width:1.25rem;height:1.25rem;color:var(--rc-text-tertiary)}._13weebv5{z-index:1;flex:1;min-width:0;position:relative}._13weebv6{align-items:center;gap:.5rem;line-height:1.25rem;display:flex}._13weebv7{line-clamp:1;-webkit-line-clamp:1;text-overflow:ellipsis;min-width:0;font-size:var(--rc-font-size-md);-webkit-box-orient:vertical;flex:1;font-weight:500;line-height:1.25rem;display:-webkit-box;overflow:hidden}._13weebv8{-webkit-line-clamp:2;text-overflow:ellipsis;font-size:var(--rc-font-size-md);color:var(--rc-text-tertiary);-webkit-box-orient:vertical;min-width:0;margin-top:.375rem;line-height:1.5;display:-webkit-box;overflow:hidden}._13weebvb{width:36rem}._13weebvb ._13weebv8{-webkit-line-clamp:3}._13weebvc{width:100%;max-width:42rem}._13weebvc ._13weebv8{-webkit-line-clamp:4}._13weebvd{align-items:stretch;gap:0;width:100%;max-width:40rem;padding:0}._13weebvd ._13weebv3{aspect-ratio:2/3;box-shadow:none;border-radius:0;align-self:stretch;width:6.75rem!important;height:auto!important}._13weebvd ._13weebv5{flex-direction:column;justify-content:center;padding:1rem 1.125rem;display:flex}._13weebvd ._13weebv8{-webkit-line-clamp:3}._13weebve ._13weebv7{background-color:var(--rc-bg-tertiary);border-radius:.25rem;width:8rem;height:1rem}._13weebve ._13weebv8{background-color:var(--rc-bg-tertiary);border-radius:.25rem;width:100%;height:.75rem;margin-top:.5rem}._13weebve ._13weebv9{width:75%}._13weebve ._13weebv3{background-color:var(--rc-bg-tertiary);background-image:none!important}._13weebve ._13weebv7,._13weebve ._13weebv8,._13weebve ._13weebv3{animation:1.6s cubic-bezier(.4,0,.6,1) infinite _13weebvf}._13weebvg{border:1px dashed var(--rc-border);background-color:var(--rc-bg);width:32rem;max-width:100%;color:var(--rc-text-tertiary);font-family:var(--rc-font-family-sans);cursor:pointer;border-radius:.625rem;align-items:center;gap:.75rem;margin:1.25rem auto;padding:.75rem .875rem;text-decoration:none;transition:border-color .15s,background-color .15s;display:flex}._13weebvg:hover{border-color:color-mix(in srgb, var(--rc-border), var(--rc-text) 25%);background-color:var(--rc-fill-quaternary);text-decoration:none}._13weebvg:focus,._13weebvg:active{text-decoration:none}._13weebvg:focus-visible{text-decoration:none}._13weebvh{background-color:var(--rc-bg-secondary);border-radius:.5rem;flex-shrink:0;justify-content:center;align-items:center;width:2rem;height:2rem;display:flex}._13weebvh svg{width:.875rem;height:.875rem;color:var(--rc-text-quaternary)}._13weebvi{flex:1;min-width:0}._13weebvj{font-size:var(--rc-font-size-md);color:var(--rc-text-secondary);text-overflow:ellipsis;white-space:nowrap;font-weight:500;display:block;overflow:hidden}._13weebvk{font-size:var(--rc-font-size-xs);color:var(--rc-text-quaternary);margin-top:.125rem;display:block}._13weebvl{display:block}._13weebvm{width:340px;font-size:var(--rc-font-size-sm);background-color:var(--rc-bg);border-color:var(--rc-border);color:var(--rc-text);flex-direction:column;gap:8px;padding:12px;display:flex}._13weebvn{background-color:var(--rc-bg-secondary);border-radius:var(--rc-radius-md);align-items:center;gap:8px;min-width:0;padding:8px 12px;display:flex}._13weebvo{color:var(--rc-text-secondary);flex-shrink:0}._13weebvp{-webkit-appearance:none;appearance:none;color:var(--rc-text);font-family:var(--rc-font-mono);font-size:var(--rc-font-size-sm);background-color:#0000;border:none;outline:none;flex:1;min-width:0;padding:0}
2
2
  /*$vite$:1*/
package/dist/static.d.ts CHANGED
@@ -8,6 +8,6 @@ export { getPluginByName, pluginMap, plugins } from './plugins';
8
8
  export { arxivPlugin, bangumiPlugin, githubCommitPlugin, githubDiscussionPlugin, githubIssuePlugin, githubPrPlugin, githubRepoPlugin, leetcodePlugin, neteaseMusicPlugin, qqMusicPlugin, tmdbPlugin, } from './plugins';
9
9
  export { createMxSpacePlugin } from './plugins';
10
10
  export type { MxSpacePluginConfig } from './plugins/self';
11
- export type { LinkCardApiAdapter, LinkCardData, LinkCardFetchContext, LinkCardPlugin, LinkCardTypeClass, PluginRegistry, UrlMatchResult, } from './types';
11
+ export type { LinkCardApiAdapter, LinkCardData, LinkCardFetchContext, LinkCardPlugin, LinkCardShape, PluginRegistry, UrlMatchResult, } from './types';
12
12
  export { camelcaseKeys, fetchGitHubApi, fetchJsonWithContext, generateColor, LanguageToColorMap, } from './utils';
13
13
  //# sourceMappingURL=static.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"static.d.ts","sourceRoot":"","sources":["../src/static.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,qBAAqB,EAAE,uBAAuB,EAAE,MAAM,gBAAgB,CAAA;AAC/E,YAAY,EAAE,YAAY,EAAE,MAAM,uBAAuB,CAAA;AACzD,OAAO,EAAE,QAAQ,EAAE,aAAa,EAAE,MAAM,uBAAuB,CAAA;AAC/D,YAAY,EAAE,qBAAqB,EAAE,MAAM,oBAAoB,CAAA;AAC/D,OAAO,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAA;AACrD,OAAO,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAA;AACrD,OAAO,EAAE,eAAe,EAAE,SAAS,EAAE,OAAO,EAAE,MAAM,WAAW,CAAA;AAC/D,OAAO,EACL,WAAW,EACX,aAAa,EACb,kBAAkB,EAClB,sBAAsB,EACtB,iBAAiB,EACjB,cAAc,EACd,gBAAgB,EAChB,cAAc,EACd,kBAAkB,EAClB,aAAa,EACb,UAAU,GACX,MAAM,WAAW,CAAA;AAClB,OAAO,EAAE,mBAAmB,EAAE,MAAM,WAAW,CAAA;AAC/C,YAAY,EAAE,mBAAmB,EAAE,MAAM,gBAAgB,CAAA;AACzD,YAAY,EACV,kBAAkB,EAClB,YAAY,EACZ,oBAAoB,EACpB,cAAc,EACd,iBAAiB,EACjB,cAAc,EACd,cAAc,GACf,MAAM,SAAS,CAAA;AAChB,OAAO,EACL,aAAa,EACb,cAAc,EACd,oBAAoB,EACpB,aAAa,EACb,kBAAkB,GACnB,MAAM,SAAS,CAAA"}
1
+ {"version":3,"file":"static.d.ts","sourceRoot":"","sources":["../src/static.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,qBAAqB,EAAE,uBAAuB,EAAE,MAAM,gBAAgB,CAAC;AAChF,YAAY,EAAE,YAAY,EAAE,MAAM,uBAAuB,CAAC;AAC1D,OAAO,EAAE,QAAQ,EAAE,aAAa,EAAE,MAAM,uBAAuB,CAAC;AAChE,YAAY,EAAE,qBAAqB,EAAE,MAAM,oBAAoB,CAAC;AAChE,OAAO,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAC;AACtD,OAAO,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAC;AACtD,OAAO,EAAE,eAAe,EAAE,SAAS,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAChE,OAAO,EACL,WAAW,EACX,aAAa,EACb,kBAAkB,EAClB,sBAAsB,EACtB,iBAAiB,EACjB,cAAc,EACd,gBAAgB,EAChB,cAAc,EACd,kBAAkB,EAClB,aAAa,EACb,UAAU,GACX,MAAM,WAAW,CAAC;AACnB,OAAO,EAAE,mBAAmB,EAAE,MAAM,WAAW,CAAC;AAChD,YAAY,EAAE,mBAAmB,EAAE,MAAM,gBAAgB,CAAC;AAC1D,YAAY,EACV,kBAAkB,EAClB,YAAY,EACZ,oBAAoB,EACpB,cAAc,EACd,aAAa,EACb,cAAc,EACd,cAAc,GACf,MAAM,SAAS,CAAC;AACjB,OAAO,EACL,aAAa,EACb,cAAc,EACd,oBAAoB,EACpB,aAAa,EACb,kBAAkB,GACnB,MAAM,SAAS,CAAC"}
package/dist/static.mjs CHANGED
@@ -1,2 +1,2 @@
1
- import { A as fetchJsonWithContext, C as githubIssuePlugin, D as LanguageToColorMap, E as leetcodePlugin, M as arxivPlugin, O as camelcaseKeys, S as githubPrPlugin, T as githubCommitPlugin, _ as tmdbPlugin, b as bangumiPlugin, d as matchUrl, f as useUrlMatcher, g as createMxSpacePlugin, h as plugins, i as useLinkCardFetchContext, j as generateColor, k as fetchGitHubApi, m as pluginMap, n as LinkCardSkeleton, p as getPluginByName, r as LinkCardFetchProvider, t as LinkCardRenderer, v as qqMusicPlugin, w as githubDiscussionPlugin, x as githubRepoPlugin, y as neteaseMusicPlugin } from "./LinkCardRenderer-DqaMJub3.js";
1
+ import { A as fetchJsonWithContext, C as githubIssuePlugin, D as LanguageToColorMap, E as leetcodePlugin, M as arxivPlugin, O as camelcaseKeys, S as githubPrPlugin, T as githubCommitPlugin, _ as tmdbPlugin, b as bangumiPlugin, d as matchUrl, f as useUrlMatcher, g as createMxSpacePlugin, h as plugins, i as useLinkCardFetchContext, j as generateColor, k as fetchGitHubApi, m as pluginMap, n as LinkCardSkeleton, p as getPluginByName, r as LinkCardFetchProvider, t as LinkCardRenderer, v as qqMusicPlugin, w as githubDiscussionPlugin, x as githubRepoPlugin, y as neteaseMusicPlugin } from "./LinkCardRenderer-D_FokwfU.js";
2
2
  export { LanguageToColorMap, LinkCardFetchProvider, LinkCardRenderer, LinkCardSkeleton, arxivPlugin, bangumiPlugin, camelcaseKeys, createMxSpacePlugin, fetchGitHubApi, fetchJsonWithContext, generateColor, getPluginByName, githubCommitPlugin, githubDiscussionPlugin, githubIssuePlugin, githubPrPlugin, githubRepoPlugin, leetcodePlugin, matchUrl, neteaseMusicPlugin, pluginMap, plugins, qqMusicPlugin, tmdbPlugin, useLinkCardFetchContext, useUrlMatcher };
@@ -3,20 +3,21 @@ export declare const semanticClassNames: {
3
3
  readonly cardShortDesc: "link-card--short-desc";
4
4
  readonly cardSkeleton: "link-card--skeleton";
5
5
  readonly cardError: "link-card--error";
6
- readonly cardPoster: "link-card--poster";
6
+ readonly cardCompact: "link-card--compact";
7
+ readonly cardExpanded: "link-card--expanded";
7
8
  readonly cardWide: "link-card--wide";
8
- readonly cardMedia: "link-card--media";
9
- readonly cardGithub: "link-card--github";
10
- readonly cardAcademic: "link-card--academic";
9
+ readonly cardPoster: "link-card--poster";
11
10
  readonly bg: "link-card__bg";
12
11
  readonly image: "link-card__image";
13
- readonly imagePoster: "link-card__image--poster";
14
12
  readonly icon: "link-card__icon";
15
13
  readonly content: "link-card__content";
16
14
  readonly title: "link-card__title";
17
15
  readonly titleText: "link-card__title-text";
18
16
  readonly desc: "link-card__desc";
19
17
  readonly desc2: "link-card__desc-2";
18
+ readonly errorContent: "link-card__error-content";
19
+ readonly errorUrl: "link-card__error-url";
20
+ readonly errorHint: "link-card__error-hint";
20
21
  readonly editWrapper: "rich-link-card-edit-wrapper";
21
22
  readonly editPanel: "rich-link-card-edit-panel";
22
23
  readonly editUrlRow: "rich-link-card-edit-url-row";
@@ -27,36 +28,37 @@ export declare const card: string;
27
28
  export declare const cardShortDesc: string;
28
29
  export declare const bg: string;
29
30
  export declare const image: string;
30
- export declare const imagePoster: string;
31
31
  export declare const icon: string;
32
32
  export declare const content: string;
33
33
  export declare const title: string;
34
34
  export declare const titleText: string;
35
35
  export declare const desc: string;
36
36
  export declare const desc2: string;
37
- export declare const cardPoster: string;
38
- export declare const cardWide: string;
39
- export declare const cardMedia: string;
40
- export declare const cardGithub: string;
41
- export declare const cardAcademic: string;
37
+ export declare const shapeCompact: string;
38
+ export declare const shapeExpanded: string;
39
+ export declare const shapeWide: string;
40
+ export declare const shapePoster: string;
42
41
  export declare const cardSkeleton: string;
43
42
  export declare const cardError: string;
43
+ export declare const errorIcon: string;
44
+ export declare const errorContent: string;
45
+ export declare const errorUrl: string;
46
+ export declare const errorHint: string;
44
47
  export declare const editWrapper: string;
45
48
  export declare const editPanel: string;
46
49
  export declare const editUrlRow: string;
47
50
  export declare const editLinkIcon: string;
48
51
  export declare const editInput: string;
49
- export declare const typeCardModifier: {
50
- readonly media: string;
51
- readonly github: string;
52
- readonly academic: string;
52
+ export declare const shapeClass: {
53
+ readonly compact: string;
54
+ readonly expanded: string;
53
55
  readonly wide: string;
56
+ readonly poster: string;
54
57
  };
55
- export declare const semanticTypeClassNames: {
56
- readonly media: "link-card--media";
57
- readonly github: "link-card--github";
58
- readonly academic: "link-card--academic";
58
+ export declare const semanticShapeClass: {
59
+ readonly compact: "link-card--compact";
60
+ readonly expanded: "link-card--expanded";
59
61
  readonly wide: "link-card--wide";
62
+ readonly poster: "link-card--poster";
60
63
  };
61
- export declare const semanticClassToStyle: Record<string, string>;
62
64
  //# sourceMappingURL=styles.css.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"styles.css.d.ts","sourceRoot":"","sources":["../src/styles.css.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,kBAAkB;;;;;;;;;;;;;;;;;;;;;;;;CAyBrB,CAAC;AAEX,eAAO,MAAM,IAAI,QA+Bf,CAAC;AAEH,eAAO,MAAM,aAAa,QAExB,CAAC;AASH,eAAO,MAAM,EAAE,QAKb,CAAC;AAEH,eAAO,MAAM,KAAK,QAWhB,CAAC;AAEH,eAAO,MAAM,WAAW,QAMtB,CAAC;AAEH,eAAO,MAAM,IAAI,QAUf,CAAC;AAcH,eAAO,MAAM,OAAO,QAKlB,CAAC;AAEH,eAAO,MAAM,KAAK,QAKhB,CAAC;AAEH,eAAO,MAAM,SAAS,QAYpB,CAAC;AAEH,eAAO,MAAM,IAAI,QAWf,CAAC;AAEH,eAAO,MAAM,KAAK,QAAY,CAAC;AAE/B,eAAO,MAAM,UAAU,QAKrB,CAAC;AAwBH,eAAO,MAAM,QAAQ,QAA8C,CAAC;AACpE,eAAO,MAAM,SAAS,QAGpB,CAAC;AAGH,eAAO,MAAM,UAAU,QAGrB,CAAC;AAEH,eAAO,MAAM,YAAY,QAA4B,CAAC;AAkBtD,eAAO,MAAM,YAAY,QAA0C,CAAC;AAuCpE,eAAO,MAAM,SAAS,QAAY,CAAC;AA8BnC,eAAO,MAAM,WAAW,QAEtB,CAAC;AAEH,eAAO,MAAM,SAAS,QAUpB,CAAC;AAEH,eAAO,MAAM,UAAU,QAQrB,CAAC;AAEH,eAAO,MAAM,YAAY,QAGvB,CAAC;AAEH,eAAO,MAAM,SAAS,QAWpB,CAAC;AAEH,eAAO,MAAM,gBAAgB;;;;;CAKnB,CAAC;AAEX,eAAO,MAAM,sBAAsB;;;;;CAKzB,CAAC;AAEX,eAAO,MAAM,oBAAoB,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAUvD,CAAC"}
1
+ {"version":3,"file":"styles.css.d.ts","sourceRoot":"","sources":["../src/styles.css.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,kBAAkB;;;;;;;;;;;;;;;;;;;;;;;;;CAyBrB,CAAC;AAIX,eAAO,MAAM,IAAI,QA6Bf,CAAC;AAEH,eAAO,MAAM,aAAa,QAAkC,CAAC;AAQ7D,eAAO,MAAM,EAAE,QAKb,CAAC;AAEH,eAAO,MAAM,KAAK,QAYhB,CAAC;AAEH,eAAO,MAAM,IAAI,QAWf,CAAC;AAcH,eAAO,MAAM,OAAO,QAKlB,CAAC;AAEH,eAAO,MAAM,KAAK,QAKhB,CAAC;AAEH,eAAO,MAAM,SAAS,QAYpB,CAAC;AAEH,eAAO,MAAM,IAAI,QAWf,CAAC;AAEH,eAAO,MAAM,KAAK,QAAY,CAAC;AAG/B,eAAO,MAAM,YAAY,QAAY,CAAC;AAGtC,eAAO,MAAM,aAAa,QAA4B,CAAC;AAIvD,eAAO,MAAM,SAAS,QAGpB,CAAC;AAIH,eAAO,MAAM,WAAW,QAMtB,CAAC;AAqBH,eAAO,MAAM,YAAY,QAAY,CAAC;AAkCtC,eAAO,MAAM,SAAS,QAwBpB,CAAC;AAEH,eAAO,MAAM,SAAS,QASpB,CAAC;AAQH,eAAO,MAAM,YAAY,QAGvB,CAAC;AAEH,eAAO,MAAM,QAAQ,QAQnB,CAAC;AAEH,eAAO,MAAM,SAAS,QAKpB,CAAC;AAGH,eAAO,MAAM,WAAW,QAEtB,CAAC;AAEH,eAAO,MAAM,SAAS,QAUpB,CAAC;AAEH,eAAO,MAAM,UAAU,QAQrB,CAAC;AAEH,eAAO,MAAM,YAAY,QAGvB,CAAC;AAEH,eAAO,MAAM,SAAS,QAWpB,CAAC;AAGH,eAAO,MAAM,UAAU;;;;;CAKb,CAAC;AAEX,eAAO,MAAM,kBAAkB;;;;;CAKrB,CAAC"}
package/dist/types.d.ts CHANGED
@@ -3,11 +3,6 @@ import { ReactNode } from 'react';
3
3
  * 卡片数据 - 插件只提供数据,渲染统一
4
4
  */
5
5
  export interface LinkCardData {
6
- /** CSS 类名覆盖 */
7
- classNames?: {
8
- image?: string;
9
- cardRoot?: string;
10
- };
11
6
  /** 高亮/主题色 (hex 格式) */
12
7
  color?: string;
13
8
  /** 卡片描述 */
@@ -48,8 +43,14 @@ export interface LinkCardFetchContext {
48
43
  */
49
44
  fetchJson?: <T = unknown>(input: string, init?: RequestInit) => Promise<T>;
50
45
  }
51
- /** 卡片类型样式 */
52
- export type LinkCardTypeClass = 'media' | 'github' | 'academic' | 'wide';
46
+ /**
47
+ * 卡片形状(layout shape)
48
+ * - compact: 默认横版小图,标题 + 双行 desc
49
+ * - expanded: 较宽,三行 desc(长摘要场景)
50
+ * - wide: 全宽,多行块状 desc(音乐 / 题目)
51
+ * - poster: 全宽 + 直立海报图(影 / 番剧)
52
+ */
53
+ export type LinkCardShape = 'compact' | 'expanded' | 'wide' | 'poster';
53
54
  /**
54
55
  * 插件接口 - 每个插件自包含
55
56
  */
@@ -78,8 +79,8 @@ export interface LinkCardPlugin<TMeta = Record<string, unknown>> {
78
79
  readonly priority?: number;
79
80
  /** 插件依赖的 provider 名称,用于路由到对应请求适配器 */
80
81
  readonly provider?: string;
81
- /** 卡片样式类型 */
82
- readonly typeClass?: LinkCardTypeClass;
82
+ /** 卡片形状 */
83
+ readonly shape?: LinkCardShape;
83
84
  }
84
85
  /**
85
86
  * 插件注册表类型
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAEvC;;GAEG;AACH,MAAM,WAAW,YAAY;IAC3B,eAAe;IACf,UAAU,CAAC,EAAE;QACX,KAAK,CAAC,EAAE,MAAM,CAAC;QACf,QAAQ,CAAC,EAAE,MAAM,CAAC;KACnB,CAAC;IACF,sBAAsB;IACtB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,WAAW;IACX,IAAI,CAAC,EAAE,SAAS,CAAC;IACjB,aAAa;IACb,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,WAAW;IACX,KAAK,EAAE,SAAS,CAAC;CAClB;AAED;;GAEG;AACH,MAAM,WAAW,cAAc;IAC7B,qBAAqB;IACrB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,cAAc;IACd,EAAE,EAAE,MAAM,CAAC;IACX,YAAY;IACZ,IAAI,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;CAChC;AAED;;GAEG;AACH,MAAM,WAAW,kBAAkB;IACjC,OAAO,EAAE,CAAC,CAAC,GAAG,OAAO,EAAE,KAAK,EAAE,MAAM,EAAE,IAAI,CAAC,EAAE,WAAW,KAAK,OAAO,CAAC,CAAC,CAAC,CAAC;CACzE;AAED;;GAEG;AACH,MAAM,WAAW,oBAAoB;IACnC;;;OAGG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,kBAAkB,CAAC,CAAC;IAC9C;;OAEG;IACH,SAAS,CAAC,EAAE,CAAC,CAAC,GAAG,OAAO,EAAE,KAAK,EAAE,MAAM,EAAE,IAAI,CAAC,EAAE,WAAW,KAAK,OAAO,CAAC,CAAC,CAAC,CAAC;CAC5E;AAED,aAAa;AACb,MAAM,MAAM,iBAAiB,GAAG,OAAO,GAAG,QAAQ,GAAG,UAAU,GAAG,MAAM,CAAC;AAEzE;;GAEG;AACH,MAAM,WAAW,cAAc,CAAC,KAAK,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC;IAC7D,mBAAmB;IACnB,QAAQ,CAAC,WAAW,EAAE,MAAM,CAAC;IAE7B;;;;;OAKG;IACH,KAAK,EAAE,CAAC,EAAE,EAAE,MAAM,EAAE,IAAI,CAAC,EAAE,KAAK,EAAE,OAAO,CAAC,EAAE,oBAAoB,KAAK,OAAO,CAAC,YAAY,CAAC,CAAC;IAE3F;;OAEG;IACH,SAAS,EAAE,CAAC,EAAE,EAAE,MAAM,KAAK,OAAO,CAAC;IAEnC;;;OAGG;IACH,QAAQ,EAAE,CAAC,GAAG,EAAE,GAAG,KAAK,cAAc,GAAG,IAAI,CAAC;IAC9C,YAAY;IACZ,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IAEtB,wBAAwB;IACxB,QAAQ,CAAC,QAAQ,CAAC,EAAE,MAAM,CAAC;IAE3B,qCAAqC;IACrC,QAAQ,CAAC,QAAQ,CAAC,EAAE,MAAM,CAAC;IAE3B,aAAa;IACb,QAAQ,CAAC,SAAS,CAAC,EAAE,iBAAiB,CAAC;CACxC;AAED;;GAEG;AACH,MAAM,MAAM,cAAc,GAAG,SAAS,cAAc,EAAE,CAAC"}
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAEvC;;GAEG;AACH,MAAM,WAAW,YAAY;IAC3B,sBAAsB;IACtB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,WAAW;IACX,IAAI,CAAC,EAAE,SAAS,CAAC;IACjB,aAAa;IACb,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,WAAW;IACX,KAAK,EAAE,SAAS,CAAC;CAClB;AAED;;GAEG;AACH,MAAM,WAAW,cAAc;IAC7B,qBAAqB;IACrB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,cAAc;IACd,EAAE,EAAE,MAAM,CAAC;IACX,YAAY;IACZ,IAAI,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;CAChC;AAED;;GAEG;AACH,MAAM,WAAW,kBAAkB;IACjC,OAAO,EAAE,CAAC,CAAC,GAAG,OAAO,EAAE,KAAK,EAAE,MAAM,EAAE,IAAI,CAAC,EAAE,WAAW,KAAK,OAAO,CAAC,CAAC,CAAC,CAAC;CACzE;AAED;;GAEG;AACH,MAAM,WAAW,oBAAoB;IACnC;;;OAGG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,kBAAkB,CAAC,CAAC;IAC9C;;OAEG;IACH,SAAS,CAAC,EAAE,CAAC,CAAC,GAAG,OAAO,EAAE,KAAK,EAAE,MAAM,EAAE,IAAI,CAAC,EAAE,WAAW,KAAK,OAAO,CAAC,CAAC,CAAC,CAAC;CAC5E;AAED;;;;;;GAMG;AACH,MAAM,MAAM,aAAa,GAAG,SAAS,GAAG,UAAU,GAAG,MAAM,GAAG,QAAQ,CAAC;AAEvE;;GAEG;AACH,MAAM,WAAW,cAAc,CAAC,KAAK,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC;IAC7D,mBAAmB;IACnB,QAAQ,CAAC,WAAW,EAAE,MAAM,CAAC;IAE7B;;;;;OAKG;IACH,KAAK,EAAE,CAAC,EAAE,EAAE,MAAM,EAAE,IAAI,CAAC,EAAE,KAAK,EAAE,OAAO,CAAC,EAAE,oBAAoB,KAAK,OAAO,CAAC,YAAY,CAAC,CAAC;IAE3F;;OAEG;IACH,SAAS,EAAE,CAAC,EAAE,EAAE,MAAM,KAAK,OAAO,CAAC;IAEnC;;;OAGG;IACH,QAAQ,EAAE,CAAC,GAAG,EAAE,GAAG,KAAK,cAAc,GAAG,IAAI,CAAC;IAC9C,YAAY;IACZ,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IAEtB,wBAAwB;IACxB,QAAQ,CAAC,QAAQ,CAAC,EAAE,MAAM,CAAC;IAE3B,qCAAqC;IACrC,QAAQ,CAAC,QAAQ,CAAC,EAAE,MAAM,CAAC;IAE3B,WAAW;IACX,QAAQ,CAAC,KAAK,CAAC,EAAE,aAAa,CAAC;CAChC;AAED;;GAEG;AACH,MAAM,MAAM,cAAc,GAAG,SAAS,cAAc,EAAE,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@haklex/rich-renderer-linkcard",
3
- "version": "0.6.2",
3
+ "version": "0.8.0",
4
4
  "description": "Rich link preview card renderer with extensible URL plugins",
5
5
  "repository": {
6
6
  "type": "git",
@@ -48,9 +48,9 @@
48
48
  "lucide-react": "^1.0.0",
49
49
  "react": ">=19",
50
50
  "react-dom": ">=19",
51
- "@haklex/rich-editor": "0.6.2",
52
- "@haklex/rich-editor-ui": "0.6.2",
53
- "@haklex/rich-style-token": "0.6.2"
51
+ "@haklex/rich-editor": "0.8.0",
52
+ "@haklex/rich-editor-ui": "0.8.0",
53
+ "@haklex/rich-style-token": "0.8.0"
54
54
  },
55
55
  "publishConfig": {
56
56
  "access": "public"