@tdacorp/hyle-sdk 0.24.1 → 0.26.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -2
- package/dist/{embed-BaLQbE_n.d.ts → brand-CwXvdSkk.d.ts} +14 -2
- package/dist/{embed-BrrGgkgQ.d.cts → brand-IuZSB9UX.d.cts} +14 -2
- package/dist/{chunk-RCK4NCYC.js → chunk-3UQGU62T.js} +12 -0
- package/dist/{chunk-O4QWHXVH.js → chunk-IDBQSMWT.js} +1 -1
- package/dist/{chunk-5TKJH2XC.js → chunk-NUQQ6VHH.js} +267 -43
- package/dist/{chunk-Y3BACEWA.js → chunk-T4EZAQFU.js} +129 -3
- package/dist/chunk-VAR2B7S6.js +82 -0
- package/dist/{chunk-U74B7AUG.js → chunk-ZWKAEWEW.js} +22 -74
- package/dist/{client-DN38IP63.d.ts → client-B2zi_BGq.d.ts} +1 -1
- package/dist/{client-CI-3cHtc.d.cts → client-DBZTvcCh.d.cts} +1 -1
- package/dist/comments.cjs +25 -1
- package/dist/comments.js +4 -2
- package/dist/html.cjs +129 -3
- package/dist/html.js +1 -1
- package/dist/index.cjs +12 -0
- package/dist/index.d.cts +4 -4
- package/dist/index.d.ts +4 -4
- package/dist/index.js +1 -1
- package/dist/next.cjs +593 -177
- package/dist/next.d.cts +27 -11
- package/dist/next.d.ts +27 -11
- package/dist/next.js +188 -124
- package/dist/react.cjs +401 -46
- package/dist/react.d.cts +114 -4
- package/dist/react.d.ts +114 -4
- package/dist/react.js +14 -4
- package/dist/reactions.cjs +25 -1
- package/dist/reactions.js +4 -2
- package/dist/{resolve-Ce_yz8gC.d.cts → resolve-0nGnsIHo.d.cts} +1 -1
- package/dist/{resolve-DMHbYyTS.d.ts → resolve-CguSaZLa.d.ts} +1 -1
- package/dist/{revalidation-callback-BQl77tQR.d.cts → revalidation-callback-FT9ik1dh.d.cts} +11 -0
- package/dist/{revalidation-callback-BQl77tQR.d.ts → revalidation-callback-FT9ik1dh.d.ts} +11 -0
- package/dist/share-client.cjs +498 -0
- package/dist/share-client.d.cts +99 -0
- package/dist/share-client.d.ts +99 -0
- package/dist/share-client.js +390 -0
- package/dist/styles.css +176 -1
- package/dist/{types-CxE8kLeo.d.cts → types-CdaIzSjg.d.cts} +2 -0
- package/dist/{types-CxE8kLeo.d.ts → types-CdaIzSjg.d.ts} +2 -0
- package/dist/use-cache.d.cts +3 -3
- package/dist/use-cache.d.ts +3 -3
- package/dist/use-cache.js +2 -2
- package/package.json +1 -1
|
@@ -685,7 +685,49 @@ var en = {
|
|
|
685
685
|
unTitle: "This page is temporarily unavailable",
|
|
686
686
|
unBody: "The content could not be loaded. Please try again in a moment.",
|
|
687
687
|
viewer: VIEWER_LABELS_EN,
|
|
688
|
-
comments: COMMENT_LABELS_EN
|
|
688
|
+
comments: COMMENT_LABELS_EN,
|
|
689
|
+
share: {
|
|
690
|
+
protectedTag: "Protected",
|
|
691
|
+
lock: "Lock",
|
|
692
|
+
lockTitle: "Lock this share and return to the password page",
|
|
693
|
+
searchLabel: "Search this share",
|
|
694
|
+
searchHint: "Finds words in the titles and descriptions of its documents. Nothing outside the share is searched.",
|
|
695
|
+
searchNone: "No documents match",
|
|
696
|
+
searchScope: "Search covers the titles and descriptions of this share's documents.",
|
|
697
|
+
searchCount: "{n} results",
|
|
698
|
+
searchOne: "1 result",
|
|
699
|
+
open: "Open",
|
|
700
|
+
close: "Close",
|
|
701
|
+
documents: "Documents",
|
|
702
|
+
documentCount: "{n} documents",
|
|
703
|
+
documentPosition: "Document {i} of {n}",
|
|
704
|
+
privateCopy: "Private copy. Never listed or indexed.",
|
|
705
|
+
noExpiry: "No expiry",
|
|
706
|
+
expires: "Expires {when}",
|
|
707
|
+
expiresSoon: "Expires soon",
|
|
708
|
+
expired: "Expired",
|
|
709
|
+
endedNotice: "This share has ended. You can finish this page, but the next one will not open.",
|
|
710
|
+
soonNotice: "This share expires within 24 hours.",
|
|
711
|
+
gateTitle: "Password required",
|
|
712
|
+
gateBody: "Enter the password you were given to open this page.",
|
|
713
|
+
gateWrong: "Wrong or expired password.",
|
|
714
|
+
gatePassword: "Password",
|
|
715
|
+
gateOpen: "Open",
|
|
716
|
+
locked: "Locked",
|
|
717
|
+
attemptsTitle: "Too many attempts",
|
|
718
|
+
attemptsBody: "Try again in {n} seconds.",
|
|
719
|
+
attemptsOne: "Try again in {n} second.",
|
|
720
|
+
unavailableTitle: "This page is not available",
|
|
721
|
+
unavailableBody: "The address may be wrong, or the share may have ended. Ask the person who sent it.",
|
|
722
|
+
theme: "Theme",
|
|
723
|
+
themeLight: "Light",
|
|
724
|
+
themeDark: "Dark",
|
|
725
|
+
themeSystem: "System",
|
|
726
|
+
showDocuments: "Show documents",
|
|
727
|
+
hideDocuments: "Hide documents",
|
|
728
|
+
closeDocuments: "Close documents",
|
|
729
|
+
skip: "Skip to content"
|
|
730
|
+
}
|
|
689
731
|
};
|
|
690
732
|
var fr = {
|
|
691
733
|
toc: "Sur cette page",
|
|
@@ -745,7 +787,49 @@ var fr = {
|
|
|
745
787
|
unTitle: "Cette page est momentan\xE9ment indisponible",
|
|
746
788
|
unBody: "Le contenu n'a pas pu \xEAtre charg\xE9. R\xE9essayez dans un instant.",
|
|
747
789
|
viewer: VIEWER_LABELS_FR,
|
|
748
|
-
comments: COMMENT_LABELS_FR
|
|
790
|
+
comments: COMMENT_LABELS_FR,
|
|
791
|
+
share: {
|
|
792
|
+
protectedTag: "Prot\xE9g\xE9",
|
|
793
|
+
lock: "Verrouiller",
|
|
794
|
+
lockTitle: "Verrouiller ce partage et revenir \xE0 la page du mot de passe",
|
|
795
|
+
searchLabel: "Rechercher dans ce partage",
|
|
796
|
+
searchHint: "Recherche des mots dans les titres et descriptions de ses documents. Rien hors du partage n'est recherch\xE9.",
|
|
797
|
+
searchNone: "Aucun document ne correspond",
|
|
798
|
+
searchScope: "La recherche porte sur les titres et descriptions des documents de ce partage.",
|
|
799
|
+
searchCount: "{n} r\xE9sultats",
|
|
800
|
+
searchOne: "1 r\xE9sultat",
|
|
801
|
+
open: "Ouvrir",
|
|
802
|
+
close: "Fermer",
|
|
803
|
+
documents: "Documents",
|
|
804
|
+
documentCount: "{n} documents",
|
|
805
|
+
documentPosition: "Document {i} sur {n}",
|
|
806
|
+
privateCopy: "Copie priv\xE9e. Jamais list\xE9e ni index\xE9e.",
|
|
807
|
+
noExpiry: "Sans expiration",
|
|
808
|
+
expires: "Expire le {when}",
|
|
809
|
+
expiresSoon: "Expire bient\xF4t",
|
|
810
|
+
expired: "Expir\xE9",
|
|
811
|
+
endedNotice: "Ce partage a pris fin. Vous pouvez terminer cette page, mais la suivante ne s'ouvrira pas.",
|
|
812
|
+
soonNotice: "Ce partage expire dans les 24 heures.",
|
|
813
|
+
gateTitle: "Mot de passe requis",
|
|
814
|
+
gateBody: "Saisissez le mot de passe qui vous a \xE9t\xE9 donn\xE9 pour ouvrir cette page.",
|
|
815
|
+
gateWrong: "Mot de passe incorrect ou expir\xE9.",
|
|
816
|
+
gatePassword: "Mot de passe",
|
|
817
|
+
gateOpen: "Ouvrir",
|
|
818
|
+
locked: "Verrouill\xE9",
|
|
819
|
+
attemptsTitle: "Trop de tentatives",
|
|
820
|
+
attemptsBody: "R\xE9essayez dans {n} secondes.",
|
|
821
|
+
attemptsOne: "R\xE9essayez dans {n} seconde.",
|
|
822
|
+
unavailableTitle: "Cette page n'est pas disponible",
|
|
823
|
+
unavailableBody: "L'adresse est peut-\xEAtre erron\xE9e, ou le partage a pris fin. Demandez \xE0 la personne qui vous l'a envoy\xE9.",
|
|
824
|
+
theme: "Th\xE8me",
|
|
825
|
+
themeLight: "Clair",
|
|
826
|
+
themeDark: "Sombre",
|
|
827
|
+
themeSystem: "Syst\xE8me",
|
|
828
|
+
showDocuments: "Afficher les documents",
|
|
829
|
+
hideDocuments: "Masquer les documents",
|
|
830
|
+
closeDocuments: "Fermer les documents",
|
|
831
|
+
skip: "Aller au contenu"
|
|
832
|
+
}
|
|
749
833
|
};
|
|
750
834
|
var es = {
|
|
751
835
|
toc: "En esta p\xE1gina",
|
|
@@ -805,7 +889,49 @@ var es = {
|
|
|
805
889
|
unTitle: "Esta p\xE1gina no est\xE1 disponible por el momento",
|
|
806
890
|
unBody: "No se pudo cargar el contenido. Int\xE9ntalo de nuevo en un momento.",
|
|
807
891
|
viewer: VIEWER_LABELS_ES,
|
|
808
|
-
comments: COMMENT_LABELS_ES
|
|
892
|
+
comments: COMMENT_LABELS_ES,
|
|
893
|
+
share: {
|
|
894
|
+
protectedTag: "Protegido",
|
|
895
|
+
lock: "Bloquear",
|
|
896
|
+
lockTitle: "Bloquear este enlace compartido y volver a la p\xE1gina de contrase\xF1a",
|
|
897
|
+
searchLabel: "Buscar en este enlace compartido",
|
|
898
|
+
searchHint: "Busca palabras en los t\xEDtulos y descripciones de sus documentos. No se busca nada fuera del enlace compartido.",
|
|
899
|
+
searchNone: "Ning\xFAn documento coincide",
|
|
900
|
+
searchScope: "La b\xFAsqueda abarca los t\xEDtulos y descripciones de los documentos de este enlace compartido.",
|
|
901
|
+
searchCount: "{n} resultados",
|
|
902
|
+
searchOne: "1 resultado",
|
|
903
|
+
open: "Abrir",
|
|
904
|
+
close: "Cerrar",
|
|
905
|
+
documents: "Documentos",
|
|
906
|
+
documentCount: "{n} documentos",
|
|
907
|
+
documentPosition: "Documento {i} de {n}",
|
|
908
|
+
privateCopy: "Copia privada. Nunca se lista ni se indexa.",
|
|
909
|
+
noExpiry: "Sin caducidad",
|
|
910
|
+
expires: "Caduca el {when}",
|
|
911
|
+
expiresSoon: "Caduca pronto",
|
|
912
|
+
expired: "Caducado",
|
|
913
|
+
endedNotice: "Este enlace compartido ha terminado. Puedes terminar esta p\xE1gina, pero la siguiente no se abrir\xE1.",
|
|
914
|
+
soonNotice: "Este enlace compartido caduca en menos de 24 horas.",
|
|
915
|
+
gateTitle: "Se requiere contrase\xF1a",
|
|
916
|
+
gateBody: "Escribe la contrase\xF1a que te han dado para abrir esta p\xE1gina.",
|
|
917
|
+
gateWrong: "Contrase\xF1a incorrecta o caducada.",
|
|
918
|
+
gatePassword: "Contrase\xF1a",
|
|
919
|
+
gateOpen: "Abrir",
|
|
920
|
+
locked: "Bloqueado",
|
|
921
|
+
attemptsTitle: "Demasiados intentos",
|
|
922
|
+
attemptsBody: "Vuelve a intentarlo en {n} segundos.",
|
|
923
|
+
attemptsOne: "Vuelve a intentarlo en {n} segundo.",
|
|
924
|
+
unavailableTitle: "Esta p\xE1gina no est\xE1 disponible",
|
|
925
|
+
unavailableBody: "La direcci\xF3n puede estar mal, o el enlace compartido ha terminado. Pregunta a quien te lo envi\xF3.",
|
|
926
|
+
theme: "Tema",
|
|
927
|
+
themeLight: "Claro",
|
|
928
|
+
themeDark: "Oscuro",
|
|
929
|
+
themeSystem: "Sistema",
|
|
930
|
+
showDocuments: "Mostrar los documentos",
|
|
931
|
+
hideDocuments: "Ocultar los documentos",
|
|
932
|
+
closeDocuments: "Cerrar los documentos",
|
|
933
|
+
skip: "Ir al contenido"
|
|
934
|
+
}
|
|
809
935
|
};
|
|
810
936
|
var TABLE = { en, fr, es };
|
|
811
937
|
function stringsFor(locale) {
|
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
// src/react/icons.tsx
|
|
2
|
+
import { Fragment, jsx, jsxs } from "react/jsx-runtime";
|
|
3
|
+
var SHAPES = {
|
|
4
|
+
info: /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
5
|
+
/* @__PURE__ */ jsx("circle", { cx: "8", cy: "8", r: "6" }),
|
|
6
|
+
/* @__PURE__ */ jsx("path", { d: "M8 7.3V11M8 5v.1" })
|
|
7
|
+
] }),
|
|
8
|
+
"check-circle": /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
9
|
+
/* @__PURE__ */ jsx("circle", { cx: "8", cy: "8", r: "6" }),
|
|
10
|
+
/* @__PURE__ */ jsx("path", { d: "m5.3 8.3 1.9 1.9 3.5-3.9" })
|
|
11
|
+
] }),
|
|
12
|
+
alert: /* @__PURE__ */ jsx("path", { d: "M8 2 1.8 13h12.4zM8 6.5v3M8 11.3v.1" }),
|
|
13
|
+
"x-circle": /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
14
|
+
/* @__PURE__ */ jsx("circle", { cx: "8", cy: "8", r: "6" }),
|
|
15
|
+
/* @__PURE__ */ jsx("path", { d: "m5.8 5.8 4.4 4.4M10.2 5.8l-4.4 4.4" })
|
|
16
|
+
] }),
|
|
17
|
+
calendar: /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
18
|
+
/* @__PURE__ */ jsx("rect", { x: "2", y: "3", width: "12", height: "11", rx: "1.3" }),
|
|
19
|
+
/* @__PURE__ */ jsx("path", { d: "M2 6.5h12M5.5 1.7v2.6M10.5 1.7v2.6" })
|
|
20
|
+
] }),
|
|
21
|
+
globe: /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
22
|
+
/* @__PURE__ */ jsx("circle", { cx: "8", cy: "8", r: "6" }),
|
|
23
|
+
/* @__PURE__ */ jsx("path", { d: "M2 8h12M8 2c2 1.7 2.8 3.7 2.8 6S10 12.3 8 14M8 2C6 3.7 5.2 5.7 5.2 8S6 12.3 8 14" })
|
|
24
|
+
] }),
|
|
25
|
+
file: /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
26
|
+
/* @__PURE__ */ jsx("path", { d: "M4 1.8h5l3 3v8.4a1 1 0 0 1-1 1H4a1 1 0 0 1-1-1V2.8a1 1 0 0 1 1-1z" }),
|
|
27
|
+
/* @__PURE__ */ jsx("path", { d: "M9 1.8v3h3" })
|
|
28
|
+
] }),
|
|
29
|
+
chev: /* @__PURE__ */ jsx("path", { d: "m6 3.5 4.5 4.5L6 12.5" }),
|
|
30
|
+
"chev-up": /* @__PURE__ */ jsx("path", { d: "m3.5 10 4.5-4.5L12.5 10" }),
|
|
31
|
+
"chev-down": /* @__PURE__ */ jsx("path", { d: "m3.5 6 4.5 4.5L12.5 6" }),
|
|
32
|
+
"chev-left": /* @__PURE__ */ jsx("path", { d: "M10 3.5 5.5 8 10 12.5" }),
|
|
33
|
+
x: /* @__PURE__ */ jsx("path", { d: "m4 4 8 8M12 4l-8 8" }),
|
|
34
|
+
important: /* @__PURE__ */ jsx("path", { d: "M3 2.5h10a1 1 0 0 1 1 1v7a1 1 0 0 1-1 1H8l-3.5 2.8v-2.8H3a1 1 0 0 1-1-1v-7a1 1 0 0 1 1-1zM8 5v2.8M8 9.5v.1" }),
|
|
35
|
+
copy: /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
36
|
+
/* @__PURE__ */ jsx("rect", { x: "5.5", y: "5.5", width: "8", height: "8", rx: "1.3" }),
|
|
37
|
+
/* @__PURE__ */ jsx("path", { d: "M10.5 5.5v-2a1 1 0 0 0-1-1h-6a1 1 0 0 0-1 1v6a1 1 0 0 0 1 1h2" })
|
|
38
|
+
] }),
|
|
39
|
+
check: /* @__PURE__ */ jsx("path", { d: "m3 8.5 3.2 3L13 4.5" }),
|
|
40
|
+
heart: /* @__PURE__ */ jsx("path", { d: "M8 13.5S2.2 10 2.2 6.1A3 3 0 0 1 8 5a3 3 0 0 1 5.8 1.1C13.8 10 8 13.5 8 13.5z" }),
|
|
41
|
+
reply: /* @__PURE__ */ jsx("path", { d: "M6.5 3.5 2.5 7.5l4 4M2.5 7.5h6a5 5 0 0 1 5 5" }),
|
|
42
|
+
clock: /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
43
|
+
/* @__PURE__ */ jsx("circle", { cx: "8", cy: "8", r: "6" }),
|
|
44
|
+
/* @__PURE__ */ jsx("path", { d: "M8 4.5V8l2.3 1.5" })
|
|
45
|
+
] }),
|
|
46
|
+
ban: /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
47
|
+
/* @__PURE__ */ jsx("circle", { cx: "8", cy: "8", r: "6" }),
|
|
48
|
+
/* @__PURE__ */ jsx("path", { d: "m3.8 12.2 8.4-8.4" })
|
|
49
|
+
] }),
|
|
50
|
+
refresh: /* @__PURE__ */ jsx("path", { d: "M13 8a5 5 0 1 1-1.6-3.7M13 2.5v2.8h-2.8" }),
|
|
51
|
+
lock: /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
52
|
+
/* @__PURE__ */ jsx("rect", { x: "3", y: "7", width: "10", height: "7", rx: "1.3" }),
|
|
53
|
+
/* @__PURE__ */ jsx("path", { d: "M5.2 7V5a2.8 2.8 0 0 1 5.6 0v2" })
|
|
54
|
+
] }),
|
|
55
|
+
search: /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
56
|
+
/* @__PURE__ */ jsx("circle", { cx: "7", cy: "7", r: "4.5" }),
|
|
57
|
+
/* @__PURE__ */ jsx("path", { d: "m10.5 10.5 3.5 3.5" })
|
|
58
|
+
] }),
|
|
59
|
+
sun: /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
60
|
+
/* @__PURE__ */ jsx("circle", { cx: "8", cy: "8", r: "2.8" }),
|
|
61
|
+
/* @__PURE__ */ jsx("path", { d: "M8 1.5v1.8M8 12.7v1.8M1.5 8h1.8M12.7 8h1.8M3.4 3.4l1.3 1.3M11.3 11.3l1.3 1.3M3.4 12.6l1.3-1.3M11.3 4.7l1.3-1.3" })
|
|
62
|
+
] }),
|
|
63
|
+
moon: /* @__PURE__ */ jsx("path", { d: "M13 9.4A5.6 5.6 0 0 1 6.6 3a5.6 5.6 0 1 0 6.4 6.4z" }),
|
|
64
|
+
monitor: /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
65
|
+
/* @__PURE__ */ jsx("rect", { x: "2", y: "3", width: "12", height: "8", rx: "1.3" }),
|
|
66
|
+
/* @__PURE__ */ jsx("path", { d: "M6 14h4M8 11v3" })
|
|
67
|
+
] }),
|
|
68
|
+
sidebar: /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
69
|
+
/* @__PURE__ */ jsx("rect", { x: "2", y: "3", width: "12", height: "10", rx: "1.3" }),
|
|
70
|
+
/* @__PURE__ */ jsx("path", { d: "M6.5 3v10" })
|
|
71
|
+
] }),
|
|
72
|
+
shield: /* @__PURE__ */ jsx("path", { d: "M8 1.5 2.5 3.6v4c0 3.2 2.3 5.4 5.5 6.9 3.2-1.5 5.5-3.7 5.5-6.9v-4z" }),
|
|
73
|
+
"arrow-left": /* @__PURE__ */ jsx("path", { d: "M13 8H3M7 4 3 8l4 4" }),
|
|
74
|
+
menu: /* @__PURE__ */ jsx("path", { d: "M2.5 4.5h11M2.5 8h11M2.5 11.5h11" })
|
|
75
|
+
};
|
|
76
|
+
function Icon({ name, className }) {
|
|
77
|
+
return /* @__PURE__ */ jsx("svg", { className: className ? `hyle-ic ${className}` : "hyle-ic", viewBox: "0 0 16 16", "aria-hidden": "true", children: SHAPES[name] });
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
export {
|
|
81
|
+
Icon
|
|
82
|
+
};
|
|
@@ -1,3 +1,7 @@
|
|
|
1
|
+
import {
|
|
2
|
+
Icon
|
|
3
|
+
} from "./chunk-VAR2B7S6.js";
|
|
4
|
+
|
|
1
5
|
// src/react/comments-api.ts
|
|
2
6
|
var CSRF_HEADER = "x-hyle-engage";
|
|
3
7
|
var TIMEOUT_MS = 15e3;
|
|
@@ -234,64 +238,9 @@ function newestFirst(thread) {
|
|
|
234
238
|
return [...thread.filter((n) => n.status === "held"), ...thread.filter((n) => n.status !== "held").reverse()];
|
|
235
239
|
}
|
|
236
240
|
|
|
237
|
-
// src/react/icons.tsx
|
|
238
|
-
import { Fragment, jsx, jsxs } from "react/jsx-runtime";
|
|
239
|
-
var SHAPES = {
|
|
240
|
-
info: /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
241
|
-
/* @__PURE__ */ jsx("circle", { cx: "8", cy: "8", r: "6" }),
|
|
242
|
-
/* @__PURE__ */ jsx("path", { d: "M8 7.3V11M8 5v.1" })
|
|
243
|
-
] }),
|
|
244
|
-
"check-circle": /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
245
|
-
/* @__PURE__ */ jsx("circle", { cx: "8", cy: "8", r: "6" }),
|
|
246
|
-
/* @__PURE__ */ jsx("path", { d: "m5.3 8.3 1.9 1.9 3.5-3.9" })
|
|
247
|
-
] }),
|
|
248
|
-
alert: /* @__PURE__ */ jsx("path", { d: "M8 2 1.8 13h12.4zM8 6.5v3M8 11.3v.1" }),
|
|
249
|
-
"x-circle": /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
250
|
-
/* @__PURE__ */ jsx("circle", { cx: "8", cy: "8", r: "6" }),
|
|
251
|
-
/* @__PURE__ */ jsx("path", { d: "m5.8 5.8 4.4 4.4M10.2 5.8l-4.4 4.4" })
|
|
252
|
-
] }),
|
|
253
|
-
calendar: /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
254
|
-
/* @__PURE__ */ jsx("rect", { x: "2", y: "3", width: "12", height: "11", rx: "1.3" }),
|
|
255
|
-
/* @__PURE__ */ jsx("path", { d: "M2 6.5h12M5.5 1.7v2.6M10.5 1.7v2.6" })
|
|
256
|
-
] }),
|
|
257
|
-
globe: /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
258
|
-
/* @__PURE__ */ jsx("circle", { cx: "8", cy: "8", r: "6" }),
|
|
259
|
-
/* @__PURE__ */ jsx("path", { d: "M2 8h12M8 2c2 1.7 2.8 3.7 2.8 6S10 12.3 8 14M8 2C6 3.7 5.2 5.7 5.2 8S6 12.3 8 14" })
|
|
260
|
-
] }),
|
|
261
|
-
file: /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
262
|
-
/* @__PURE__ */ jsx("path", { d: "M4 1.8h5l3 3v8.4a1 1 0 0 1-1 1H4a1 1 0 0 1-1-1V2.8a1 1 0 0 1 1-1z" }),
|
|
263
|
-
/* @__PURE__ */ jsx("path", { d: "M9 1.8v3h3" })
|
|
264
|
-
] }),
|
|
265
|
-
chev: /* @__PURE__ */ jsx("path", { d: "m6 3.5 4.5 4.5L6 12.5" }),
|
|
266
|
-
"chev-up": /* @__PURE__ */ jsx("path", { d: "m3.5 10 4.5-4.5L12.5 10" }),
|
|
267
|
-
"chev-down": /* @__PURE__ */ jsx("path", { d: "m3.5 6 4.5 4.5L12.5 6" }),
|
|
268
|
-
"chev-left": /* @__PURE__ */ jsx("path", { d: "M10 3.5 5.5 8 10 12.5" }),
|
|
269
|
-
x: /* @__PURE__ */ jsx("path", { d: "m4 4 8 8M12 4l-8 8" }),
|
|
270
|
-
important: /* @__PURE__ */ jsx("path", { d: "M3 2.5h10a1 1 0 0 1 1 1v7a1 1 0 0 1-1 1H8l-3.5 2.8v-2.8H3a1 1 0 0 1-1-1v-7a1 1 0 0 1 1-1zM8 5v2.8M8 9.5v.1" }),
|
|
271
|
-
copy: /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
272
|
-
/* @__PURE__ */ jsx("rect", { x: "5.5", y: "5.5", width: "8", height: "8", rx: "1.3" }),
|
|
273
|
-
/* @__PURE__ */ jsx("path", { d: "M10.5 5.5v-2a1 1 0 0 0-1-1h-6a1 1 0 0 0-1 1v6a1 1 0 0 0 1 1h2" })
|
|
274
|
-
] }),
|
|
275
|
-
check: /* @__PURE__ */ jsx("path", { d: "m3 8.5 3.2 3L13 4.5" }),
|
|
276
|
-
heart: /* @__PURE__ */ jsx("path", { d: "M8 13.5S2.2 10 2.2 6.1A3 3 0 0 1 8 5a3 3 0 0 1 5.8 1.1C13.8 10 8 13.5 8 13.5z" }),
|
|
277
|
-
reply: /* @__PURE__ */ jsx("path", { d: "M6.5 3.5 2.5 7.5l4 4M2.5 7.5h6a5 5 0 0 1 5 5" }),
|
|
278
|
-
clock: /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
279
|
-
/* @__PURE__ */ jsx("circle", { cx: "8", cy: "8", r: "6" }),
|
|
280
|
-
/* @__PURE__ */ jsx("path", { d: "M8 4.5V8l2.3 1.5" })
|
|
281
|
-
] }),
|
|
282
|
-
ban: /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
283
|
-
/* @__PURE__ */ jsx("circle", { cx: "8", cy: "8", r: "6" }),
|
|
284
|
-
/* @__PURE__ */ jsx("path", { d: "m3.8 12.2 8.4-8.4" })
|
|
285
|
-
] }),
|
|
286
|
-
refresh: /* @__PURE__ */ jsx("path", { d: "M13 8a5 5 0 1 1-1.6-3.7M13 2.5v2.8h-2.8" })
|
|
287
|
-
};
|
|
288
|
-
function Icon({ name, className }) {
|
|
289
|
-
return /* @__PURE__ */ jsx("svg", { className: className ? `hyle-ic ${className}` : "hyle-ic", viewBox: "0 0 16 16", "aria-hidden": "true", children: SHAPES[name] });
|
|
290
|
-
}
|
|
291
|
-
|
|
292
241
|
// src/react/reaction-bar.tsx
|
|
293
242
|
import { useEffect, useRef, useState } from "react";
|
|
294
|
-
import { Fragment
|
|
243
|
+
import { Fragment, jsx, jsxs } from "react/jsx-runtime";
|
|
295
244
|
var reactionKey = (subject, kind) => `${subject}:${kind}`;
|
|
296
245
|
var kindName = (s, kind) => ({ like: s.reactionLike, love: s.reactionLove, insightful: s.reactionInsightful, celebrate: s.reactionCelebrate })[kind];
|
|
297
246
|
function settleReactions(overlay, pending, listing) {
|
|
@@ -344,40 +293,40 @@ function ReactionBar({ s, scope, subject, likes, counts, likedByMe, mine, overla
|
|
|
344
293
|
const on = state?.on ?? serverOn;
|
|
345
294
|
if (kind !== "like" && !open && !state && count2 === 0) return null;
|
|
346
295
|
const out = access === "out";
|
|
347
|
-
const content = kind !== "like" ? /* @__PURE__ */
|
|
348
|
-
out ? /* @__PURE__ */
|
|
296
|
+
const content = kind !== "like" ? /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
297
|
+
out ? /* @__PURE__ */ jsx("span", { className: "hyle-sr", children: s.reactionSignIn }) : null,
|
|
349
298
|
kindName(s, kind),
|
|
350
299
|
" ",
|
|
351
|
-
/* @__PURE__ */
|
|
352
|
-
] }) : scope === "article" ? /* @__PURE__ */
|
|
353
|
-
/* @__PURE__ */
|
|
300
|
+
/* @__PURE__ */ jsx("span", { children: count2 })
|
|
301
|
+
] }) : scope === "article" ? /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
302
|
+
/* @__PURE__ */ jsx(Icon, { name: "heart" }),
|
|
354
303
|
out ? s.likeArticle : on ? s.likedArticle : s.likeArticle,
|
|
355
304
|
" ",
|
|
356
|
-
/* @__PURE__ */
|
|
357
|
-
/* @__PURE__ */
|
|
358
|
-
] }) : /* @__PURE__ */
|
|
359
|
-
/* @__PURE__ */
|
|
360
|
-
/* @__PURE__ */
|
|
361
|
-
/* @__PURE__ */
|
|
305
|
+
/* @__PURE__ */ jsx("span", { className: "hyle-sr", children: out ? s.likeArticleSignIn : ", " }),
|
|
306
|
+
/* @__PURE__ */ jsx("span", { children: count2 })
|
|
307
|
+
] }) : /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
308
|
+
/* @__PURE__ */ jsx(Icon, { name: "heart" }),
|
|
309
|
+
/* @__PURE__ */ jsx("span", { className: "hyle-sr", children: out ? s.likeCommentSignIn : s.likeComment }),
|
|
310
|
+
/* @__PURE__ */ jsx("span", { children: count2 })
|
|
362
311
|
] });
|
|
363
312
|
const cls = kind === "like" ? base : `${base} chip`;
|
|
364
|
-
if (out && signInHref) return /* @__PURE__ */
|
|
365
|
-
if (access !== "in") return /* @__PURE__ */
|
|
366
|
-
return /* @__PURE__ */
|
|
313
|
+
if (out && signInHref) return /* @__PURE__ */ jsx("a", { className: cls, href: signInHref, children: content }, kind);
|
|
314
|
+
if (access !== "in") return /* @__PURE__ */ jsx("button", { className: cls, type: "button", "aria-disabled": "true", children: content }, kind);
|
|
315
|
+
return /* @__PURE__ */ jsx("button", { ref: kind === "love" ? first : void 0, className: cls, type: "button", "aria-pressed": on, onClick: () => {
|
|
367
316
|
setOpen(false);
|
|
368
317
|
onToggle(kind, server, serverOn);
|
|
369
318
|
}, children: content }, kind);
|
|
370
319
|
}
|
|
371
|
-
if (!counts) return /* @__PURE__ */
|
|
320
|
+
if (!counts) return /* @__PURE__ */ jsx(Fragment, { children: button("like") });
|
|
372
321
|
const onKey = (e) => {
|
|
373
322
|
if (e.key !== "Escape" || !open) return;
|
|
374
323
|
e.preventDefault();
|
|
375
324
|
setOpen(false);
|
|
376
325
|
trigger.current?.focus();
|
|
377
326
|
};
|
|
378
|
-
return /* @__PURE__ */
|
|
327
|
+
return /* @__PURE__ */ jsxs("span", { className: "hyle-reaction-set", role: "group", "aria-label": s.reactions, onKeyDown: onKey, children: [
|
|
379
328
|
REACTION_KINDS.map(button),
|
|
380
|
-
access === "in" ? /* @__PURE__ */
|
|
329
|
+
access === "in" ? /* @__PURE__ */ jsx("button", { ref: trigger, className: scope === "article" ? "hyle-btn" : "hyle-cm-btn", type: "button", "aria-expanded": open, onClick: () => setOpen((v) => !v), children: s.react }) : null
|
|
381
330
|
] });
|
|
382
331
|
}
|
|
383
332
|
|
|
@@ -391,7 +340,6 @@ export {
|
|
|
391
340
|
arrivesAs,
|
|
392
341
|
arrangeThread,
|
|
393
342
|
stillUnseen,
|
|
394
|
-
Icon,
|
|
395
343
|
kindName,
|
|
396
344
|
useReactions,
|
|
397
345
|
ReactionBar
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { m as Resolved, i as MountsResult, H as HylePreview, e as HyleProtectedGate, d as HyleProtected } from './types-
|
|
1
|
+
import { m as Resolved, i as MountsResult, H as HylePreview, e as HyleProtectedGate, d as HyleProtected } from './types-CdaIzSjg.js';
|
|
2
2
|
|
|
3
3
|
/** docs/cp1-spec.md section 5.3.3: `hyle.push/1`, the whole-post delivery of a path in push mode (ADR 0025). */
|
|
4
4
|
declare const MAX_PUSH_BODY_BYTES: number;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { m as Resolved, i as MountsResult, H as HylePreview, e as HyleProtectedGate, d as HyleProtected } from './types-
|
|
1
|
+
import { m as Resolved, i as MountsResult, H as HylePreview, e as HyleProtectedGate, d as HyleProtected } from './types-CdaIzSjg.cjs';
|
|
2
2
|
|
|
3
3
|
/** docs/cp1-spec.md section 5.3.3: `hyle.push/1`, the whole-post delivery of a path in push mode (ADR 0025). */
|
|
4
4
|
declare const MAX_PUSH_BODY_BYTES: number;
|
package/dist/comments.cjs
CHANGED
|
@@ -720,7 +720,31 @@ var SHAPES = {
|
|
|
720
720
|
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)("circle", { cx: "8", cy: "8", r: "6" }),
|
|
721
721
|
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)("path", { d: "m3.8 12.2 8.4-8.4" })
|
|
722
722
|
] }),
|
|
723
|
-
refresh: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("path", { d: "M13 8a5 5 0 1 1-1.6-3.7M13 2.5v2.8h-2.8" })
|
|
723
|
+
refresh: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("path", { d: "M13 8a5 5 0 1 1-1.6-3.7M13 2.5v2.8h-2.8" }),
|
|
724
|
+
lock: /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(import_jsx_runtime3.Fragment, { children: [
|
|
725
|
+
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)("rect", { x: "3", y: "7", width: "10", height: "7", rx: "1.3" }),
|
|
726
|
+
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)("path", { d: "M5.2 7V5a2.8 2.8 0 0 1 5.6 0v2" })
|
|
727
|
+
] }),
|
|
728
|
+
search: /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(import_jsx_runtime3.Fragment, { children: [
|
|
729
|
+
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)("circle", { cx: "7", cy: "7", r: "4.5" }),
|
|
730
|
+
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)("path", { d: "m10.5 10.5 3.5 3.5" })
|
|
731
|
+
] }),
|
|
732
|
+
sun: /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(import_jsx_runtime3.Fragment, { children: [
|
|
733
|
+
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)("circle", { cx: "8", cy: "8", r: "2.8" }),
|
|
734
|
+
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)("path", { d: "M8 1.5v1.8M8 12.7v1.8M1.5 8h1.8M12.7 8h1.8M3.4 3.4l1.3 1.3M11.3 11.3l1.3 1.3M3.4 12.6l1.3-1.3M11.3 4.7l1.3-1.3" })
|
|
735
|
+
] }),
|
|
736
|
+
moon: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("path", { d: "M13 9.4A5.6 5.6 0 0 1 6.6 3a5.6 5.6 0 1 0 6.4 6.4z" }),
|
|
737
|
+
monitor: /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(import_jsx_runtime3.Fragment, { children: [
|
|
738
|
+
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)("rect", { x: "2", y: "3", width: "12", height: "8", rx: "1.3" }),
|
|
739
|
+
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)("path", { d: "M6 14h4M8 11v3" })
|
|
740
|
+
] }),
|
|
741
|
+
sidebar: /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(import_jsx_runtime3.Fragment, { children: [
|
|
742
|
+
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)("rect", { x: "2", y: "3", width: "12", height: "10", rx: "1.3" }),
|
|
743
|
+
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)("path", { d: "M6.5 3v10" })
|
|
744
|
+
] }),
|
|
745
|
+
shield: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("path", { d: "M8 1.5 2.5 3.6v4c0 3.2 2.3 5.4 5.5 6.9 3.2-1.5 5.5-3.7 5.5-6.9v-4z" }),
|
|
746
|
+
"arrow-left": /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("path", { d: "M13 8H3M7 4 3 8l4 4" }),
|
|
747
|
+
menu: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("path", { d: "M2.5 4.5h11M2.5 8h11M2.5 11.5h11" })
|
|
724
748
|
};
|
|
725
749
|
function Icon({ name, className }) {
|
|
726
750
|
return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("svg", { className: className ? `hyle-ic ${className}` : "hyle-ic", viewBox: "0 0 16 16", "aria-hidden": "true", children: SHAPES[name] });
|
package/dist/comments.js
CHANGED
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import {
|
|
3
|
-
Icon,
|
|
4
3
|
ReactionBar,
|
|
5
4
|
arrangeThread,
|
|
6
5
|
arrivesAs,
|
|
@@ -13,7 +12,10 @@ import {
|
|
|
13
12
|
nextVote,
|
|
14
13
|
stillUnseen,
|
|
15
14
|
useReactions
|
|
16
|
-
} from "./chunk-
|
|
15
|
+
} from "./chunk-ZWKAEWEW.js";
|
|
16
|
+
import {
|
|
17
|
+
Icon
|
|
18
|
+
} from "./chunk-VAR2B7S6.js";
|
|
17
19
|
|
|
18
20
|
// src/react/comments.tsx
|
|
19
21
|
import { useEffect as useEffect3, useId, useRef as useRef4, useState as useState4 } from "react";
|
package/dist/html.cjs
CHANGED
|
@@ -724,7 +724,49 @@ var en = {
|
|
|
724
724
|
unTitle: "This page is temporarily unavailable",
|
|
725
725
|
unBody: "The content could not be loaded. Please try again in a moment.",
|
|
726
726
|
viewer: VIEWER_LABELS_EN,
|
|
727
|
-
comments: COMMENT_LABELS_EN
|
|
727
|
+
comments: COMMENT_LABELS_EN,
|
|
728
|
+
share: {
|
|
729
|
+
protectedTag: "Protected",
|
|
730
|
+
lock: "Lock",
|
|
731
|
+
lockTitle: "Lock this share and return to the password page",
|
|
732
|
+
searchLabel: "Search this share",
|
|
733
|
+
searchHint: "Finds words in the titles and descriptions of its documents. Nothing outside the share is searched.",
|
|
734
|
+
searchNone: "No documents match",
|
|
735
|
+
searchScope: "Search covers the titles and descriptions of this share's documents.",
|
|
736
|
+
searchCount: "{n} results",
|
|
737
|
+
searchOne: "1 result",
|
|
738
|
+
open: "Open",
|
|
739
|
+
close: "Close",
|
|
740
|
+
documents: "Documents",
|
|
741
|
+
documentCount: "{n} documents",
|
|
742
|
+
documentPosition: "Document {i} of {n}",
|
|
743
|
+
privateCopy: "Private copy. Never listed or indexed.",
|
|
744
|
+
noExpiry: "No expiry",
|
|
745
|
+
expires: "Expires {when}",
|
|
746
|
+
expiresSoon: "Expires soon",
|
|
747
|
+
expired: "Expired",
|
|
748
|
+
endedNotice: "This share has ended. You can finish this page, but the next one will not open.",
|
|
749
|
+
soonNotice: "This share expires within 24 hours.",
|
|
750
|
+
gateTitle: "Password required",
|
|
751
|
+
gateBody: "Enter the password you were given to open this page.",
|
|
752
|
+
gateWrong: "Wrong or expired password.",
|
|
753
|
+
gatePassword: "Password",
|
|
754
|
+
gateOpen: "Open",
|
|
755
|
+
locked: "Locked",
|
|
756
|
+
attemptsTitle: "Too many attempts",
|
|
757
|
+
attemptsBody: "Try again in {n} seconds.",
|
|
758
|
+
attemptsOne: "Try again in {n} second.",
|
|
759
|
+
unavailableTitle: "This page is not available",
|
|
760
|
+
unavailableBody: "The address may be wrong, or the share may have ended. Ask the person who sent it.",
|
|
761
|
+
theme: "Theme",
|
|
762
|
+
themeLight: "Light",
|
|
763
|
+
themeDark: "Dark",
|
|
764
|
+
themeSystem: "System",
|
|
765
|
+
showDocuments: "Show documents",
|
|
766
|
+
hideDocuments: "Hide documents",
|
|
767
|
+
closeDocuments: "Close documents",
|
|
768
|
+
skip: "Skip to content"
|
|
769
|
+
}
|
|
728
770
|
};
|
|
729
771
|
var fr = {
|
|
730
772
|
toc: "Sur cette page",
|
|
@@ -784,7 +826,49 @@ var fr = {
|
|
|
784
826
|
unTitle: "Cette page est momentan\xE9ment indisponible",
|
|
785
827
|
unBody: "Le contenu n'a pas pu \xEAtre charg\xE9. R\xE9essayez dans un instant.",
|
|
786
828
|
viewer: VIEWER_LABELS_FR,
|
|
787
|
-
comments: COMMENT_LABELS_FR
|
|
829
|
+
comments: COMMENT_LABELS_FR,
|
|
830
|
+
share: {
|
|
831
|
+
protectedTag: "Prot\xE9g\xE9",
|
|
832
|
+
lock: "Verrouiller",
|
|
833
|
+
lockTitle: "Verrouiller ce partage et revenir \xE0 la page du mot de passe",
|
|
834
|
+
searchLabel: "Rechercher dans ce partage",
|
|
835
|
+
searchHint: "Recherche des mots dans les titres et descriptions de ses documents. Rien hors du partage n'est recherch\xE9.",
|
|
836
|
+
searchNone: "Aucun document ne correspond",
|
|
837
|
+
searchScope: "La recherche porte sur les titres et descriptions des documents de ce partage.",
|
|
838
|
+
searchCount: "{n} r\xE9sultats",
|
|
839
|
+
searchOne: "1 r\xE9sultat",
|
|
840
|
+
open: "Ouvrir",
|
|
841
|
+
close: "Fermer",
|
|
842
|
+
documents: "Documents",
|
|
843
|
+
documentCount: "{n} documents",
|
|
844
|
+
documentPosition: "Document {i} sur {n}",
|
|
845
|
+
privateCopy: "Copie priv\xE9e. Jamais list\xE9e ni index\xE9e.",
|
|
846
|
+
noExpiry: "Sans expiration",
|
|
847
|
+
expires: "Expire le {when}",
|
|
848
|
+
expiresSoon: "Expire bient\xF4t",
|
|
849
|
+
expired: "Expir\xE9",
|
|
850
|
+
endedNotice: "Ce partage a pris fin. Vous pouvez terminer cette page, mais la suivante ne s'ouvrira pas.",
|
|
851
|
+
soonNotice: "Ce partage expire dans les 24 heures.",
|
|
852
|
+
gateTitle: "Mot de passe requis",
|
|
853
|
+
gateBody: "Saisissez le mot de passe qui vous a \xE9t\xE9 donn\xE9 pour ouvrir cette page.",
|
|
854
|
+
gateWrong: "Mot de passe incorrect ou expir\xE9.",
|
|
855
|
+
gatePassword: "Mot de passe",
|
|
856
|
+
gateOpen: "Ouvrir",
|
|
857
|
+
locked: "Verrouill\xE9",
|
|
858
|
+
attemptsTitle: "Trop de tentatives",
|
|
859
|
+
attemptsBody: "R\xE9essayez dans {n} secondes.",
|
|
860
|
+
attemptsOne: "R\xE9essayez dans {n} seconde.",
|
|
861
|
+
unavailableTitle: "Cette page n'est pas disponible",
|
|
862
|
+
unavailableBody: "L'adresse est peut-\xEAtre erron\xE9e, ou le partage a pris fin. Demandez \xE0 la personne qui vous l'a envoy\xE9.",
|
|
863
|
+
theme: "Th\xE8me",
|
|
864
|
+
themeLight: "Clair",
|
|
865
|
+
themeDark: "Sombre",
|
|
866
|
+
themeSystem: "Syst\xE8me",
|
|
867
|
+
showDocuments: "Afficher les documents",
|
|
868
|
+
hideDocuments: "Masquer les documents",
|
|
869
|
+
closeDocuments: "Fermer les documents",
|
|
870
|
+
skip: "Aller au contenu"
|
|
871
|
+
}
|
|
788
872
|
};
|
|
789
873
|
var es = {
|
|
790
874
|
toc: "En esta p\xE1gina",
|
|
@@ -844,7 +928,49 @@ var es = {
|
|
|
844
928
|
unTitle: "Esta p\xE1gina no est\xE1 disponible por el momento",
|
|
845
929
|
unBody: "No se pudo cargar el contenido. Int\xE9ntalo de nuevo en un momento.",
|
|
846
930
|
viewer: VIEWER_LABELS_ES,
|
|
847
|
-
comments: COMMENT_LABELS_ES
|
|
931
|
+
comments: COMMENT_LABELS_ES,
|
|
932
|
+
share: {
|
|
933
|
+
protectedTag: "Protegido",
|
|
934
|
+
lock: "Bloquear",
|
|
935
|
+
lockTitle: "Bloquear este enlace compartido y volver a la p\xE1gina de contrase\xF1a",
|
|
936
|
+
searchLabel: "Buscar en este enlace compartido",
|
|
937
|
+
searchHint: "Busca palabras en los t\xEDtulos y descripciones de sus documentos. No se busca nada fuera del enlace compartido.",
|
|
938
|
+
searchNone: "Ning\xFAn documento coincide",
|
|
939
|
+
searchScope: "La b\xFAsqueda abarca los t\xEDtulos y descripciones de los documentos de este enlace compartido.",
|
|
940
|
+
searchCount: "{n} resultados",
|
|
941
|
+
searchOne: "1 resultado",
|
|
942
|
+
open: "Abrir",
|
|
943
|
+
close: "Cerrar",
|
|
944
|
+
documents: "Documentos",
|
|
945
|
+
documentCount: "{n} documentos",
|
|
946
|
+
documentPosition: "Documento {i} de {n}",
|
|
947
|
+
privateCopy: "Copia privada. Nunca se lista ni se indexa.",
|
|
948
|
+
noExpiry: "Sin caducidad",
|
|
949
|
+
expires: "Caduca el {when}",
|
|
950
|
+
expiresSoon: "Caduca pronto",
|
|
951
|
+
expired: "Caducado",
|
|
952
|
+
endedNotice: "Este enlace compartido ha terminado. Puedes terminar esta p\xE1gina, pero la siguiente no se abrir\xE1.",
|
|
953
|
+
soonNotice: "Este enlace compartido caduca en menos de 24 horas.",
|
|
954
|
+
gateTitle: "Se requiere contrase\xF1a",
|
|
955
|
+
gateBody: "Escribe la contrase\xF1a que te han dado para abrir esta p\xE1gina.",
|
|
956
|
+
gateWrong: "Contrase\xF1a incorrecta o caducada.",
|
|
957
|
+
gatePassword: "Contrase\xF1a",
|
|
958
|
+
gateOpen: "Abrir",
|
|
959
|
+
locked: "Bloqueado",
|
|
960
|
+
attemptsTitle: "Demasiados intentos",
|
|
961
|
+
attemptsBody: "Vuelve a intentarlo en {n} segundos.",
|
|
962
|
+
attemptsOne: "Vuelve a intentarlo en {n} segundo.",
|
|
963
|
+
unavailableTitle: "Esta p\xE1gina no est\xE1 disponible",
|
|
964
|
+
unavailableBody: "La direcci\xF3n puede estar mal, o el enlace compartido ha terminado. Pregunta a quien te lo envi\xF3.",
|
|
965
|
+
theme: "Tema",
|
|
966
|
+
themeLight: "Claro",
|
|
967
|
+
themeDark: "Oscuro",
|
|
968
|
+
themeSystem: "Sistema",
|
|
969
|
+
showDocuments: "Mostrar los documentos",
|
|
970
|
+
hideDocuments: "Ocultar los documentos",
|
|
971
|
+
closeDocuments: "Cerrar los documentos",
|
|
972
|
+
skip: "Ir al contenido"
|
|
973
|
+
}
|
|
848
974
|
};
|
|
849
975
|
var TABLE = { en, fr, es };
|
|
850
976
|
function stringsFor(locale) {
|
package/dist/html.js
CHANGED
package/dist/index.cjs
CHANGED
|
@@ -431,6 +431,10 @@ async function runHook(hook, event) {
|
|
|
431
431
|
clearTimeout(timer);
|
|
432
432
|
}
|
|
433
433
|
}
|
|
434
|
+
function parseIndexUrls(value) {
|
|
435
|
+
if (!Array.isArray(value)) return [];
|
|
436
|
+
return value.flatMap((item) => isRecord(item) && isEventPath(item.path) && isText(item.locale) ? [{ path: item.path, locale: item.locale }] : []);
|
|
437
|
+
}
|
|
434
438
|
function createRevalidationCallbackRoute(options) {
|
|
435
439
|
const dedupe = new DeliveryDedupe(options.dedupeCapacity);
|
|
436
440
|
return {
|
|
@@ -483,6 +487,14 @@ function createRevalidationCallbackRoute(options) {
|
|
|
483
487
|
const hook = options.onCommentEvent;
|
|
484
488
|
const event = hook && parseCommentEvent(body);
|
|
485
489
|
if (hook && event) await runHook(hook, event);
|
|
490
|
+
const indexUrls = parseIndexUrls(body.index_urls);
|
|
491
|
+
if (options.onIndexUrls && indexUrls.length > 0) {
|
|
492
|
+
try {
|
|
493
|
+
options.onIndexUrls(indexUrls);
|
|
494
|
+
} catch {
|
|
495
|
+
console.error("hyle: onIndexUrls failed");
|
|
496
|
+
}
|
|
497
|
+
}
|
|
486
498
|
return okResponse(purged);
|
|
487
499
|
}
|
|
488
500
|
};
|