sanity-plugin-seofields 1.5.5 → 1.6.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.
Files changed (70) hide show
  1. package/README.md +4 -4
  2. package/dist/SeoHealthDashboard-7XMPVJRX.cjs +10 -0
  3. package/dist/{SeoHealthDashboard-KPBNXSL4.cjs.map → SeoHealthDashboard-7XMPVJRX.cjs.map} +1 -1
  4. package/dist/SeoHealthDashboard-UWPLB5DM.js +4 -0
  5. package/dist/{SeoHealthDashboard-QKVB5HK3.js.map → SeoHealthDashboard-UWPLB5DM.js.map} +1 -1
  6. package/dist/{SeoHealthTool-ON3SRXCF.cjs → SeoHealthTool-2H4XZR4I.cjs} +4 -4
  7. package/dist/{SeoHealthTool-ON3SRXCF.cjs.map → SeoHealthTool-2H4XZR4I.cjs.map} +1 -1
  8. package/dist/{SeoHealthTool-EPPOEDTW.js → SeoHealthTool-XCXINAQI.js} +3 -3
  9. package/dist/{SeoHealthTool-EPPOEDTW.js.map → SeoHealthTool-XCXINAQI.js.map} +1 -1
  10. package/dist/{SeoPreview-G3LPA7GV.js → SeoPreview-F6GGPZWI.js} +2 -2
  11. package/dist/SeoPreview-F6GGPZWI.js.map +1 -0
  12. package/dist/{SeoPreview-Y3CFDVBR.cjs → SeoPreview-JDROKZLP.cjs} +2 -2
  13. package/dist/SeoPreview-JDROKZLP.cjs.map +1 -0
  14. package/dist/chunk-6NIHHOVS.js +3918 -0
  15. package/dist/chunk-6NIHHOVS.js.map +1 -0
  16. package/dist/chunk-7HCP5O62.cjs +4027 -0
  17. package/dist/chunk-7HCP5O62.cjs.map +1 -0
  18. package/dist/{chunk-527WXITP.js → chunk-KWUITSHS.js} +218 -54
  19. package/dist/chunk-KWUITSHS.js.map +1 -0
  20. package/dist/{chunk-UCVSMPEJ.js → chunk-NHJBEV3A.js} +2 -2
  21. package/dist/{chunk-UCVSMPEJ.js.map → chunk-NHJBEV3A.js.map} +1 -1
  22. package/dist/chunk-WCLEWFAJ.cjs +669 -0
  23. package/dist/chunk-WCLEWFAJ.cjs.map +1 -0
  24. package/dist/{chunk-G2SVI2SP.cjs → chunk-Z74QPO75.cjs} +2 -2
  25. package/dist/{chunk-G2SVI2SP.cjs.map → chunk-Z74QPO75.cjs.map} +1 -1
  26. package/dist/cli.js +25 -25
  27. package/dist/component-7rqDvuy2.d.ts +534 -0
  28. package/dist/component-J2nEQkOw.d.cts +534 -0
  29. package/dist/index.cjs +21 -91
  30. package/dist/index.cjs.map +1 -1
  31. package/dist/index.d.cts +2 -49
  32. package/dist/index.d.ts +2 -49
  33. package/dist/index.js +21 -91
  34. package/dist/index.js.map +1 -1
  35. package/dist/next.cjs +155 -51
  36. package/dist/next.d.cts +3 -3
  37. package/dist/next.d.ts +3 -3
  38. package/dist/next.js +2 -2
  39. package/dist/schema/next.cjs +171 -52
  40. package/dist/schema/next.cjs.map +1 -1
  41. package/dist/schema/next.d.cts +12 -428
  42. package/dist/schema/next.d.ts +12 -428
  43. package/dist/schema/next.js +20 -2
  44. package/dist/schema/next.js.map +1 -1
  45. package/dist/schema.cjs +831 -156
  46. package/dist/schema.cjs.map +1 -1
  47. package/dist/schema.d.cts +318 -41
  48. package/dist/schema.d.ts +318 -41
  49. package/dist/schema.js +567 -86
  50. package/dist/schema.js.map +1 -1
  51. package/dist/types-BRn3hfQb.d.ts +24 -0
  52. package/dist/types-BSgolLj3.d.cts +24 -0
  53. package/dist/{types-R3n9Fu4w.d.cts → types-BtSRRG6C.d.cts} +1 -1
  54. package/dist/{types-R3n9Fu4w.d.ts → types-BtSRRG6C.d.ts} +1 -1
  55. package/dist/types-DnVvOp3o.d.ts +1215 -0
  56. package/dist/types-DoUYMRVf.d.cts +1215 -0
  57. package/package.json +2 -1
  58. package/dist/SeoHealthDashboard-KPBNXSL4.cjs +0 -10
  59. package/dist/SeoHealthDashboard-QKVB5HK3.js +0 -4
  60. package/dist/SeoPreview-G3LPA7GV.js.map +0 -1
  61. package/dist/SeoPreview-Y3CFDVBR.cjs.map +0 -1
  62. package/dist/chunk-527WXITP.js.map +0 -1
  63. package/dist/chunk-6CYMVS3O.js +0 -1245
  64. package/dist/chunk-6CYMVS3O.js.map +0 -1
  65. package/dist/chunk-D2GWRRK5.cjs +0 -1293
  66. package/dist/chunk-D2GWRRK5.cjs.map +0 -1
  67. package/dist/chunk-L3L3FSPJ.cjs +0 -478
  68. package/dist/chunk-L3L3FSPJ.cjs.map +0 -1
  69. package/dist/types-CVaAX7uy.d.cts +0 -589
  70. package/dist/types-Ci-ZZT7A.d.ts +0 -589
