nuxt-seo-utils 8.2.0 → 8.3.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.
- package/dist/cli.mjs +1 -1
- package/dist/devtools/lib/seo-utils/rpc.ts +3 -0
- package/dist/devtools/lib/seo-utils/state.ts +35 -0
- package/dist/devtools/lib/seo-utils/tools.ts +98 -0
- package/dist/devtools/nuxt.config.ts +3 -0
- package/dist/devtools/pages/seo-utils/debug.vue +50 -0
- package/dist/devtools/pages/seo-utils/docs.vue +3 -0
- package/dist/devtools/pages/seo-utils/identity.vue +1168 -0
- package/dist/devtools/pages/seo-utils/index.vue +609 -0
- package/dist/devtools/pages/seo-utils/social.vue +515 -0
- package/dist/devtools/pages/seo-utils.vue +64 -0
- package/dist/module.json +1 -1
- package/dist/module.mjs +2 -2
- package/dist/runtime/app/composables/polyfills.js +1 -1
- package/dist/runtime/app/composables/useBreadcrumbItems.js +3 -3
- package/dist/runtime/app/composables/useFallbackTitle.js +1 -1
- package/dist/runtime/app/composables/useShareLinks.js +2 -2
- package/dist/runtime/app/logic/applyDefaults.js +2 -2
- package/dist/runtime/app/plugins/1.absoluteImageUrls.server.js +1 -1
- package/dist/runtime/app/plugins/siteConfig.js +1 -1
- package/dist/runtime/server/middleware/redirectCanonical.js +1 -1
- package/dist/runtime/server/middleware/resolveImagesInPagesDir.js +1 -1
- package/dist/runtime/server/routes/__nuxt-seo-utils/debug.d.ts +1 -1
- package/dist/runtime/server/routes/__nuxt-seo-utils/debug.js +1 -1
- package/package.json +32 -31
- package/dist/devtools/200.html +0 -1
- package/dist/devtools/404.html +0 -1
- package/dist/devtools/_nuxt/BEw_EXq1.js +0 -14
- package/dist/devtools/_nuxt/BgCgKrEE.js +0 -1
- package/dist/devtools/_nuxt/C4gkMyix.js +0 -1
- package/dist/devtools/_nuxt/CQ4Jy7Nm.js +0 -1
- package/dist/devtools/_nuxt/DcgcSEa-.js +0 -33
- package/dist/devtools/_nuxt/DeIiaCYF.js +0 -1
- package/dist/devtools/_nuxt/DevtoolsMetric.DabK8i8g.css +0 -1
- package/dist/devtools/_nuxt/DfZjB7w2.js +0 -1
- package/dist/devtools/_nuxt/DjEWf-n1.js +0 -1
- package/dist/devtools/_nuxt/builds/latest.json +0 -1
- package/dist/devtools/_nuxt/builds/meta/21c3fe25-8926-44ca-9d37-f478243d148a.json +0 -1
- package/dist/devtools/_nuxt/debug.B9T5jmI-.css +0 -1
- package/dist/devtools/_nuxt/entry.aDw8hoj_.css +0 -1
- package/dist/devtools/_nuxt/fira-code.Bc8wnsZt.woff2 +0 -0
- package/dist/devtools/_nuxt/hubot-sans.DLGyhQVu.woff2 +0 -0
- package/dist/devtools/_nuxt/identity.Dl98KbLG.css +0 -1
- package/dist/devtools/_nuxt/index.BrQ8jYVK.css +0 -1
- package/dist/devtools/_nuxt/social.DrJTEVxX.css +0 -1
- package/dist/devtools/_nuxt/tools.DM91U8p4.css +0 -1
- package/dist/devtools/debug/index.html +0 -1
- package/dist/devtools/docs/index.html +0 -1
- package/dist/devtools/identity/index.html +0 -1
- package/dist/devtools/index.html +0 -1
- package/dist/devtools/social/index.html +0 -1
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { useSiteConfig } from "#site-config/app/composables/useSiteConfig";
|
|
2
1
|
import { injectHead } from "@unhead/vue";
|
|
3
2
|
import { defineNuxtPlugin, useRuntimeConfig } from "nuxt/app";
|
|
3
|
+
import { useSiteConfig } from "#site-config/app/composables/useSiteConfig";
|
|
4
4
|
export default defineNuxtPlugin(() => {
|
|
5
5
|
const head = injectHead();
|
|
6
6
|
if (!head)
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { getSiteConfig } from "#site-config/server/composables/getSiteConfig";
|
|
2
1
|
import { defineEventHandler, getRequestHost, sendRedirect, setHeader } from "h3";
|
|
3
2
|
import { joinURL } from "ufo";
|
|
3
|
+
import { getSiteConfig } from "#site-config/server/composables/getSiteConfig";
|
|
4
4
|
export default defineEventHandler((e) => {
|
|
5
5
|
if (import.meta.prerender) {
|
|
6
6
|
return;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import fs from "node:fs";
|
|
2
|
-
import { fileMapping } from "#seo-utils-virtual/pageDirImages";
|
|
3
2
|
import { defineEventHandler, setHeader } from "h3";
|
|
4
3
|
import { parseURL } from "ufo";
|
|
4
|
+
import { fileMapping } from "#seo-utils-virtual/pageDirImages";
|
|
5
5
|
export default defineEventHandler(async (e) => {
|
|
6
6
|
const path = parseURL(e.path).pathname;
|
|
7
7
|
if (fileMapping[path]) {
|
|
@@ -13,6 +13,6 @@ declare const _default: import("h3").EventHandler<import("h3").EventHandlerReque
|
|
|
13
13
|
twitter: any;
|
|
14
14
|
};
|
|
15
15
|
headConfig: any;
|
|
16
|
-
path: string | number | true | import("ufo").QueryValue[]
|
|
16
|
+
path: string | number | true | Record<string, any> | import("ufo").QueryValue[];
|
|
17
17
|
}>;
|
|
18
18
|
export default _default;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { getSiteConfig } from "#site-config/server/composables";
|
|
2
1
|
import { defineEventHandler, getQuery } from "h3";
|
|
3
2
|
import { useRuntimeConfig } from "nitropack/runtime";
|
|
3
|
+
import { getSiteConfig } from "#site-config/server/composables";
|
|
4
4
|
export default defineEventHandler((e) => {
|
|
5
5
|
const siteConfig = getSiteConfig(e);
|
|
6
6
|
const runtimeConfig = useRuntimeConfig(e);
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "nuxt-seo-utils",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "8.
|
|
4
|
+
"version": "8.3.0",
|
|
5
5
|
"description": "SEO utilities to improve your Nuxt sites discoverability and shareability",
|
|
6
6
|
"license": "MIT",
|
|
7
7
|
"funding": "https://github.com/sponsors/harlan-zw",
|
|
@@ -63,63 +63,64 @@
|
|
|
63
63
|
}
|
|
64
64
|
},
|
|
65
65
|
"dependencies": {
|
|
66
|
-
"@nuxt/kit": "^4.4.
|
|
66
|
+
"@nuxt/kit": "^4.4.8",
|
|
67
67
|
"@unhead/bundler": "^3.1.3",
|
|
68
68
|
"citty": "^0.2.2",
|
|
69
|
+
"consola": "^3.4.2",
|
|
69
70
|
"defu": "^6.1.7",
|
|
70
71
|
"escape-string-regexp": "^5.0.0",
|
|
71
72
|
"exsolve": "^1.0.8",
|
|
72
73
|
"image-size": "^2.0.2",
|
|
73
74
|
"nuxt-site-config": "^4.0.8",
|
|
74
|
-
"nuxtseo-
|
|
75
|
+
"nuxtseo-layer-devtools": "^5.2.3",
|
|
76
|
+
"nuxtseo-shared": "^5.2.3",
|
|
75
77
|
"pathe": "^2.0.3",
|
|
76
|
-
"pkg-types": "^2.3.
|
|
78
|
+
"pkg-types": "^2.3.1",
|
|
77
79
|
"scule": "^1.3.0",
|
|
78
|
-
"tinyglobby": "^0.2.
|
|
79
|
-
"ufo": "^1.6.
|
|
80
|
+
"tinyglobby": "^0.2.17",
|
|
81
|
+
"ufo": "^1.6.4"
|
|
80
82
|
},
|
|
81
83
|
"optionalDependencies": {
|
|
82
|
-
"sharp": "^0.
|
|
84
|
+
"sharp": "^0.35.0"
|
|
83
85
|
},
|
|
84
86
|
"devDependencies": {
|
|
85
|
-
"@antfu/eslint-config": "^
|
|
86
|
-
"@nuxt/devtools-kit": "4.0.0-alpha.
|
|
87
|
+
"@antfu/eslint-config": "^9.0.0",
|
|
88
|
+
"@nuxt/devtools-kit": "4.0.0-alpha.7",
|
|
87
89
|
"@nuxt/module-builder": "^1.0.2",
|
|
88
|
-
"@nuxt/schema": "^4.4.
|
|
89
|
-
"@nuxt/test-utils": "^4.0.
|
|
90
|
-
"@nuxt/ui": "^4.
|
|
91
|
-
"@nuxtjs/i18n": "^10.
|
|
92
|
-
"@types/node": "^25.
|
|
90
|
+
"@nuxt/schema": "^4.4.8",
|
|
91
|
+
"@nuxt/test-utils": "^4.0.3",
|
|
92
|
+
"@nuxt/ui": "^4.8.2",
|
|
93
|
+
"@nuxtjs/i18n": "^10.4.0",
|
|
94
|
+
"@types/node": "^25.9.3",
|
|
93
95
|
"@unhead/vue": "^3.1.3",
|
|
94
|
-
"@vue/test-utils": "^2.4.
|
|
95
|
-
"bumpp": "^11.0
|
|
96
|
+
"@vue/test-utils": "^2.4.11",
|
|
97
|
+
"bumpp": "^11.1.0",
|
|
96
98
|
"case-police": "^2.2.1",
|
|
97
99
|
"cheerio": "^1.2.0",
|
|
98
|
-
"eslint": "^10.
|
|
99
|
-
"eslint-plugin-harlanzw": "^0.
|
|
100
|
-
"happy-dom": "^20.
|
|
101
|
-
"lint-staged": "^
|
|
100
|
+
"eslint": "^10.4.1",
|
|
101
|
+
"eslint-plugin-harlanzw": "^0.17.0",
|
|
102
|
+
"happy-dom": "^20.10.2",
|
|
103
|
+
"lint-staged": "^17.0.7",
|
|
102
104
|
"markdownlint-cli": "^0.48.0",
|
|
103
|
-
"nuxt": "^4.4.
|
|
104
|
-
"nuxt-security": "^2.
|
|
105
|
-
"
|
|
106
|
-
"
|
|
107
|
-
"
|
|
108
|
-
"semver": "^7.7.4",
|
|
105
|
+
"nuxt": "^4.4.8",
|
|
106
|
+
"nuxt-security": "^2.6.0",
|
|
107
|
+
"playwright-core": "^1.60.0",
|
|
108
|
+
"sass": "^1.100.0",
|
|
109
|
+
"semver": "^7.8.4",
|
|
109
110
|
"sirv": "^3.0.2",
|
|
110
111
|
"typescript": "^6.0.3",
|
|
111
112
|
"ultrahtml": "^1.6.0",
|
|
112
113
|
"unbuild": "^3.6.1",
|
|
113
114
|
"unhead": "^3.1.3",
|
|
114
|
-
"vitest": "^4.1.
|
|
115
|
-
"vue
|
|
115
|
+
"vitest": "^4.1.8",
|
|
116
|
+
"vue": "^3.5.35",
|
|
117
|
+
"vue-tsc": "^3.3.4"
|
|
116
118
|
},
|
|
117
119
|
"scripts": {
|
|
118
|
-
"client:build": "
|
|
120
|
+
"client:build": "node -e \"require('fs').cpSync('devtools','dist/devtools',{recursive:true})\"",
|
|
119
121
|
"build": "nuxt-module-build build --stub && nuxt-module-build prepare && nuxt-module-build build && npm run client:build",
|
|
120
122
|
"dev": "nuxt dev playground",
|
|
121
|
-
"
|
|
122
|
-
"dev:prepare": "nuxt-module-build build --stub && nuxt-module-build prepare && nuxt prepare playground && pnpm prepare:fixtures",
|
|
123
|
+
"dev:prepare": "nuxt-module-build build --stub && nuxt-module-build prepare && nuxt prepare playground && pnpm prepare:fixtures && pnpm run client:build",
|
|
123
124
|
"stub": "nuxt-module-build build --stub && nuxt-module-build prepare",
|
|
124
125
|
"lint": "eslint .",
|
|
125
126
|
"lint:fix": "eslint . --fix",
|
package/dist/devtools/200.html
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
<!DOCTYPE html><html><head><meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1"><link rel="stylesheet" href="/__nuxt-seo-utils/_nuxt/entry.aDw8hoj_.css" crossorigin><link rel="modulepreload" as="script" crossorigin href="/__nuxt-seo-utils/_nuxt/DcgcSEa-.js"><script type="module" src="/__nuxt-seo-utils/_nuxt/DcgcSEa-.js" crossorigin></script><script>"use strict";(()=>{const t=window,e=document.documentElement,c=["dark","light"],n=getStorageValue("localStorage","nuxt-color-mode")||"system";let i=n==="system"?u():n;const r=e.getAttribute("data-color-mode-forced");r&&(i=r),l(i),t["__NUXT_COLOR_MODE__"]={preference:n,value:i,getColorScheme:u,addColorScheme:l,removeColorScheme:d};function l(o){const s=""+o+"",a="";e.classList?e.classList.add(s):e.className+=" "+s,a&&e.setAttribute("data-"+a,o)}function d(o){const s=""+o+"",a="";e.classList?e.classList.remove(s):e.className=e.className.replace(new RegExp(s,"g"),""),a&&e.removeAttribute("data-"+a)}function f(o){return t.matchMedia("(prefers-color-scheme"+o+")")}function u(){if(t.matchMedia&&f("").media!=="not all"){for(const o of c)if(f(":"+o).matches)return o}return"light"}})();function getStorageValue(t,e){switch(t){case"localStorage":return window.localStorage.getItem(e);case"sessionStorage":return window.sessionStorage.getItem(e);case"cookie":return getCookie(e);default:return null}}function getCookie(t){const c=("; "+window.document.cookie).split("; "+t+"=");if(c.length===2)return c.pop()?.split(";").shift()}</script></head><body><div id="__nuxt" class="isolate"></div><div id="teleports"></div><script>window.__NUXT_SITE_CONFIG__={_priority:{env:-15},env:"production"}</script><script>window.__NUXT__={};window.__NUXT__.config={public:{i18n:{baseUrl:"",defaultLocale:"",rootRedirect:"",redirectStatusCode:302,skipSettingLocaleOnNavigate:false,locales:[],detectBrowserLanguage:{alwaysRedirect:false,cookieCrossOrigin:false,cookieDomain:"",cookieKey:"i18n_redirected",cookieSecure:false,fallbackLocale:"",redirectOn:"root",useCookie:true},experimental:{localeDetector:"",typedPages:true,typedOptionsAndMessages:false,alternateLinkCanonicalQueries:true,devCache:false,cacheLifetime:"",stripMessagesPayload:false,preload:false,strictSeo:false,nitroContextDetection:true,httpCacheDuration:10},domainLocales:{}}},app:{baseURL:"/__nuxt-seo-utils",buildId:"21c3fe25-8926-44ca-9d37-f478243d148a",buildAssetsDir:"/_nuxt/",cdnURL:""}}</script><script type="application/json" data-nuxt-data="nuxt-app" data-ssr="false" id="__NUXT_DATA__">[{"prerenderedAt":1,"serverRendered":2},1780939273270,false]</script></body></html>
|
package/dist/devtools/404.html
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
<!DOCTYPE html><html><head><meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1"><link rel="stylesheet" href="/__nuxt-seo-utils/_nuxt/entry.aDw8hoj_.css" crossorigin><link rel="modulepreload" as="script" crossorigin href="/__nuxt-seo-utils/_nuxt/DcgcSEa-.js"><script type="module" src="/__nuxt-seo-utils/_nuxt/DcgcSEa-.js" crossorigin></script><script>"use strict";(()=>{const t=window,e=document.documentElement,c=["dark","light"],n=getStorageValue("localStorage","nuxt-color-mode")||"system";let i=n==="system"?u():n;const r=e.getAttribute("data-color-mode-forced");r&&(i=r),l(i),t["__NUXT_COLOR_MODE__"]={preference:n,value:i,getColorScheme:u,addColorScheme:l,removeColorScheme:d};function l(o){const s=""+o+"",a="";e.classList?e.classList.add(s):e.className+=" "+s,a&&e.setAttribute("data-"+a,o)}function d(o){const s=""+o+"",a="";e.classList?e.classList.remove(s):e.className=e.className.replace(new RegExp(s,"g"),""),a&&e.removeAttribute("data-"+a)}function f(o){return t.matchMedia("(prefers-color-scheme"+o+")")}function u(){if(t.matchMedia&&f("").media!=="not all"){for(const o of c)if(f(":"+o).matches)return o}return"light"}})();function getStorageValue(t,e){switch(t){case"localStorage":return window.localStorage.getItem(e);case"sessionStorage":return window.sessionStorage.getItem(e);case"cookie":return getCookie(e);default:return null}}function getCookie(t){const c=("; "+window.document.cookie).split("; "+t+"=");if(c.length===2)return c.pop()?.split(";").shift()}</script></head><body><div id="__nuxt" class="isolate"></div><div id="teleports"></div><script>window.__NUXT_SITE_CONFIG__={_priority:{env:-15},env:"production"}</script><script>window.__NUXT__={};window.__NUXT__.config={public:{i18n:{baseUrl:"",defaultLocale:"",rootRedirect:"",redirectStatusCode:302,skipSettingLocaleOnNavigate:false,locales:[],detectBrowserLanguage:{alwaysRedirect:false,cookieCrossOrigin:false,cookieDomain:"",cookieKey:"i18n_redirected",cookieSecure:false,fallbackLocale:"",redirectOn:"root",useCookie:true},experimental:{localeDetector:"",typedPages:true,typedOptionsAndMessages:false,alternateLinkCanonicalQueries:true,devCache:false,cacheLifetime:"",stripMessagesPayload:false,preload:false,strictSeo:false,nitroContextDetection:true,httpCacheDuration:10},domainLocales:{}}},app:{baseURL:"/__nuxt-seo-utils",buildId:"21c3fe25-8926-44ca-9d37-f478243d148a",buildAssetsDir:"/_nuxt/",cdnURL:""}}</script><script type="application/json" data-nuxt-data="nuxt-app" data-ssr="false" id="__NUXT_DATA__">[{"prerenderedAt":1,"serverRendered":2},1780939273270,false]</script></body></html>
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
import{d as H,u as J,s as j,q as A,v as W,x as K,o,g as i,c as P,y as Q,w as x,b as r,e as X,F as f,i as e,n as B,z as p,j as a,A as Y,m as S,k as h,a as E,p as Z,B as ee,r as G,f as v,l as se}from"./DcgcSEa-.js";import{_ as te,a as oe,p as ae}from"./C4gkMyix.js";import{_ as ne}from"./BgCgKrEE.js";const ie={class:"space-y-5 stagger-children"},le={class:"id-hero__left"},re={class:"id-score-ring"},ce={viewBox:"0 0 36 36",class:"id-score-ring__svg"},de=["stroke-dasharray"],ue={class:"id-score-ring__text"},me={class:"font-medium text-sm"},_e={class:"text-xs text-[var(--color-text-muted)]"},pe={class:"id-browser-tab"},ge={class:"id-browser-tab__chrome"},ve={class:"id-browser-tab__tab"},he=["src"],fe={class:"id-browser-tab__title"},xe={class:"id-browser-tab__bar"},be={class:"id-browser-tab__url"},ye={class:"id-group-header"},ke={class:"id-group-count"},we={class:"text-xs text-[var(--color-text-muted)] mb-3"},Ce={class:"id-icon-grid"},Se={class:"id-icon-preview"},Te=["src","alt"],ze={class:"id-icon-meta"},$e=["href"],Pe={class:"id-icon-badges"},Ie={key:0,class:"id-badge"},Ae={key:1,class:"id-badge"},Be={key:2,class:"id-badge id-badge--accent"},Ge={key:1,class:"id-empty panel-grids"},Ne={class:"id-empty__inner"},De={class:"id-empty__icon-ring"},Le={class:"id-terminal"},Me={class:"id-terminal__body"},Ue={class:"id-gen-files"},Ve={class:"id-gen-name"},We={class:"id-gen-size"},Ee={class:"id-gen-desc"},Fe={class:"hint-callout mt-4 w-full"},Re={key:0,class:"mb-5"},qe={class:"id-color-scheme-row"},Oe={class:"text-sm font-mono font-medium"},He={key:1},Je={class:"id-color-grid"},je={class:"id-color-card__meta"},Ke={class:"id-color-card__value"},Qe={key:1,class:"text-[0.625rem] text-[var(--color-text-subtle)] block mt-0.5 font-mono"},Xe={key:1,class:"hint-callout"},Ye={class:"id-guide-grid"},Ze={class:"id-guide-card"},es={class:"id-guide-card__icon"},ss={class:"id-guide-card"},ts={class:"id-guide-card__icon"},os={class:"id-file-list"},as={class:"id-file-name"},ns={class:"id-file-desc"},is={class:"id-guide-card"},ls={class:"id-guide-card__icon"},rs={class:"id-terminal__body !mt-auto !rounded-[var(--radius-sm)]"},F="npx nuxt-seo-utils icons --source <your-logo.svg>",cs=H({__name:"identity",setup(ds){const{copy:N}=J(),T=G(!1),b=G(null),d=G(null),g=v(()=>A.value?.siteConfig||null),y=v(()=>d.value?.icons||[]),D=v(()=>y.value.length>0),R=v(()=>{const n={};return y.value.forEach(s=>{const m=s.rel||"icon";n[m]||(n[m]=[]),n[m].push(s)}),n}),L={icon:{label:"Favicon",description:"Browser tab icons used across the site"},"apple-touch-icon":{label:"Apple Touch Icon",description:"High resolution icon for iOS home screen"}},k=v(()=>{if(!g.value||!d.value)return{present:0,total:0};const n=[!!g.value.name,!!g.value.url&&g.value.url!=="http://localhost:3000",!!g.value.description,D.value,d.value.ogImages.length>0,d.value.themeColors.length>0];return{present:n.filter(Boolean).length,total:n.length}}),z=v(()=>{const{present:n,total:s}=k.value;return s>0?Math.round(n/s*100):0}),M=v(()=>{const n=z.value;return n>=80?"success":(n>=50,"warning")}),U=v(()=>{const n=y.value.find(m=>m.href?.includes("favicon.ico"));return n?n.href:y.value.find(m=>m.rel==="icon")?.href||null}),q=v(()=>{if(!g.value?.url)return"localhost:3000";try{return new URL(g.value.url).hostname}catch{return g.value.url}});async function V(){T.value=!0,b.value=null,d.value=null;try{const n=window.parent?.location?.origin||window.location.origin,s=await fetch(`${n}${W.value}`,{headers:{Accept:"text/html"}});if(!s.ok)throw new Error(`HTTP ${s.status}`);const m=await s.text(),c=ae(m),$=[];c.allMeta.filter(t=>t.name==="theme-color").forEach(t=>{let _="default";const l=t.media||null;l?.includes("prefers-color-scheme: light")?_="light":l?.includes("prefers-color-scheme: dark")&&(_="dark"),$.push({color:t.content,media:l||void 0,context:_})});const u=[];c.ogTags["og:image"]&&u.push({url:c.ogTags["og:image"],width:c.ogTags["og:image:width"],height:c.ogTags["og:image:height"],alt:c.ogTags["og:image:alt"]});const w=[];c.twitterTags["twitter:image"]&&w.push({url:c.twitterTags["twitter:image"],width:c.twitterTags["twitter:image:width"],height:c.twitterTags["twitter:image:height"]});const C=c.allMeta.find(t=>t.name==="color-scheme"),I=c.iconLinks.map(t=>({...t,href:t.href.startsWith("http")?t.href:`${n}${t.href.startsWith("/")?"":"/"}${t.href}`}));d.value={icons:I,ogImages:u,twitterImages:w,themeColors:$,colorScheme:C?.content||null}}catch(n){b.value=n.message||"Failed to fetch page"}finally{T.value=!1}}j([()=>A.value,W,K],()=>{A.value&&V()},{immediate:!0});const O=[{name:"favicon.ico",size:"32x32",desc:"Browser tab"},{name:"icon-16x16.png",size:"16x16",desc:"Small favicon"},{name:"icon-32x32.png",size:"32x32",desc:"Standard favicon"},{name:"apple-touch-icon.png",size:"180x180",desc:"iOS home screen"},{name:"icon-192x192.png",size:"192x192",desc:"Android/PWA"},{name:"icon-512x512.png",size:"512x512",desc:"PWA splash"}];return(n,s)=>{const m=Q,c=X,$=te,u=Y,w=ne,C=Z,I=oe;return o(),i("div",ie,[T.value?(o(),P(m,{key:0})):b.value?(o(),P($,{key:1,error:b.value,title:"Failed to check page"},{default:x(()=>[r(c,{size:"sm",variant:"ghost",icon:"carbon:reset",label:"Retry",onClick:V})]),_:1},8,["error"])):d.value?(o(),i(f,{key:2},[e("div",{class:B(["id-hero",`id-hero--${M.value}`])},[e("div",le,[e("div",re,[(o(),i("svg",ce,[s[2]||(s[2]=e("circle",{cx:"18",cy:"18",r:"15.5",fill:"none",stroke:"var(--color-border-subtle)","stroke-width":"2.5"},null,-1)),e("circle",{cx:"18",cy:"18",r:"15.5",fill:"none",class:B(["id-score-ring__progress",`id-score-ring__progress--${M.value}`]),"stroke-width":"2.5","stroke-linecap":"round","stroke-dasharray":`${z.value*.974}, 100`,transform:"rotate(-90 18 18)"},null,10,de)])),e("span",ue,[p(a(k.value.present),1),s[3]||(s[3]=e("span",{class:"id-score-ring__sep"},"/",-1)),p(a(k.value.total),1)])]),e("div",null,[e("p",me,a(z.value>=80?"Identity configured":z.value>=50?"Partially configured":"Needs setup"),1),e("p",_e,a(k.value.present)+" of "+a(k.value.total)+" identity checks passing ",1)])]),e("div",pe,[e("div",ge,[s[4]||(s[4]=e("div",{class:"id-browser-tab__dots"},[e("span"),e("span"),e("span")],-1)),e("div",ve,[U.value?(o(),i("img",{key:0,src:U.value,class:"id-browser-tab__favicon",alt:""},null,8,he)):(o(),P(u,{key:1,name:"carbon:earth",class:"id-browser-tab__favicon-placeholder"})),e("span",fe,a(g.value?.name||"Untitled"),1)])]),e("div",xe,[r(u,{name:"carbon:locked",class:"id-browser-tab__lock"}),e("span",be,a(q.value),1)])])],2),r(C,{icon:"carbon:image",text:"Icons"},{actions:x(()=>[r(w,{value:y.value.length,label:"icons"},null,8,["value"])]),default:x(()=>[D.value?(o(!0),i(f,{key:0},S(R.value,(t,_)=>(o(),i("div",{key:_,class:"mb-5 last:mb-0"},[e("div",ye,[e("span",null,a(L[_]?.label||_),1),e("span",ke,a(t.length),1)]),e("p",we,a(L[_]?.description||""),1),e("div",Ce,[(o(!0),i(f,null,S(t,l=>(o(),i("div",{key:l.href,class:"id-icon-card"},[e("div",Se,[e("img",{src:l.href,alt:l.rel,class:"id-icon-img"},null,8,Te)]),e("div",ze,[e("a",{href:l.href,target:"_blank",class:"id-icon-href"},a(l.href),9,$e),e("div",Pe,[l.sizes?(o(),i("span",Ie,a(l.sizes),1)):h("",!0),l.type?(o(),i("span",Ae,a(l.type),1)):h("",!0),l.media?(o(),i("span",Be,a(l.media.includes("dark")?"Dark":l.media.includes("light")?"Light":l.media),1)):h("",!0)])])]))),128))])]))),128)):(o(),i("div",Ge,[e("div",Ne,[e("div",De,[r(u,{name:"carbon:image",class:"text-xl"})]),s[8]||(s[8]=e("p",{class:"font-medium text-sm mb-0.5"}," No favicons detected ",-1)),s[9]||(s[9]=e("p",{class:"text-xs text-[var(--color-text-muted)] mb-5 max-w-xs text-center"}," Generate all required icon variants from a single source image. ",-1)),e("div",Le,[s[6]||(s[6]=e("div",{class:"id-terminal__chrome"},[e("span",{class:"id-terminal__dot id-terminal__dot--red"}),e("span",{class:"id-terminal__dot id-terminal__dot--yellow"}),e("span",{class:"id-terminal__dot id-terminal__dot--green"}),e("span",{class:"id-terminal__label"},"Terminal")],-1)),e("div",Me,[s[5]||(s[5]=e("span",{class:"id-terminal__prompt"},"$",-1)),e("code",null,a(F)),r(c,{size:"xs",variant:"ghost",color:"neutral",icon:"carbon:copy",class:"id-terminal__copy",onClick:s[0]||(s[0]=t=>E(N)(F))})])]),e("div",Ue,[(o(),i(f,null,S(O,t=>e("div",{key:t.name,class:"id-gen-row"},[r(u,{name:"carbon:arrow-right",class:"id-gen-arrow"}),e("span",Ve,a(t.name),1),e("span",We,a(t.size),1),e("span",Ee,a(t.desc),1)])),64))]),e("div",Fe,[r(u,{name:"carbon:information",class:"hint-callout-icon text-sm mt-0.5 shrink-0"}),s[7]||(s[7]=e("div",{class:"text-xs text-[var(--color-text-muted)]"},[p(" Place a source image (SVG, PNG, or JPG) in your "),e("code",{class:"id-code"},"public/"),p(" directory, then run the command above. Requires "),e("code",{class:"id-code"},"sharp"),p(" as a dev dependency: "),e("pre",{class:"id-snippet !mt-2 !mb-0"},"pnpm add -D sharp")],-1))])])]))]),_:1}),r(C,{icon:"carbon:color-palette",text:"Theme Colors"},{actions:x(()=>[r(w,{value:d.value.themeColors.length,label:"colors"},null,8,["value"])]),default:x(()=>[d.value.themeColors.length||d.value.colorScheme?(o(),i(f,{key:0},[d.value.colorScheme?(o(),i("div",Re,[s[12]||(s[12]=e("div",{class:"id-group-header"},[e("span",null,"Color Scheme")],-1)),e("div",qe,[s[11]||(s[11]=e("div",{class:"id-color-scheme-swatch"},null,-1)),e("div",null,[e("span",Oe,a(d.value.colorScheme),1),s[10]||(s[10]=e("p",{class:"text-xs text-[var(--color-text-muted)]"}," Supported color schemes for system preferences ",-1))])])])):h("",!0),d.value.themeColors.length?(o(),i("div",He,[s[13]||(s[13]=e("div",{class:"id-group-header"},[e("span",null,"Theme Colors")],-1)),e("div",Je,[(o(!0),i(f,null,S(d.value.themeColors,(t,_)=>(o(),i("div",{key:_,class:"id-color-card"},[e("div",{class:"id-color-card__swatch",style:ee({backgroundColor:t.color})},null,4),e("div",je,[e("span",Ke,a(t.color),1),t.context!=="default"?(o(),i("span",{key:0,class:B(["id-badge",t.context==="dark"?"id-badge--dark":"id-badge--light"])},a(t.context),3)):h("",!0),t.media?(o(),i("span",Qe,a(t.media),1)):h("",!0)])]))),128))])])):h("",!0)],64)):(o(),i("div",Xe,[r(u,{name:"carbon:information",class:"hint-callout-icon text-sm mt-0.5 shrink-0"}),s[14]||(s[14]=e("div",{class:"text-xs text-[var(--color-text-muted)]"},[p(" No theme colors found. Add theme color meta tags in your "),e("code",{class:"id-code"},"nuxt.config.ts"),p(": "),e("pre",{class:"id-snippet !mt-2"},`app: {
|
|
2
|
-
head: {
|
|
3
|
-
meta: [
|
|
4
|
-
{ name: 'theme-color', content: '#00dc82' },
|
|
5
|
-
{ name: 'theme-color', content: '#18181b',
|
|
6
|
-
media: '(prefers-color-scheme: dark)' }
|
|
7
|
-
]
|
|
8
|
-
}
|
|
9
|
-
}`)],-1))]))]),_:1}),r(C,{icon:"carbon:book",text:"Configuration"},{default:x(()=>[e("div",Ye,[e("div",Ze,[e("div",es,[r(u,{name:"carbon:settings"})]),s[15]||(s[15]=e("h4",{class:"id-guide-card__title"}," Site Config ",-1)),s[16]||(s[16]=e("p",{class:"id-guide-card__desc"}," Core identity settings ",-1)),s[17]||(s[17]=e("pre",{class:"id-snippet !mt-auto"},`site: {
|
|
10
|
-
url: 'https://example.com',
|
|
11
|
-
name: 'My Site',
|
|
12
|
-
description: 'A description',
|
|
13
|
-
defaultLocale: 'en',
|
|
14
|
-
}`,-1))]),e("div",ss,[e("div",ts,[r(u,{name:"carbon:folder"})]),s[18]||(s[18]=e("h4",{class:"id-guide-card__title"}," Metadata Files ",-1)),s[19]||(s[19]=e("p",{class:"id-guide-card__desc"},[p(" Auto-detected from "),e("code",{class:"id-code"},"public/")],-1)),e("div",os,[(o(),i(f,null,S([{name:"favicon.ico",desc:"Tab icon"},{name:"icon-*.png",desc:"PNG variants"},{name:"apple-touch-icon.png",desc:"iOS icon"},{name:"og-image.png",desc:"Social share"},{name:"twitter-image.png",desc:"Twitter card"}],t=>e("div",{key:t.name,class:"id-file-row"},[r(u,{name:"carbon:document",class:"id-file-icon"}),e("span",as,a(t.name),1),e("span",ns,a(t.desc),1)])),64))])]),e("div",is,[e("div",ls,[r(u,{name:"carbon:terminal"})]),s[22]||(s[22]=e("h4",{class:"id-guide-card__title"}," Icon Generation ",-1)),s[23]||(s[23]=e("p",{class:"id-guide-card__desc"}," All variants from one source ",-1)),e("div",rs,[s[20]||(s[20]=e("span",{class:"id-terminal__prompt"},"$",-1)),s[21]||(s[21]=e("code",{class:"text-xs"},"npx nuxt-seo-utils icons --source logo.svg",-1)),r(c,{size:"xs",variant:"ghost",color:"neutral",icon:"carbon:copy",class:"id-terminal__copy",onClick:s[1]||(s[1]=t=>E(N)("npx nuxt-seo-utils icons --source logo.svg"))})]),s[24]||(s[24]=e("p",{class:"text-[0.6875rem] text-[var(--color-text-muted)] mt-2"},[p(" Requires "),e("code",{class:"id-code"},"sharp"),p(" dev dependency. Accepts SVG, PNG, JPG, or WebP. ")],-1))])])]),_:1})],64)):!T.value&&!b.value?(o(),P(I,{key:3,icon:"carbon:identification",title:"Waiting for connection",description:"Waiting for connection to host app..."})):h("",!0)])}}}),ps=se(cs,[["__scopeId","data-v-f0aa2872"]]);export{ps as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{d as n,o as a,g as t,n as l,c as i,A as r,k as o,i as m,j as c,l as d}from"./DcgcSEa-.js";const _={class:"devtools-metric-value"},v={key:1,class:"devtools-metric-label"},u=n({__name:"DevtoolsMetric",props:{label:{},value:{},icon:{},variant:{default:"default"}},setup(e){return(f,k)=>{const s=r;return a(),t("div",{class:l(["devtools-metric",`devtools-metric-${e.variant}`])},[e.icon?(a(),i(s,{key:0,name:e.icon,class:"devtools-metric-icon","aria-hidden":"true"},null,8,["name"])):o("",!0),m("span",_,c(e.value),1),e.label?(a(),t("span",v,c(e.label),1)):o("",!0)],2)}}}),h=Object.assign(d(u,[["__scopeId","data-v-ac8c8c5d"]]),{__name:"DevtoolsMetric"});export{h as _};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{d as E,o as a,g as i,i as d,b,A as C,j as p,k as m,h as A,l as k,n as $,z as w}from"./DcgcSEa-.js";const q={class:"devtools-error"},D={class:"devtools-error-icon-wrap"},M={class:"devtools-error-title"},R={key:0,class:"devtools-error-message"},N={key:1,class:"devtools-error-actions"},L=E({__name:"DevtoolsError",props:{icon:{default:"carbon:warning"},title:{default:"Something went wrong"},error:{}},setup(t){return(n,s)=>{const c=C;return a(),i("div",q,[d("div",D,[b(c,{name:t.icon,class:"devtools-error-icon"},null,8,["name"])]),d("p",M,p(t.title),1),t.error?(a(),i("p",R,p(typeof t.error=="string"?t.error:t.error.message),1)):m("",!0),n.$slots.default?(a(),i("div",N,[A(n.$slots,"default",{},void 0,!0)])):m("",!0)])}}}),P=Object.assign(k(L,[["__scopeId","data-v-730d244f"]]),{__name:"DevtoolsError"}),X={class:"devtools-empty"},H={class:"devtools-empty-title"},O={key:0,class:"devtools-empty-description"},x={key:1,class:"devtools-empty-actions"},j=E({__name:"DevtoolsEmptyState",props:{icon:{default:"carbon:search"},title:{},description:{},variant:{default:"default"}},setup(t){return(n,s)=>{const c=C;return a(),i("div",X,[d("div",{class:$(["devtools-empty-icon",`devtools-empty-icon-${t.variant}`])},[b(c,{name:t.icon,class:"w-8 h-8","aria-hidden":"true"},null,8,["name"])],2),d("h2",H,p(t.title),1),t.description||n.$slots.description?(a(),i("p",O,[A(n.$slots,"description",{},()=>[w(p(t.description),1)],!0)])):m("",!0),n.$slots.default?(a(),i("div",x,[A(n.$slots,"default",{},void 0,!0)])):m("",!0)])}}}),V=Object.assign(k(j,[["__scopeId","data-v-a9e7efe5"]]),{__name:"DevtoolsEmptyState"}),y={TITLE_MAX_CHARS:60,TITLE_WARN_CHARS:50,TITLE_MAX_PIXELS:580,DESC_MAX_CHARS:160,DESC_WARN_CHARS:150,DESC_MAX_PIXELS:920};function W(t,n=16){return Math.round(t.length*n*.55)}function B(t){const s=new DOMParser().parseFromString(t,"text/html"),c=s.querySelector("title")?.textContent?.trim()||"",I=s.querySelector('meta[name="description"]')?.getAttribute("content")?.trim()||"",T=s.querySelector('link[rel="canonical"]')?.getAttribute("href")||"",v={};s.querySelectorAll('meta[property^="og:"]').forEach(e=>{const o=e.getAttribute("property"),r=e.getAttribute("content");o&&r&&(v[o]=r)});const g={};s.querySelectorAll('meta[name^="twitter:"]').forEach(e=>{const o=e.getAttribute("name"),r=e.getAttribute("content");o&&r&&(g[o]=r)});const l=[];s.querySelectorAll("meta").forEach(e=>{const o=e.getAttribute("name"),r=e.getAttribute("property"),u=e.getAttribute("http-equiv"),h=e.getAttribute("content")||"",f=e.getAttribute("media")||void 0;o?l.push({name:o,content:h,type:"name",media:f}):r?l.push({name:r,content:h,type:"property",media:f}):u&&l.push({name:u,content:h,type:"http-equiv",media:f})});const _=[];s.querySelectorAll('script[type="application/ld+json"]').forEach(e=>{const o=e.textContent?.trim()||"";try{const r=JSON.parse(o),u=r["@type"]||(r["@graph"]?"Graph":"Unknown");_.push({type:u,data:r,raw:o})}catch{_.push({type:"Invalid JSON",data:null,raw:o})}});const S=[];return s.querySelectorAll('link[rel="icon"], link[rel="apple-touch-icon"], link[rel="shortcut icon"]').forEach(e=>{const o=e.getAttribute("href");o&&S.push({rel:e.getAttribute("rel")||"icon",href:o,type:e.getAttribute("type")||void 0,sizes:e.getAttribute("sizes")||void 0,media:e.getAttribute("media")||void 0})}),{title:c,description:I,ogTags:v,twitterTags:g,allMeta:l,canonical:T,schemas:_,iconLinks:S}}function U(t){return t>y.TITLE_MAX_CHARS?"error":t<30?"warning":"success"}function J(t){return t>y.DESC_MAX_CHARS?"error":t>y.DESC_WARN_CHARS||t<70?"warning":"success"}export{y as S,P as _,V as a,J as d,W as e,B as p,U as t};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{_ as D}from"./BgCgKrEE.js";import{u as B,d as g,o as a,c as m,_ as O,a as u,w as _,b as c,e as j,n as f,f as k,t as R,r as V,g as r,h as w,i as y,j as p,k as b,l as x,F as N,m as H,p as I,q as v}from"./DcgcSEa-.js";function L(o=2e3){const{copy:n,copied:t}=B({legacy:!0,copiedDuring:o});return{copy:n,copied:t}}const T=g({__name:"DevtoolsCopyButton",props:{text:{}},setup(o){const{copy:n,copied:t}=L();return(s,l)=>{const i=j,d=O;return a(),m(d,{text:u(t)?"Copied!":"Copy"},{default:_(()=>[c(i,{icon:u(t)?"carbon:checkmark":"carbon:copy","aria-label":u(t)?"Copied":"Copy to clipboard",class:f(u(t)?"text-[var(--seo-green)]":""),onClick:l[0]||(l[0]=e=>u(n)(o.text))},null,8,["icon","aria-label","class"])]),_:1},8,["text"])}}}),C=Object.assign(T,{__name:"DevtoolsCopyButton"}),h=V();function F(o,n){return k(()=>h.value&&h.value.codeToHtml(R(o)||"",{lang:n,themes:{light:"vitesse-light",dark:"vitesse-dark"}})||"")}const J=["innerHTML"],K=g({__name:"OCodeBlock",props:{code:{},lang:{},lines:{type:Boolean,default:!1},transformRendered:{type:Function}},setup(o){const n=k(()=>{const t=F(o.code,o.lang);return o.transformRendered?o.transformRendered(t.value||""):t.value});return(t,s)=>(a(),r("pre",{class:f(["code-block p-5",o.lines?"code-block-lines":""]),innerHTML:u(n)},null,10,J))}}),M=Object.assign(K,{__name:"OCodeBlock"}),U={class:"devtools-snippet"},q={key:0,class:"devtools-snippet-header"},z={class:"devtools-snippet-label"},A=g({__name:"DevtoolsSnippet",props:{label:{},code:{},lang:{default:"js"}},setup(o){return(n,t)=>{const s=C,l=M;return a(),r("div",U,[o.label||n.$slots.header?(a(),r("div",q,[w(n.$slots,"header",{},()=>[y("code",z,p(o.label),1)],!0),c(s,{text:o.code},null,8,["text"])])):b("",!0),c(l,{code:o.code,lang:o.lang,class:"devtools-snippet-block"},null,8,["code","lang"])])}}}),S=Object.assign(x(A,[["__scopeId","data-v-eb4eeaac"]]),{__name:"DevtoolsSnippet"}),E={class:"divide-y divide-[var(--color-border-subtle)]"},G={class:"devtools-kv-key"},P=["href"],Q=["href"],W=g({__name:"DevtoolsKeyValue",props:{items:{},striped:{type:Boolean,default:!1}},setup(o){const n=/^https?:\/\/\S+$/;function t(s){return!s.link&&!s.code&&typeof s.value=="string"&&n.test(s.value)}return(s,l)=>{const i=S,d=C;return a(),r("div",E,[(a(!0),r(N,null,H(o.items,e=>(a(),r("div",{key:e.key,class:f(["devtools-kv-row group",{"devtools-kv-striped":o.striped,"devtools-kv-stacked":!!e.code}])},[y("span",G,p(e.key),1),y("div",{class:f(["devtools-kv-value-wrap",{"devtools-kv-value-wrap-full":!!e.code}])},[e.link?(a(),r("a",{key:0,href:e.link,target:"_blank",rel:"noopener",class:"link-external text-sm"},p(e.value),9,P)):e.code&&e.value!==void 0&&e.value!==""?(a(),m(i,{key:1,code:String(e.value),lang:e.code,class:"devtools-kv-snippet"},null,8,["code","lang"])):t(e)?(a(),r("a",{key:2,href:String(e.value),target:"_blank",rel:"noopener",class:"link-external text-sm"},p(e.value),9,Q)):(a(),r("span",{key:3,class:f(["devtools-kv-value",{"font-mono":e.mono!==!1,"devtools-kv-true":e.value===!0,"devtools-kv-false":e.value===!1,"devtools-kv-empty":e.value===void 0||e.value===""}])},p(e.value===void 0||e.value===""?"(empty)":e.value),3)),!e.code&&e.copyable&&e.value!==void 0&&e.value!==""?(a(),m(d,{key:4,text:String(e.value),class:"opacity-0 group-hover:opacity-100 transition-opacity"},null,8,["text"])):b("",!0)],2)],2))),128))])}}}),X=Object.assign(x(W,[["__scopeId","data-v-b4c972e8"]]),{__name:"DevtoolsKeyValue"}),Y={class:"space-y-5 stagger-children"},oe=g({__name:"debug",setup(o){const n=k(()=>v.value?.runtimeConfig?Object.entries(v.value.runtimeConfig).map(([s,l])=>({key:s,value:typeof l=="object"?JSON.stringify(l):String(l),mono:!0})):[]),t=k(()=>v.value?.siteConfig?Object.entries(v.value.siteConfig).map(([s,l])=>({key:s,value:String(l),mono:!0})):[]);return(s,l)=>{const i=D,d=X,e=I,$=S;return a(),r("div",Y,[c(e,{icon:"carbon:settings",text:"Runtime Config"},{actions:_(()=>[c(i,{value:n.value.length,label:"keys"},null,8,["value"])]),default:_(()=>[c(d,{items:n.value,striped:""},null,8,["items"])]),_:1}),c(e,{icon:"carbon:earth",text:"Site Config"},{actions:_(()=>[c(i,{value:t.value.length,label:"keys"},null,8,["value"])]),default:_(()=>[c(d,{items:t.value,striped:""},null,8,["items"])]),_:1}),c(e,{icon:"carbon:code",text:"Raw JSON"},{default:_(()=>[c($,{code:JSON.stringify(u(v)||{},null,2),lang:"json",label:"debug.json"},null,8,["code"])]),_:1})])}}});export{oe as default};
|