sanity-plugin-seofields 1.5.3 → 1.5.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/cli.js CHANGED
@@ -61,7 +61,7 @@ ${e}`}function ft(e,t,n,o){a.success(`Updated ${e}`),a.dim(""),a.dim(" What was
61
61
  title,
62
62
  slug,
63
63
  seo
64
- } | order(_updatedAt desc)`;o.text="Fetching documents...";let d;try{d=await s.fetch(l);}catch(u){o.fail(`Failed to fetch: ${u.message}`),process.exit(1);}if(o.succeed(`Analysed ${d.length} document(s)`),d.length===0){a.warn("No documents with SEO fields found."),n&&Se(i);return}let g=d.map(u=>({doc:u,health:G(u)}));await gt(g,d,e),n&&Se(i);}async function gt(e,t,n){let o={excellent:0,good:0,fair:0,poor:0,missing:0},s=0;for(let{health:d}of e)o[d.status]=(o[d.status]||0)+1,s+=d.score;let i=Math.round(s/e.length);if(pt(t,i,o),n.format==="summary")return;n.format!=="table"&&(a.info(""),a.warn(`Unknown format "${n.format}", defaulting to table output.`)),St(e);let r={};for(let{health:d}of e)for(let g of d.issues)r[g]=(r[g]||0)+1;let l=Object.entries(r).sort(([,d],[,g])=>g-d).slice(0,10);l.length>0&&$t(l,t.length),a.info("");}function pt(e,t,n){a.heading("\u{1F4CA} Summary"),a.info(""),a.info(` Total documents: ${c.bold(String(e.length))}`),a.info(` Average score: ${c.bold(ve(t))}%`),a.info(""),a.info(` ${A.excellent} Excellent (80+): ${n.excellent}`),a.info(` ${A.good} Good (60-79): ${n.good}`),a.info(` ${A.fair} Fair (40-59): ${n.fair}`),a.info(` ${A.poor} Poor (1-39): ${n.poor}`),a.info(` ${A.missing} Missing (0): ${n.missing}`);}var mt={excellent:"Excellent",good:"Good",fair:"Fair",poor:"Poor",missing:"Missing"},ht={excellent:c.green,good:c.blue,fair:c.yellow,poor:c.red,missing:c.dim};function yt(e,t=11){var s,i;let n=((s=mt[e])!=null?s:e).padEnd(t);return ((i=ht[e])!=null?i:(r=>r))(n)}function St(e){a.heading("\u{1F4CB} Documents"),a.info("");let t=Math.min(44,Math.max(5,...e.map(({doc:r})=>(r.title||r._id).length))),n=11,o=14,s=5,i=c.dim("\u2500".repeat(s+2+n+2+o+2+t));a.info(` ${c.dim("Score".padEnd(s))} ${c.dim("Status".padEnd(n))} ${c.dim("Type".padEnd(o))} ${c.dim("Title")}`),a.info(` ${i}`);for(let{doc:r,health:l}of e){let d=$e(r.title||r._id,t),g=String(l.score).padStart(s),f=yt(l.status,n),u=c.dim($e(r._type,o).padEnd(o));a.info(` ${ve(l.score,g)} ${f} ${u} ${d}`);}}function $t(e,t){a.heading("\u{1F50D} Top Issues"),a.info("");for(let[n,o]of e){let s=Math.round(o/t*100);a.info(` ${c.red(String(o).padStart(4))} docs (${s}%) ${n}`);}}function Se(e){a.info(""),a.info(` ${c.dim("\u2500".repeat(52))}`),a.info(` ${c.dim("Connection info")}`),a.info(` ${c.dim("Project ID:")} ${c.white(e.projectId)} ${c.dim(`\u2190 ${e.sources.projectId}`)}`),a.info(` ${c.dim("Dataset: ")} ${c.white(e.dataset)} ${c.dim(`\u2190 ${e.sources.dataset}`)}`),a.info(` ${c.dim("Token: ")} ${c.dim(e.sources.token)}`),a.info("");}function ve(e,t){let n=t!=null?t:String(e);return e>=80?c.green(n):e>=60?c.blue(n):e>=40?c.yellow(n):e>0?c.red(n):c.dim(n)}function $e(e,t){return e.length>t?`${e.slice(0,t-1)}\u2026`:e}U();var Q="1.5.3",Ce=[c.cyan,e=>c.bold(c.blue(e)),c.blue,c.magenta,c.red,c.yellow],v=Ce[Math.floor(Math.random()*Ce.length)],we=["Run `seofields doctor` first to verify your setup is correct.","Use `seofields report --format summary` for a quick overview.","Export your SEO data before making bulk changes: `seofields export -o backup.json`.","Add `seoFields` type to every document schema to track SEO health.","A meta title between 50\u201360 characters gets the best click-through rate.","Meta descriptions should be 140\u2013160 characters for optimal display.","Open Graph images should be 1200\xD7630px for best social sharing.","Use `seofields config --baseUrl=https://yoursite.com` to enable canonical URLs.","Twitter Card images require a separate `twitterImage` field for best results.","Schema.org markup helps search engines understand your content structure.","Use `seofields report --types post,page` to filter by document type.","The `healthDashboard` tool gives a live view of SEO scores inside Sanity Studio.","Keywords should appear naturally \u2014 avoid keyword stuffing.","Every page needs a unique meta title. Duplicates hurt rankings.","Use `seofields export --format csv` to open SEO data in a spreadsheet.","Set `noIndex: true` on internal or draft pages to prevent indexing.","OG title and meta title can differ \u2014 OG is optimised for social, meta for search.","Run `seofields report` after content migrations to catch regressions.","Use `seofields init --schema-org` to add structured data support.","Structured data (Schema.org) can unlock rich results in Google Search.","A score of 80+ is excellent. Aim to get all key pages there.","The `seoPreview` option shows a live Google-style preview inside the editor.","Use `seofields report` in CI to catch SEO regressions before they ship.","Use `--dataset staging` to run reports against your staging dataset.","Keep your license key private \u2014 never commit it to version control.","Use `seofields config --healthDashboard.showDocumentId=true` for easier debugging.","Use `seofields export --format json --output report.json` to save SEO data to a file.","Alt text on images improves both accessibility and image search ranking.","Canonical URLs prevent duplicate content penalties from search engines.","A missing OG image means social shares show a blank card \u2014 always add one.","Use descriptive slugs: `/blog/seo-tips` ranks better than `/blog/post-123`.","Re-run `seofields report` monthly to track your SEO health over time.","The `types` filter helps you focus reports on high-priority content.","Use `seofields export` to back up SEO data before schema migrations.","Short meta titles (under 30 chars) waste valuable search result space.","Long meta descriptions get truncated \u2014 stay under 160 characters.","Twitter Cards need `twitter:card`, `twitter:title`, and `twitter:image` at minimum.","Use `seofields doctor` after upgrading the plugin to catch breaking changes.","JSON export includes health scores \u2014 pipe it into your analytics pipeline.","Set a `defaultHiddenFields` list to keep the SEO panel focused.","Internal links pass authority \u2014 make sure important pages are well-linked.","Page speed is a ranking factor \u2014 optimise images referenced in SEO fields.","Use consistent brand phrasing in meta titles across your site.","Structured data errors can be tested at schema.org/validator.","Focus first on pages with the most traffic, not just the lowest scores.","Add SEO review to your content publishing checklist.","Use `seofields config --healthDashboard.licenseKey=KEY` to unlock premium features.","The CSV export makes it easy to share SEO audits with non-technical stakeholders.","Every image on your page should have descriptive alt text.","Avoid duplicate meta descriptions \u2014 each page needs its own."];function bt(){return we[Math.floor(Math.random()*we.length)]}var vt=62,K=vt-2;function Ct(e,t){let n=e.split(" "),o=[],s="";for(let i of n)s.length+(s?1:0)+i.length>t?(s&&o.push(s),s=i):s=s?`${s} ${i}`:i;return s&&o.push(s),o}function F(e,t){let n=K-3,o=" ".repeat(Math.max(0,n-t));return ` ${v("\u2502")} ${e}${o} ${v("\u2502")}`}function M(){return F("",0)}function Ie(){let e="\u2500".repeat(K),t=bt(),n=K-3-5,o=Ct(t,n);console.log(),console.log(` ${v(`\u256D${e}\u256E`)}`),console.log(M()),console.log(F(`${c.bold(c.green("seofields"))}${c.dim(` v${Q}`)}`,`seofields v${Q}`.length)),console.log(F(c.dim("SEO tooling for Sanity CMS \u2014 manage from your terminal"),54)),console.log(M());for(let i=0;i<o.length;i++){let r=i===0?`${c.dim("Tip: ")}${c.white(o[i])}`:` ${c.white(o[i])}`,l=5+o[i].length;console.log(F(r,l));}console.log(M()),console.log(` ${v(`\u2570${e}\u256F`)}`),console.log(),console.log(` ${c.bold("Commands")}`),console.log();let s=[["init ","Add seofields() to sanity.config"],["config ","Update plugin configuration options"],["create-config ","Create seofields.cli.ts / .js interactively"],["report ","SEO health report across all documents"],["export ","Export SEO fields as JSON or CSV"],["doctor ","Check setup, deps & config"]];for(let[i,r]of s)console.log(` ${v(i)} ${c.dim(r)}`);console.log(),console.log(` ${c.dim("Run ")}${c.white("seofields <command> --help")}${c.dim(" for details")}`),console.log();}function P(e,t){let n="\u2500".repeat(K),o=`seofields \u203A ${e}`;return ["",` ${v(`\u256D${n}\u256E`)}`,M(),F(`${c.bold(c.green("seofields"))}${v(" \u203A ")}${c.bold(v(e))}`,o.length),F(c.dim(t),t.length),M(),` ${v(`\u2570${n}\u256F`)}`].join(`
64
+ } | order(_updatedAt desc)`;o.text="Fetching documents...";let d;try{d=await s.fetch(l);}catch(u){o.fail(`Failed to fetch: ${u.message}`),process.exit(1);}if(o.succeed(`Analysed ${d.length} document(s)`),d.length===0){a.warn("No documents with SEO fields found."),n&&Se(i);return}let g=d.map(u=>({doc:u,health:G(u)}));await gt(g,d,e),n&&Se(i);}async function gt(e,t,n){let o={excellent:0,good:0,fair:0,poor:0,missing:0},s=0;for(let{health:d}of e)o[d.status]=(o[d.status]||0)+1,s+=d.score;let i=Math.round(s/e.length);if(pt(t,i,o),n.format==="summary")return;n.format!=="table"&&(a.info(""),a.warn(`Unknown format "${n.format}", defaulting to table output.`)),St(e);let r={};for(let{health:d}of e)for(let g of d.issues)r[g]=(r[g]||0)+1;let l=Object.entries(r).sort(([,d],[,g])=>g-d).slice(0,10);l.length>0&&$t(l,t.length),a.info("");}function pt(e,t,n){a.heading("\u{1F4CA} Summary"),a.info(""),a.info(` Total documents: ${c.bold(String(e.length))}`),a.info(` Average score: ${c.bold(ve(t))}%`),a.info(""),a.info(` ${A.excellent} Excellent (80+): ${n.excellent}`),a.info(` ${A.good} Good (60-79): ${n.good}`),a.info(` ${A.fair} Fair (40-59): ${n.fair}`),a.info(` ${A.poor} Poor (1-39): ${n.poor}`),a.info(` ${A.missing} Missing (0): ${n.missing}`);}var mt={excellent:"Excellent",good:"Good",fair:"Fair",poor:"Poor",missing:"Missing"},ht={excellent:c.green,good:c.blue,fair:c.yellow,poor:c.red,missing:c.dim};function yt(e,t=11){var s,i;let n=((s=mt[e])!=null?s:e).padEnd(t);return ((i=ht[e])!=null?i:(r=>r))(n)}function St(e){a.heading("\u{1F4CB} Documents"),a.info("");let t=Math.min(44,Math.max(5,...e.map(({doc:r})=>(r.title||r._id).length))),n=11,o=14,s=5,i=c.dim("\u2500".repeat(s+2+n+2+o+2+t));a.info(` ${c.dim("Score".padEnd(s))} ${c.dim("Status".padEnd(n))} ${c.dim("Type".padEnd(o))} ${c.dim("Title")}`),a.info(` ${i}`);for(let{doc:r,health:l}of e){let d=$e(r.title||r._id,t),g=String(l.score).padStart(s),f=yt(l.status,n),u=c.dim($e(r._type,o).padEnd(o));a.info(` ${ve(l.score,g)} ${f} ${u} ${d}`);}}function $t(e,t){a.heading("\u{1F50D} Top Issues"),a.info("");for(let[n,o]of e){let s=Math.round(o/t*100);a.info(` ${c.red(String(o).padStart(4))} docs (${s}%) ${n}`);}}function Se(e){a.info(""),a.info(` ${c.dim("\u2500".repeat(52))}`),a.info(` ${c.dim("Connection info")}`),a.info(` ${c.dim("Project ID:")} ${c.white(e.projectId)} ${c.dim(`\u2190 ${e.sources.projectId}`)}`),a.info(` ${c.dim("Dataset: ")} ${c.white(e.dataset)} ${c.dim(`\u2190 ${e.sources.dataset}`)}`),a.info(` ${c.dim("Token: ")} ${c.dim(e.sources.token)}`),a.info("");}function ve(e,t){let n=t!=null?t:String(e);return e>=80?c.green(n):e>=60?c.blue(n):e>=40?c.yellow(n):e>0?c.red(n):c.dim(n)}function $e(e,t){return e.length>t?`${e.slice(0,t-1)}\u2026`:e}U();var Q="1.5.4",Ce=[c.cyan,e=>c.bold(c.blue(e)),c.blue,c.magenta,c.red,c.yellow],v=Ce[Math.floor(Math.random()*Ce.length)],we=["Run `seofields doctor` first to verify your setup is correct.","Use `seofields report --format summary` for a quick overview.","Export your SEO data before making bulk changes: `seofields export -o backup.json`.","Add `seoFields` type to every document schema to track SEO health.","A meta title between 50\u201360 characters gets the best click-through rate.","Meta descriptions should be 140\u2013160 characters for optimal display.","Open Graph images should be 1200\xD7630px for best social sharing.","Use `seofields config --baseUrl=https://yoursite.com` to enable canonical URLs.","Twitter Card images require a separate `twitterImage` field for best results.","Schema.org markup helps search engines understand your content structure.","Use `seofields report --types post,page` to filter by document type.","The `healthDashboard` tool gives a live view of SEO scores inside Sanity Studio.","Keywords should appear naturally \u2014 avoid keyword stuffing.","Every page needs a unique meta title. Duplicates hurt rankings.","Use `seofields export --format csv` to open SEO data in a spreadsheet.","Set `noIndex: true` on internal or draft pages to prevent indexing.","OG title and meta title can differ \u2014 OG is optimised for social, meta for search.","Run `seofields report` after content migrations to catch regressions.","Use `seofields init --schema-org` to add structured data support.","Structured data (Schema.org) can unlock rich results in Google Search.","A score of 80+ is excellent. Aim to get all key pages there.","The `seoPreview` option shows a live Google-style preview inside the editor.","Use `seofields report` in CI to catch SEO regressions before they ship.","Use `--dataset staging` to run reports against your staging dataset.","Keep your license key private \u2014 never commit it to version control.","Use `seofields config --healthDashboard.showDocumentId=true` for easier debugging.","Use `seofields export --format json --output report.json` to save SEO data to a file.","Alt text on images improves both accessibility and image search ranking.","Canonical URLs prevent duplicate content penalties from search engines.","A missing OG image means social shares show a blank card \u2014 always add one.","Use descriptive slugs: `/blog/seo-tips` ranks better than `/blog/post-123`.","Re-run `seofields report` monthly to track your SEO health over time.","The `types` filter helps you focus reports on high-priority content.","Use `seofields export` to back up SEO data before schema migrations.","Short meta titles (under 30 chars) waste valuable search result space.","Long meta descriptions get truncated \u2014 stay under 160 characters.","Twitter Cards need `twitter:card`, `twitter:title`, and `twitter:image` at minimum.","Use `seofields doctor` after upgrading the plugin to catch breaking changes.","JSON export includes health scores \u2014 pipe it into your analytics pipeline.","Set a `defaultHiddenFields` list to keep the SEO panel focused.","Internal links pass authority \u2014 make sure important pages are well-linked.","Page speed is a ranking factor \u2014 optimise images referenced in SEO fields.","Use consistent brand phrasing in meta titles across your site.","Structured data errors can be tested at schema.org/validator.","Focus first on pages with the most traffic, not just the lowest scores.","Add SEO review to your content publishing checklist.","Use `seofields config --healthDashboard.licenseKey=KEY` to unlock premium features.","The CSV export makes it easy to share SEO audits with non-technical stakeholders.","Every image on your page should have descriptive alt text.","Avoid duplicate meta descriptions \u2014 each page needs its own."];function bt(){return we[Math.floor(Math.random()*we.length)]}var vt=62,K=vt-2;function Ct(e,t){let n=e.split(" "),o=[],s="";for(let i of n)s.length+(s?1:0)+i.length>t?(s&&o.push(s),s=i):s=s?`${s} ${i}`:i;return s&&o.push(s),o}function F(e,t){let n=K-3,o=" ".repeat(Math.max(0,n-t));return ` ${v("\u2502")} ${e}${o} ${v("\u2502")}`}function M(){return F("",0)}function Ie(){let e="\u2500".repeat(K),t=bt(),n=K-3-5,o=Ct(t,n);console.log(),console.log(` ${v(`\u256D${e}\u256E`)}`),console.log(M()),console.log(F(`${c.bold(c.green("seofields"))}${c.dim(` v${Q}`)}`,`seofields v${Q}`.length)),console.log(F(c.dim("SEO tooling for Sanity CMS \u2014 manage from your terminal"),54)),console.log(M());for(let i=0;i<o.length;i++){let r=i===0?`${c.dim("Tip: ")}${c.white(o[i])}`:` ${c.white(o[i])}`,l=5+o[i].length;console.log(F(r,l));}console.log(M()),console.log(` ${v(`\u2570${e}\u256F`)}`),console.log(),console.log(` ${c.bold("Commands")}`),console.log();let s=[["init ","Add seofields() to sanity.config"],["config ","Update plugin configuration options"],["create-config ","Create seofields.cli.ts / .js interactively"],["report ","SEO health report across all documents"],["export ","Export SEO fields as JSON or CSV"],["doctor ","Check setup, deps & config"]];for(let[i,r]of s)console.log(` ${v(i)} ${c.dim(r)}`);console.log(),console.log(` ${c.dim("Run ")}${c.white("seofields <command> --help")}${c.dim(" for details")}`),console.log();}function P(e,t){let n="\u2500".repeat(K),o=`seofields \u203A ${e}`;return ["",` ${v(`\u256D${n}\u256E`)}`,M(),F(`${c.bold(c.green("seofields"))}${v(" \u203A ")}${c.bold(v(e))}`,o.length),F(c.dim(t),t.length),M(),` ${v(`\u2570${n}\u256F`)}`].join(`
65
65
  `)}program.name("seofields").description("CLI for sanity-plugin-seofields \u2014 manage SEO from your terminal").version(Q).action(Ie);program.command("config",{isDefault:false}).description("Update seofields() configuration in your sanity.config file").addHelpText("before",P("config","Update seofields() configuration in your sanity.config file")).allowUnknownOption().allowExcessArguments().helpOption("-h, --help","Show help and all available options").addHelpText("after",["",` ${c.bold("Usage")}`,` ${c.dim("Pass any option as")} ${c.white("--key=value")}${c.dim(". Nested keys use dot notation.")}`,"",` ${c.bold("Top-level options")}`,` ${v("--baseUrl")}${c.dim("=<url>").padEnd(38)} ${c.dim("Canonical base URL")}`,` ${v("--seoPreview")}${c.dim("=<bool>").padEnd(36)} ${c.dim("Enable live Google-style preview")}`,` ${v("--defaultHiddenFields")}${c.dim("=<f1,f2>").padEnd(28)} ${c.dim("Comma-separated fields to hide")}`,` ${v("--types")}${c.dim("=<t1,t2>").padEnd(40)} ${c.dim("Document types that have SEO fields")}`,"",` ${c.bold("healthDashboard options")} ${c.dim("(prefix: --healthDashboard.<key>)")}`,` ${v("--healthDashboard.licenseKey")}${c.dim("=<key>").padEnd(22)} ${c.dim("License key for premium features")}`,` ${v("--healthDashboard.toolTitle")}${c.dim("=<str>").padEnd(23)} ${c.dim("Custom title shown in Studio")}`,` ${v("--healthDashboard.showDocumentId")}${c.dim("=<bool>").padEnd(17)} ${c.dim("Show document _id in dashboard")}`,` ${v("--healthDashboard.showHealthScore")}${c.dim("=<bool>").padEnd(16)} ${c.dim("Show score badge per document")}`,` ${v("--healthDashboard.query.types")}${c.dim("=<t1,t2>").padEnd(21)} ${c.dim("Filter dashboard by document types")}`,"",` ${c.bold("Examples")}`,` ${c.white("seofields config --baseUrl=https://mysite.com")}`,` ${c.white("seofields config --healthDashboard.licenseKey=SEOF-1234")}`,` ${c.white("seofields config --healthDashboard.showDocumentId=true --seoPreview=true")}`,` ${c.white("seofields config --healthDashboard.query.types=post,page")}`,` ${c.white("seofields config --defaultHiddenFields=metaImage,openGraphUrl")}`,""].join(`
66
66
  `)).action(()=>{let e=process.argv.indexOf("config"),t=e>=0?process.argv.slice(e+1):[];de(t);});program.command("create-config").description("Interactively create a seofields.cli.ts / .js config file").addHelpText("before",P("create-config","Interactively create a seofields.cli.ts / .js config file")).action(ue);program.command("init").description("Add seofields() plugin to your sanity.config file").addHelpText("before",P("init","Add seofields() plugin to your sanity.config file")).option("--preview","Enable SEO preview in the plugin config").option("--dashboard","Explicitly enable the SEO Health Dashboard").option("--no-dashboard","Disable the SEO Health Dashboard").option("--schema-org","Also add schemaOrg() plugin registration").addHelpText("after",["",` ${c.dim("Note: ")}${c.yellow("--preview")}${c.dim(", ")}${c.yellow("--dashboard")}${c.dim(", and ")}${c.yellow("--no-dashboard")}${c.dim(" only apply during initial setup.")}`,` ${c.dim(" If seofields() is already in your config, use:")}`,"",` ${c.dim(" ")}${c.white("seofields config --healthDashboard=true --seoPreview=true")}`,""].join(`
67
67
  `)).action(ye);program.command("export").description("Export all documents with SEO fields as JSON or CSV").addHelpText("before",P("export","Export all documents with SEO fields as JSON or CSV")).option("-p, --project-id <id>","Sanity project ID").option("-d, --dataset <name>","Sanity dataset name").option("-t, --token <token>","Sanity API token").option("--types <types>","Comma-separated document types to export (e.g. post,page)").option("-f, --format <format>","Output format: json or csv","json").option("-o, --output <path>","Output file path (defaults to stdout)").action(me);program.command("report").description("Generate an SEO health report for all documents").addHelpText("before",P("report","Generate an SEO health report for all documents")).option("-p, --project-id <id>","Sanity project ID").option("-d, --dataset <name>","Sanity dataset name").option("-t, --token <token>","Sanity API token").option("--types <types>","Comma-separated document types to include").option("--format <format>",'Output format: table or summary (default: "table")',"table").action(be);program.command("doctor").description("Check plugin configuration, dependencies, and setup").addHelpText("before",P("doctor","Check plugin configuration, dependencies, and setup")).option("--cwd <path>","Working directory to check",process.cwd()).action(ge);var _=process.argv.slice(2);_.length===1&&(_[0]==="--help"||_[0]==="-h")&&(Ie(),process.exit(0));if(_.length>=2&&_[_.length-1]==="help"){let e=program.commands.find(t=>t.name()===_[0]);e&&(e.help(),process.exit(0));}program.parse();
package/dist/index.cjs CHANGED
@@ -766,6 +766,70 @@ function seoFieldsSchema(config = {}) {
766
766
  ]
767
767
  });