package/dist/index.cjs CHANGED
@@ -661,7 +661,7 @@ function twitter(config = {}) {
661
661
  }
662
662
 
663
663
  // src/schemas/index.ts
664
- var LazySeoPreview = React12__default.default.lazy(() => import('./SeoPreview-Y3CFDVBR.cjs'));
664
+ var LazySeoPreview = React12__default.default.lazy(() => import('./SeoPreview-JDROKZLP.cjs'));
665
665
  var SeoPreviewWrapper = (props) => React12__default.default.createElement(React12__default.default.Suspense, { fallback: null }, React12__default.default.createElement(LazySeoPreview, props));
666
666
  function buildFieldGroupMap(groups) {
667
667
  const map = /* @__PURE__ */ new Map();
@@ -987,100 +987,30 @@ function types(config = {}) {
987
987
  }
988
988
 
989
989
  // src/plugin.ts
990
- var V132 = "v1.3.2";
991
- var CHANGELOG_V132 = `https://github.com/hardik-143/sanity-plugin-seofields/blob/main/CHANGELOG.md#132--2026-03-23`;
992
990
  var resolveDashboardConfig = (healthDashboard) => {
993
- var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p, _q, _r, _s, _t, _u, _v;
991
+ var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n;
994
992
  const cfg = typeof healthDashboard === "object" ? healthDashboard : void 0;
995
- const deprecationWarnings = [];
996
- if (((_a = cfg == null ? void 0 : cfg.display) == null ? void 0 : _a.typeColumn) !== void 0) {
997
- deprecationWarnings.push({
998
- key: "display.typeColumn \u2192 showTypeColumn",
999
- version: V132,
1000
- changelogUrl: CHANGELOG_V132
1001
- });
1002
- if (cfg.showTypeColumn) {
1003
- console.warn(
1004
- `[sanity-plugin-seofields] Both "healthDashboard.display.typeColumn" and "healthDashboard.showTypeColumn" are set. "showTypeColumn" will take precedence. Please remove "healthDashboard.display.typeColumn". See ${CHANGELOG_V132}`
1005
- );
1006
- } else {
1007
- console.warn(
1008
- `[sanity-plugin-seofields] "healthDashboard.display.typeColumn" is deprecated. Use "healthDashboard.showTypeColumn" instead. See ${CHANGELOG_V132}`
1009
- );
1010
- }
1011
- }
1012
- if (((_b = cfg == null ? void 0 : cfg.display) == null ? void 0 : _b.documentId) !== void 0) {
1013
- deprecationWarnings.push({
1014
- key: "display.documentId \u2192 showDocumentId",
1015
- version: V132,
1016
- changelogUrl: CHANGELOG_V132
1017
- });
1018
- if (cfg.showDocumentId) {
1019
- console.warn(
1020
- `[sanity-plugin-seofields] Both "healthDashboard.display.documentId" and "healthDashboard.showDocumentId" are set. "showDocumentId" will take precedence. Please remove "healthDashboard.display.documentId". See ${CHANGELOG_V132}`
1021
- );
1022
- } else {
1023
- console.warn(
1024
- `[sanity-plugin-seofields] "healthDashboard.display.documentId" is deprecated. Use "healthDashboard.showDocumentId" instead. See ${CHANGELOG_V132}`
1025
- );
1026
- }
1027
- }
1028
- if (cfg == null ? void 0 : cfg.typeLabels) {
1029
- deprecationWarnings.push({
1030
- key: "typeLabels \u2192 typeDisplayLabels",
1031
- version: V132,
1032
- changelogUrl: CHANGELOG_V132
1033
- });
1034
- if (cfg.typeDisplayLabels) {
1035
- console.warn(
1036
- `[sanity-plugin-seofields] Both "healthDashboard.typeLabels" and "healthDashboard.typeDisplayLabels" are set. "typeDisplayLabels" will take precedence. Please remove "typeLabels". See ${CHANGELOG_V132}`
1037
- );
1038
- } else {
1039
- console.warn(
1040
- `[sanity-plugin-seofields] "healthDashboard.typeLabels" is deprecated. Use "healthDashboard.typeDisplayLabels" instead. See ${CHANGELOG_V132}`
1041
- );
1042
- }
1043
- }
1044
- if (cfg == null ? void 0 : cfg.docBadge) {
1045
- deprecationWarnings.push({
1046
- key: "docBadge \u2192 getDocumentBadge",
1047
- version: V132,
1048
- changelogUrl: CHANGELOG_V132
1049
- });
1050
- if (cfg == null ? void 0 : cfg.getDocumentBadge) {
1051
- console.warn(
1052
- `[sanity-plugin-seofields] Both "healthDashboard.docBadge" and "healthDashboard.getDocumentBadge" are set. "getDocumentBadge" will take precedence. Please remove "docBadge". See ${CHANGELOG_V132}`
1053
- );
1054
- } else {
1055
- console.warn(
1056
- `[sanity-plugin-seofields] "healthDashboard.docBadge" is deprecated. Use "healthDashboard.getDocumentBadge" instead. See ${CHANGELOG_V132}`
1057
- );
1058
- }
1059
- }
1060
993
  return {
1061
994
  enabled: healthDashboard !== false,
1062
- toolTitle: (_d = (_c = cfg == null ? void 0 : cfg.tool) == null ? void 0 : _c.title) != null ? _d : "SEO Health",
1063
- toolName: (_f = (_e = cfg == null ? void 0 : cfg.tool) == null ? void 0 : _e.name) != null ? _f : "seo-health-dashboard",
1064
- icon: (_g = cfg == null ? void 0 : cfg.content) == null ? void 0 : _g.icon,
1065
- title: (_h = cfg == null ? void 0 : cfg.content) == null ? void 0 : _h.title,
1066
- description: (_i = cfg == null ? void 0 : cfg.content) == null ? void 0 : _i.description,
1067
- // New flat keys take precedence; fall back to deprecated display.* for backwards compat
1068
- showTypeColumn: (_k = cfg == null ? void 0 : cfg.showTypeColumn) != null ? _k : (_j = cfg == null ? void 0 : cfg.display) == null ? void 0 : _j.typeColumn,
1069
- showDocumentId: (_m = cfg == null ? void 0 : cfg.showDocumentId) != null ? _m : (_l = cfg == null ? void 0 : cfg.display) == null ? void 0 : _l.documentId,
1070
- queryTypes: (_n = cfg == null ? void 0 : cfg.query) == null ? void 0 : _n.types,
1071
- queryRequireSeo: (_o = cfg == null ? void 0 : cfg.query) == null ? void 0 : _o.requireSeo,
1072
- queryGroq: (_p = cfg == null ? void 0 : cfg.query) == null ? void 0 : _p.groq,
995
+ toolTitle: (_b = (_a = cfg == null ? void 0 : cfg.tool) == null ? void 0 : _a.title) != null ? _b : "SEO Health",
996
+ toolName: (_d = (_c = cfg == null ? void 0 : cfg.tool) == null ? void 0 : _c.name) != null ? _d : "seo-health-dashboard",
997
+ icon: (_e = cfg == null ? void 0 : cfg.content) == null ? void 0 : _e.icon,
998
+ title: (_f = cfg == null ? void 0 : cfg.content) == null ? void 0 : _f.title,
999
+ description: (_g = cfg == null ? void 0 : cfg.content) == null ? void 0 : _g.description,
1000
+ showTypeColumn: cfg == null ? void 0 : cfg.showTypeColumn,
1001
+ showDocumentId: cfg == null ? void 0 : cfg.showDocumentId,
1002
+ queryTypes: (_h = cfg == null ? void 0 : cfg.query) == null ? void 0 : _h.types,
1003
+ queryRequireSeo: (_i = cfg == null ? void 0 : cfg.query) == null ? void 0 : _i.requireSeo,
1004
+ queryGroq: (_j = cfg == null ? void 0 : cfg.query) == null ? void 0 : _j.groq,
1073
1005
  apiVersion: cfg == null ? void 0 : cfg.apiVersion,
1074
1006
  licenseKey: cfg == null ? void 0 : cfg.licenseKey,
1075
- // New key takes precedence; fall back to deprecated key for backwards compat
1076
- typeDisplayLabels: (_q = cfg == null ? void 0 : cfg.typeDisplayLabels) != null ? _q : cfg == null ? void 0 : cfg.typeLabels,
1007
+ typeDisplayLabels: cfg == null ? void 0 : cfg.typeDisplayLabels,
1077
1008
  typeColumnMode: cfg == null ? void 0 : cfg.typeColumnMode,
1078
1009
  titleField: cfg == null ? void 0 : cfg.titleField,
1079
- // New key takes precedence; fall back to deprecated key for backwards compat
1080
- getDocumentBadge: (_r = cfg == null ? void 0 : cfg.getDocumentBadge) != null ? _r : cfg == null ? void 0 : cfg.docBadge,
1081
- loadingLicense: (_s = cfg == null ? void 0 : cfg.content) == null ? void 0 : _s.loadingLicense,
1082
- loadingDocuments: (_t = cfg == null ? void 0 : cfg.content) == null ? void 0 : _t.loadingDocuments,
1083
- noDocuments: (_u = cfg == null ? void 0 : cfg.content) == null ? void 0 : _u.noDocuments,
1010
+ getDocumentBadge: cfg == null ? void 0 : cfg.getDocumentBadge,
1011
+ loadingLicense: (_k = cfg == null ? void 0 : cfg.content) == null ? void 0 : _k.loadingLicense,
1012
+ loadingDocuments: (_l = cfg == null ? void 0 : cfg.content) == null ? void 0 : _l.loadingDocuments,
1013
+ noDocuments: (_m = cfg == null ? void 0 : cfg.content) == null ? void 0 : _m.noDocuments,
1084
1014
  previewMode: cfg == null ? void 0 : cfg.previewMode,
1085
1015
  structureTool: cfg == null ? void 0 : cfg.structureTool,
1086
1016
  exportEnabled: (() => {
@@ -1095,14 +1025,14 @@ var resolveDashboardConfig = (healthDashboard) => {
1095
1025
  if (typeof exportCfg === "object" && exportCfg.formats) return exportCfg.formats;
1096
1026
  return ["csv", "json"];
1097
1027
  })(),
1098
- compactStats: (_v = cfg == null ? void 0 : cfg.compactStats) != null ? _v : false,
1099
- deprecationWarnings
1028
+ compactStats: (_n = cfg == null ? void 0 : cfg.compactStats) != null ? _n : false,
1029
+ deprecationWarnings: []
1100
1030
  };
1101
1031
  };
1102
1032
  var seofields = sanity.definePlugin((config = {}) => {
1103
1033
  const { healthDashboard = true } = config;
1104
1034
  const dash = resolveDashboardConfig(healthDashboard);
1105
- const LazySeoHealthTool = React12__default.default.lazy(() => import('./SeoHealthTool-ON3SRXCF.cjs'));
1035
+ const LazySeoHealthTool = React12__default.default.lazy(() => import('./SeoHealthTool-2H4XZR4I.cjs'));
1106
1036
  const BoundSeoHealthTool = () => React12__default.default.createElement(
1107
1037
  React12__default.default.Suspense,
1108
1038
  { fallback: null },
@@ -1149,7 +1079,7 @@ var seofields = sanity.definePlugin((config = {}) => {
1149
1079
  });
1150
1080
  });
1151
1081
  var plugin_default = seofields;
1152
- var LazySeoHealthDashboard = React12__default.default.lazy(() => import('./SeoHealthDashboard-KPBNXSL4.cjs'));
1082
+ var LazySeoHealthDashboard = React12__default.default.lazy(() => import('./SeoHealthDashboard-7XMPVJRX.cjs'));
1153
1083
  function createSeoHealthPane(optionsOrS, optionsWhenS) {
1154
1084
  const S = optionsOrS;
1155
1085
  const _a = optionsWhenS != null ? optionsWhenS : {}, { query, openInPane = true, title: paneTitle } = _a, rest = chunkS367Y35J_cjs.__objRest(_a, ["query", "openInPane", "title"]);