768
768
  }
769
+ function baseMeta(config = {}) {
770
+ return sanity.defineType({
771
+ name: "baseMeta",
772
+ title: "Basic Meta Settings",
773
+ type: "object",
774
+ fields: [
775
+ sanity.defineField(chunkS367Y35J_cjs.__spreadProps(chunkS367Y35J_cjs.__spreadValues({
776
+ name: "title"
777
+ }, getFieldInfo("title", config.fieldOverrides)), {
778
+ type: "string",
779
+ components: {
780
+ input: MetaTitle_default
781
+ },
782
+ hidden: getFieldHiddenFunction("title", config)
783
+ })),
784
+ sanity.defineField(chunkS367Y35J_cjs.__spreadProps(chunkS367Y35J_cjs.__spreadValues({
785
+ name: "description"
786
+ }, getFieldInfo("description", config.fieldOverrides)), {
787
+ type: "text",
788
+ rows: 3,
789
+ components: {
790
+ input: MetaDescription_default
791
+ },
792
+ hidden: getFieldHiddenFunction("description", config)
793
+ })),
794
+ sanity.defineField(chunkS367Y35J_cjs.__spreadProps(chunkS367Y35J_cjs.__spreadValues({
795
+ name: "metaImage"
796
+ }, getFieldInfo("metaImage", config.fieldOverrides)), {
797
+ type: "image",
798
+ options: {
799
+ hotspot: true
800
+ },
801
+ components: {
802
+ input: MetaImage_default
803
+ },
804
+ hidden: getFieldHiddenFunction("metaImage", config)
805
+ })),
806
+ sanity.defineField(chunkS367Y35J_cjs.__spreadProps(chunkS367Y35J_cjs.__spreadValues({
807
+ name: "keywords"
808
+ }, getFieldInfo("keywords", config.fieldOverrides)), {
809
+ title: "Keywords",
810
+ type: "array",
811
+ of: [{ type: "string" }],
812
+ description: "Add relevant keywords for this page. These keywords will be used for SEO purposes.",
813
+ hidden: getFieldHiddenFunction("keywords", config)
814
+ })),
815
+ sanity.defineField(chunkS367Y35J_cjs.__spreadProps(chunkS367Y35J_cjs.__spreadValues({
816
+ name: "canonicalUrl"
817
+ }, getFieldInfo("canonicalUrl", config.fieldOverrides)), {
818
+ title: "Canonical URL",
819
+ type: "url",
820
+ description: "Specify the canonical URL for this page. This helps prevent duplicate content issues by indicating the preferred version of a page.",
821
+ hidden: getFieldHiddenFunction("canonicalUrl", config)
822
+ })),
823
+ sanity.defineField(chunkS367Y35J_cjs.__spreadProps(chunkS367Y35J_cjs.__spreadValues({
824
+ name: "metaAttributes"
825
+ }, getFieldInfo("metaAttributes", config.fieldOverrides)), {
826
+ type: "array",
827
+ of: [{ type: "metaAttribute" }],
828
+ hidden: getFieldHiddenFunction("metaAttributes", config)
829
+ }))
830
+ ]
831
+ });
832
+ }
769
833
  var metaAttribute_default = sanity.defineType({
770
834
  name: "metaAttribute",
771
835
  title: "Meta Attribute",
@@ -866,6 +930,8 @@ function types(config = {}) {
866
930
  return [
867
931
  seoFieldsSchema(config),
868
932
  // pass config here
933
+ baseMeta(config),
934
+ // pass config here
869
935
  openGraph(config),
870
936
  // pass config here
871
937
  twitter(config),
@@ -1062,6 +1128,7 @@ function createSeoHealthPane(optionsOrS, optionsWhenS) {
1062
1128
  var src_default = plugin_default;
1063
1129
 
1064
1130
  exports.allSchemas = types;
1131
+ exports.baseMetaSchema = baseMeta;
1065
1132
  exports.createSeoHealthPane = createSeoHealthPane;
1066
1133
  exports.default = src_default;
1067
1134
  exports.metaAttributeSchema = metaAttribute_default;