@skspwork/config-doc 0.4.4 → 0.4.6

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@skspwork/config-doc",
3
- "version": "0.4.4",
3
+ "version": "0.4.6",
4
4
  "description": "Interactive documentation tool for JSON configuration files (appsettings.json)",
5
5
  "keywords": [
6
6
  "config",
@@ -43,7 +43,7 @@
43
43
  "scripts": {
44
44
  "build": "cd packages/web && npm install && npm run build && cd ../.. && node scripts/prepare-standalone.js",
45
45
  "prepublishOnly": "npm run build",
46
- "test:local": "npm pack && npm install -g skspwork-config-doc-0.4.4.tgz",
46
+ "test:local": "npm pack && npm install -g skspwork-config-doc-0.4.6.tgz",
47
47
  "unlink": "npm unlink -g @skspwork/config-doc"
48
48
  }
49
49
  }
@@ -1 +1 @@
1
- <!DOCTYPE html><!--config_doc_build--><html lang="ja"><head><meta charSet="utf-8"/><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="preload" href="/_next/static/media/797e433ab948586e-s.p.dbea232f.woff2" as="font" crossorigin="" type="font/woff2"/><link rel="preload" href="/_next/static/media/caa3a2e1cccd8315-s.p.853070df.woff2" as="font" crossorigin="" type="font/woff2"/><link rel="stylesheet" href="/_next/static/chunks/2014aa4b74125922.css" data-precedence="next"/><link rel="preload" as="script" fetchPriority="low" href="/_next/static/chunks/e8e7deb26267a701.js"/><script src="/_next/static/chunks/5e09075ff69944fe.js" async=""></script><script src="/_next/static/chunks/d5ac216659f25bca.js" async=""></script><script src="/_next/static/chunks/turbopack-76672a26fb0af68d.js" async=""></script><script src="/_next/static/chunks/74b0a4bcb4aa2cd1.js" async=""></script><script src="/_next/static/chunks/5edfc5b1a4e490d6.js" async=""></script><meta name="next-size-adjust" content=""/><title>ConfigDoc Web</title><meta name="description" content="設定ファイルのドキュメント化ツール"/><link rel="icon" href="/favicon.ico?favicon.0b3bf435.ico" sizes="256x256" type="image/x-icon"/><script src="/_next/static/chunks/a6dad97d9634a72d.js" noModule=""></script></head><body class="geist_a71539c9-module__T19VSG__variable geist_mono_8d43a2aa-module__8Li5zG__variable antialiased"><div hidden=""><!--$--><!--/$--></div><div class="min-h-screen bg-gradient-to-br from-blue-50 via-indigo-50 to-purple-50"><header class="bg-white/80 backdrop-blur-md border-b border-gray-200 shadow-sm sticky top-0 z-50"><div class="container mx-auto px-6 py-4 flex items-center justify-between"><div class="flex items-center gap-3"><div class="w-10 h-10 bg-gradient-to-br from-blue-600 to-purple-600 rounded-lg flex items-center justify-center shadow-lg"><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-file-text w-6 h-6 text-white" aria-hidden="true"><path d="M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z"></path><path d="M14 2v5a1 1 0 0 0 1 1h5"></path><path d="M10 9H8"></path><path d="M16 13H8"></path><path d="M16 17H8"></path></svg></div><div><h1 class="text-2xl font-bold bg-gradient-to-r from-blue-600 to-purple-600 bg-clip-text text-transparent">ConfigDoc</h1><p class="text-xs text-gray-500">Configuration Documentation Tool</p></div></div><button class="flex items-center gap-2 px-5 py-2.5 bg-gradient-to-r from-green-500 to-emerald-600 text-white rounded-lg hover:from-green-600 hover:to-emerald-700 shadow-md hover:shadow-lg transition-all duration-200 transform hover:scale-105" title="エクスポート"><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-download w-5 h-5" aria-hidden="true"><path d="M12 15V3"></path><path d="M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4"></path><path d="m7 10 5 5 5-5"></path></svg><span class="font-medium">エクスポート</span></button></div></header><main class="container mx-auto px-6 py-8"><div class="bg-white/90 backdrop-blur-sm rounded-2xl shadow-xl border border-gray-100 p-6 mb-8 hover:shadow-2xl transition-shadow duration-300"><div class="flex items-center justify-between mb-4"><div class="flex items-center gap-2"><div class="w-8 h-8 bg-gradient-to-br from-blue-500 to-blue-600 rounded-lg flex items-center justify-center"><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-folder-open w-5 h-5 text-white" aria-hidden="true"><path d="m6 14 1.5-2.9A2 2 0 0 1 9.24 10H20a2 2 0 0 1 1.94 2.5l-1.54 6a2 2 0 0 1-1.95 1.5H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h3.9a2 2 0 0 1 1.69.9l.81 1.2a2 2 0 0 0 1.67.9H18a2 2 0 0 1 2 2v2"></path></svg></div><h2 class="text-xl font-bold text-gray-800">設定ファイル</h2></div><button class="flex items-center gap-2 px-4 py-2 bg-gradient-to-r from-blue-500 to-blue-600 text-white rounded-lg hover:from-blue-600 hover:to-blue-700 shadow-md hover:shadow-lg transition-all duration-200 transform hover:scale-105"><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-folder-open w-5 h-5" aria-hidden="true"><path d="m6 14 1.5-2.9A2 2 0 0 1 9.24 10H20a2 2 0 0 1 1.94 2.5l-1.54 6a2 2 0 0 1-1.95 1.5H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h3.9a2 2 0 0 1 1.69.9l.81 1.2a2 2 0 0 0 1.67.9H18a2 2 0 0 1 2 2v2"></path></svg><span class="font-medium">ファイルを追加</span></button></div><div class="text-center py-12 bg-gradient-to-br from-gray-50 to-gray-100 rounded-xl border-2 border-dashed border-gray-300"><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-folder-open w-16 h-16 text-gray-400 mx-auto mb-3" aria-hidden="true"><path d="m6 14 1.5-2.9A2 2 0 0 1 9.24 10H20a2 2 0 0 1 1.94 2.5l-1.54 6a2 2 0 0 1-1.95 1.5H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h3.9a2 2 0 0 1 1.69.9l.81 1.2a2 2 0 0 0 1.67.9H18a2 2 0 0 1 2 2v2"></path></svg><p class="text-sm text-gray-600 font-medium">設定ファイルを選択してください</p><p class="text-xs text-gray-500 mt-1">「ファイルを追加」ボタンから開始</p></div></div></main></div><!--$--><!--/$--><script src="/_next/static/chunks/e8e7deb26267a701.js" id="_R_" async=""></script><script>(self.__next_f=self.__next_f||[]).push([0])</script><script>self.__next_f.push([1,"1:\"$Sreact.fragment\"\n2:I[42402,[\"/_next/static/chunks/74b0a4bcb4aa2cd1.js\"],\"default\"]\n3:I[27115,[\"/_next/static/chunks/74b0a4bcb4aa2cd1.js\"],\"default\"]\n4:I[13914,[\"/_next/static/chunks/74b0a4bcb4aa2cd1.js\"],\"ClientPageRoot\"]\n5:I[52211,[\"/_next/static/chunks/5edfc5b1a4e490d6.js\"],\"default\"]\n8:I[98753,[\"/_next/static/chunks/74b0a4bcb4aa2cd1.js\"],\"OutletBoundary\"]\n9:\"$Sreact.suspense\"\nb:I[98753,[\"/_next/static/chunks/74b0a4bcb4aa2cd1.js\"],\"ViewportBoundary\"]\nd:I[98753,[\"/_next/static/chunks/74b0a4bcb4aa2cd1.js\"],\"MetadataBoundary\"]\nf:I[71118,[],\"default\"]\n:HL[\"/_next/static/chunks/2014aa4b74125922.css\",\"style\"]\n:HL[\"/_next/static/media/797e433ab948586e-s.p.dbea232f.woff2\",\"font\",{\"crossOrigin\":\"\",\"type\":\"font/woff2\"}]\n:HL[\"/_next/static/media/caa3a2e1cccd8315-s.p.853070df.woff2\",\"font\",{\"crossOrigin\":\"\",\"type\":\"font/woff2\"}]\n"])</script><script>self.__next_f.push([1,"0:{\"P\":null,\"b\":\"config-doc-build\",\"c\":[\"\",\"\"],\"q\":\"\",\"i\":false,\"f\":[[[\"\",{\"children\":[\"__PAGE__\",{}]},\"$undefined\",\"$undefined\",true],[[\"$\",\"$1\",\"c\",{\"children\":[[[\"$\",\"link\",\"0\",{\"rel\":\"stylesheet\",\"href\":\"/_next/static/chunks/2014aa4b74125922.css\",\"precedence\":\"next\",\"crossOrigin\":\"$undefined\",\"nonce\":\"$undefined\"}]],[\"$\",\"html\",null,{\"lang\":\"ja\",\"children\":[\"$\",\"body\",null,{\"className\":\"geist_a71539c9-module__T19VSG__variable geist_mono_8d43a2aa-module__8Li5zG__variable antialiased\",\"children\":[\"$\",\"$L2\",null,{\"parallelRouterKey\":\"children\",\"error\":\"$undefined\",\"errorStyles\":\"$undefined\",\"errorScripts\":\"$undefined\",\"template\":[\"$\",\"$L3\",null,{}],\"templateStyles\":\"$undefined\",\"templateScripts\":\"$undefined\",\"notFound\":[[[\"$\",\"title\",null,{\"children\":\"404: This page could not be found.\"}],[\"$\",\"div\",null,{\"style\":{\"fontFamily\":\"system-ui,\\\"Segoe UI\\\",Roboto,Helvetica,Arial,sans-serif,\\\"Apple Color Emoji\\\",\\\"Segoe UI Emoji\\\"\",\"height\":\"100vh\",\"textAlign\":\"center\",\"display\":\"flex\",\"flexDirection\":\"column\",\"alignItems\":\"center\",\"justifyContent\":\"center\"},\"children\":[\"$\",\"div\",null,{\"children\":[[\"$\",\"style\",null,{\"dangerouslySetInnerHTML\":{\"__html\":\"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}\"}}],[\"$\",\"h1\",null,{\"className\":\"next-error-h1\",\"style\":{\"display\":\"inline-block\",\"margin\":\"0 20px 0 0\",\"padding\":\"0 23px 0 0\",\"fontSize\":24,\"fontWeight\":500,\"verticalAlign\":\"top\",\"lineHeight\":\"49px\"},\"children\":404}],[\"$\",\"div\",null,{\"style\":{\"display\":\"inline-block\"},\"children\":[\"$\",\"h2\",null,{\"style\":{\"fontSize\":14,\"fontWeight\":400,\"lineHeight\":\"49px\",\"margin\":0},\"children\":\"This page could not be found.\"}]}]]}]}]],[]],\"forbidden\":\"$undefined\",\"unauthorized\":\"$undefined\"}]}]}]]}],{\"children\":[[\"$\",\"$1\",\"c\",{\"children\":[[\"$\",\"$L4\",null,{\"Component\":\"$5\",\"serverProvidedParams\":{\"searchParams\":{},\"params\":{},\"promises\":[\"$@6\",\"$@7\"]}}],[[\"$\",\"script\",\"script-0\",{\"src\":\"/_next/static/chunks/5edfc5b1a4e490d6.js\",\"async\":true,\"nonce\":\"$undefined\"}]],[\"$\",\"$L8\",null,{\"children\":[\"$\",\"$9\",null,{\"name\":\"Next.MetadataOutlet\",\"children\":\"$@a\"}]}]]}],{},null,false,false]},null,false,false],[\"$\",\"$1\",\"h\",{\"children\":[null,[\"$\",\"$Lb\",null,{\"children\":\"$Lc\"}],[\"$\",\"div\",null,{\"hidden\":true,\"children\":[\"$\",\"$Ld\",null,{\"children\":[\"$\",\"$9\",null,{\"name\":\"Next.Metadata\",\"children\":\"$Le\"}]}]}],[\"$\",\"meta\",null,{\"name\":\"next-size-adjust\",\"content\":\"\"}]]}],false]],\"m\":\"$undefined\",\"G\":[\"$f\",[]],\"S\":true}\n"])</script><script>self.__next_f.push([1,"6:{}\n7:\"$0:f:0:1:1:children:0:props:children:0:props:serverProvidedParams:params\"\n"])</script><script>self.__next_f.push([1,"c:[[\"$\",\"meta\",\"0\",{\"charSet\":\"utf-8\"}],[\"$\",\"meta\",\"1\",{\"name\":\"viewport\",\"content\":\"width=device-width, initial-scale=1\"}]]\n"])</script><script>self.__next_f.push([1,"10:I[75060,[\"/_next/static/chunks/74b0a4bcb4aa2cd1.js\"],\"IconMark\"]\na:null\ne:[[\"$\",\"title\",\"0\",{\"children\":\"ConfigDoc Web\"}],[\"$\",\"meta\",\"1\",{\"name\":\"description\",\"content\":\"設定ファイルのドキュメント化ツール\"}],[\"$\",\"link\",\"2\",{\"rel\":\"icon\",\"href\":\"/favicon.ico?favicon.0b3bf435.ico\",\"sizes\":\"256x256\",\"type\":\"image/x-icon\"}],[\"$\",\"$L10\",\"3\",{}]]\n"])</script></body></html>
1
+ <!DOCTYPE html><!--config_doc_build--><html lang="ja"><head><meta charSet="utf-8"/><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="preload" href="/_next/static/media/797e433ab948586e-s.p.dbea232f.woff2" as="font" crossorigin="" type="font/woff2"/><link rel="preload" href="/_next/static/media/caa3a2e1cccd8315-s.p.853070df.woff2" as="font" crossorigin="" type="font/woff2"/><link rel="stylesheet" href="/_next/static/chunks/2014aa4b74125922.css" data-precedence="next"/><link rel="preload" as="script" fetchPriority="low" href="/_next/static/chunks/e8e7deb26267a701.js"/><script src="/_next/static/chunks/5e09075ff69944fe.js" async=""></script><script src="/_next/static/chunks/d5ac216659f25bca.js" async=""></script><script src="/_next/static/chunks/turbopack-76672a26fb0af68d.js" async=""></script><script src="/_next/static/chunks/74b0a4bcb4aa2cd1.js" async=""></script><script src="/_next/static/chunks/e49ab4a9fc4760d2.js" async=""></script><meta name="next-size-adjust" content=""/><title>ConfigDoc Web</title><meta name="description" content="設定ファイルのドキュメント化ツール"/><link rel="icon" href="/favicon.ico?favicon.0b3bf435.ico" sizes="256x256" type="image/x-icon"/><script src="/_next/static/chunks/a6dad97d9634a72d.js" noModule=""></script></head><body class="geist_a71539c9-module__T19VSG__variable geist_mono_8d43a2aa-module__8Li5zG__variable antialiased"><div hidden=""><!--$--><!--/$--></div><div class="min-h-screen bg-gradient-to-br from-blue-50 via-indigo-50 to-purple-50"><header class="bg-white/80 backdrop-blur-md border-b border-gray-200 shadow-sm sticky top-0 z-50"><div class="container mx-auto px-6 py-4 flex items-center justify-between"><div class="flex items-center gap-3"><div class="w-10 h-10 bg-gradient-to-br from-blue-600 to-purple-600 rounded-lg flex items-center justify-center shadow-lg"><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-file-text w-6 h-6 text-white" aria-hidden="true"><path d="M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z"></path><path d="M14 2v5a1 1 0 0 0 1 1h5"></path><path d="M10 9H8"></path><path d="M16 13H8"></path><path d="M16 17H8"></path></svg></div><div><h1 class="text-2xl font-bold bg-gradient-to-r from-blue-600 to-purple-600 bg-clip-text text-transparent">ConfigDoc</h1><p class="text-xs text-gray-500">Configuration Documentation Tool</p></div></div><button class="flex items-center gap-2 px-5 py-2.5 bg-gradient-to-r from-green-500 to-emerald-600 text-white rounded-lg hover:from-green-600 hover:to-emerald-700 shadow-md hover:shadow-lg transition-all duration-200 transform hover:scale-105" title="エクスポート"><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-download w-5 h-5" aria-hidden="true"><path d="M12 15V3"></path><path d="M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4"></path><path d="m7 10 5 5 5-5"></path></svg><span class="font-medium">エクスポート</span></button></div></header><main class="container mx-auto px-6 py-8"><div class="bg-white/90 backdrop-blur-sm rounded-2xl shadow-xl border border-gray-100 p-6 mb-8 hover:shadow-2xl transition-shadow duration-300"><div class="flex items-center justify-between mb-4"><div class="flex items-center gap-2"><div class="w-8 h-8 bg-gradient-to-br from-blue-500 to-blue-600 rounded-lg flex items-center justify-center"><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-folder-open w-5 h-5 text-white" aria-hidden="true"><path d="m6 14 1.5-2.9A2 2 0 0 1 9.24 10H20a2 2 0 0 1 1.94 2.5l-1.54 6a2 2 0 0 1-1.95 1.5H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h3.9a2 2 0 0 1 1.69.9l.81 1.2a2 2 0 0 0 1.67.9H18a2 2 0 0 1 2 2v2"></path></svg></div><h2 class="text-xl font-bold text-gray-800">設定ファイル</h2></div><button class="flex items-center gap-2 px-4 py-2 bg-gradient-to-r from-blue-500 to-blue-600 text-white rounded-lg hover:from-blue-600 hover:to-blue-700 shadow-md hover:shadow-lg transition-all duration-200 transform hover:scale-105"><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-folder-open w-5 h-5" aria-hidden="true"><path d="m6 14 1.5-2.9A2 2 0 0 1 9.24 10H20a2 2 0 0 1 1.94 2.5l-1.54 6a2 2 0 0 1-1.95 1.5H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h3.9a2 2 0 0 1 1.69.9l.81 1.2a2 2 0 0 0 1.67.9H18a2 2 0 0 1 2 2v2"></path></svg><span class="font-medium">ファイルを追加</span></button></div><div class="text-center py-12 bg-gradient-to-br from-gray-50 to-gray-100 rounded-xl border-2 border-dashed border-gray-300"><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-folder-open w-16 h-16 text-gray-400 mx-auto mb-3" aria-hidden="true"><path d="m6 14 1.5-2.9A2 2 0 0 1 9.24 10H20a2 2 0 0 1 1.94 2.5l-1.54 6a2 2 0 0 1-1.95 1.5H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h3.9a2 2 0 0 1 1.69.9l.81 1.2a2 2 0 0 0 1.67.9H18a2 2 0 0 1 2 2v2"></path></svg><p class="text-sm text-gray-600 font-medium">設定ファイルを選択してください</p><p class="text-xs text-gray-500 mt-1">「ファイルを追加」ボタンから開始</p></div></div></main></div><!--$--><!--/$--><script src="/_next/static/chunks/e8e7deb26267a701.js" id="_R_" async=""></script><script>(self.__next_f=self.__next_f||[]).push([0])</script><script>self.__next_f.push([1,"1:\"$Sreact.fragment\"\n2:I[42402,[\"/_next/static/chunks/74b0a4bcb4aa2cd1.js\"],\"default\"]\n3:I[27115,[\"/_next/static/chunks/74b0a4bcb4aa2cd1.js\"],\"default\"]\n4:I[13914,[\"/_next/static/chunks/74b0a4bcb4aa2cd1.js\"],\"ClientPageRoot\"]\n5:I[52211,[\"/_next/static/chunks/e49ab4a9fc4760d2.js\"],\"default\"]\n8:I[98753,[\"/_next/static/chunks/74b0a4bcb4aa2cd1.js\"],\"OutletBoundary\"]\n9:\"$Sreact.suspense\"\nb:I[98753,[\"/_next/static/chunks/74b0a4bcb4aa2cd1.js\"],\"ViewportBoundary\"]\nd:I[98753,[\"/_next/static/chunks/74b0a4bcb4aa2cd1.js\"],\"MetadataBoundary\"]\nf:I[71118,[],\"default\"]\n:HL[\"/_next/static/chunks/2014aa4b74125922.css\",\"style\"]\n:HL[\"/_next/static/media/797e433ab948586e-s.p.dbea232f.woff2\",\"font\",{\"crossOrigin\":\"\",\"type\":\"font/woff2\"}]\n:HL[\"/_next/static/media/caa3a2e1cccd8315-s.p.853070df.woff2\",\"font\",{\"crossOrigin\":\"\",\"type\":\"font/woff2\"}]\n"])</script><script>self.__next_f.push([1,"0:{\"P\":null,\"b\":\"config-doc-build\",\"c\":[\"\",\"\"],\"q\":\"\",\"i\":false,\"f\":[[[\"\",{\"children\":[\"__PAGE__\",{}]},\"$undefined\",\"$undefined\",true],[[\"$\",\"$1\",\"c\",{\"children\":[[[\"$\",\"link\",\"0\",{\"rel\":\"stylesheet\",\"href\":\"/_next/static/chunks/2014aa4b74125922.css\",\"precedence\":\"next\",\"crossOrigin\":\"$undefined\",\"nonce\":\"$undefined\"}]],[\"$\",\"html\",null,{\"lang\":\"ja\",\"children\":[\"$\",\"body\",null,{\"className\":\"geist_a71539c9-module__T19VSG__variable geist_mono_8d43a2aa-module__8Li5zG__variable antialiased\",\"children\":[\"$\",\"$L2\",null,{\"parallelRouterKey\":\"children\",\"error\":\"$undefined\",\"errorStyles\":\"$undefined\",\"errorScripts\":\"$undefined\",\"template\":[\"$\",\"$L3\",null,{}],\"templateStyles\":\"$undefined\",\"templateScripts\":\"$undefined\",\"notFound\":[[[\"$\",\"title\",null,{\"children\":\"404: This page could not be found.\"}],[\"$\",\"div\",null,{\"style\":{\"fontFamily\":\"system-ui,\\\"Segoe UI\\\",Roboto,Helvetica,Arial,sans-serif,\\\"Apple Color Emoji\\\",\\\"Segoe UI Emoji\\\"\",\"height\":\"100vh\",\"textAlign\":\"center\",\"display\":\"flex\",\"flexDirection\":\"column\",\"alignItems\":\"center\",\"justifyContent\":\"center\"},\"children\":[\"$\",\"div\",null,{\"children\":[[\"$\",\"style\",null,{\"dangerouslySetInnerHTML\":{\"__html\":\"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}\"}}],[\"$\",\"h1\",null,{\"className\":\"next-error-h1\",\"style\":{\"display\":\"inline-block\",\"margin\":\"0 20px 0 0\",\"padding\":\"0 23px 0 0\",\"fontSize\":24,\"fontWeight\":500,\"verticalAlign\":\"top\",\"lineHeight\":\"49px\"},\"children\":404}],[\"$\",\"div\",null,{\"style\":{\"display\":\"inline-block\"},\"children\":[\"$\",\"h2\",null,{\"style\":{\"fontSize\":14,\"fontWeight\":400,\"lineHeight\":\"49px\",\"margin\":0},\"children\":\"This page could not be found.\"}]}]]}]}]],[]],\"forbidden\":\"$undefined\",\"unauthorized\":\"$undefined\"}]}]}]]}],{\"children\":[[\"$\",\"$1\",\"c\",{\"children\":[[\"$\",\"$L4\",null,{\"Component\":\"$5\",\"serverProvidedParams\":{\"searchParams\":{},\"params\":{},\"promises\":[\"$@6\",\"$@7\"]}}],[[\"$\",\"script\",\"script-0\",{\"src\":\"/_next/static/chunks/e49ab4a9fc4760d2.js\",\"async\":true,\"nonce\":\"$undefined\"}]],[\"$\",\"$L8\",null,{\"children\":[\"$\",\"$9\",null,{\"name\":\"Next.MetadataOutlet\",\"children\":\"$@a\"}]}]]}],{},null,false,false]},null,false,false],[\"$\",\"$1\",\"h\",{\"children\":[null,[\"$\",\"$Lb\",null,{\"children\":\"$Lc\"}],[\"$\",\"div\",null,{\"hidden\":true,\"children\":[\"$\",\"$Ld\",null,{\"children\":[\"$\",\"$9\",null,{\"name\":\"Next.Metadata\",\"children\":\"$Le\"}]}]}],[\"$\",\"meta\",null,{\"name\":\"next-size-adjust\",\"content\":\"\"}]]}],false]],\"m\":\"$undefined\",\"G\":[\"$f\",[]],\"S\":true}\n"])</script><script>self.__next_f.push([1,"6:{}\n7:\"$0:f:0:1:1:children:0:props:children:0:props:serverProvidedParams:params\"\n"])</script><script>self.__next_f.push([1,"c:[[\"$\",\"meta\",\"0\",{\"charSet\":\"utf-8\"}],[\"$\",\"meta\",\"1\",{\"name\":\"viewport\",\"content\":\"width=device-width, initial-scale=1\"}]]\n"])</script><script>self.__next_f.push([1,"10:I[75060,[\"/_next/static/chunks/74b0a4bcb4aa2cd1.js\"],\"IconMark\"]\na:null\ne:[[\"$\",\"title\",\"0\",{\"children\":\"ConfigDoc Web\"}],[\"$\",\"meta\",\"1\",{\"name\":\"description\",\"content\":\"設定ファイルのドキュメント化ツール\"}],[\"$\",\"link\",\"2\",{\"rel\":\"icon\",\"href\":\"/favicon.ico?favicon.0b3bf435.ico\",\"sizes\":\"256x256\",\"type\":\"image/x-icon\"}],[\"$\",\"$L10\",\"3\",{}]]\n"])</script></body></html>
@@ -2,7 +2,7 @@
2
2
  2:I[42402,["/_next/static/chunks/74b0a4bcb4aa2cd1.js"],"default"]
3
3
  3:I[27115,["/_next/static/chunks/74b0a4bcb4aa2cd1.js"],"default"]
4
4
  4:I[13914,["/_next/static/chunks/74b0a4bcb4aa2cd1.js"],"ClientPageRoot"]
5
- 5:I[52211,["/_next/static/chunks/5edfc5b1a4e490d6.js"],"default"]
5
+ 5:I[52211,["/_next/static/chunks/e49ab4a9fc4760d2.js"],"default"]
6
6
  8:I[98753,["/_next/static/chunks/74b0a4bcb4aa2cd1.js"],"OutletBoundary"]
7
7
  9:"$Sreact.suspense"
8
8
  b:I[98753,["/_next/static/chunks/74b0a4bcb4aa2cd1.js"],"ViewportBoundary"]
@@ -11,7 +11,7 @@ f:I[71118,[],"default"]
11
11
  :HL["/_next/static/chunks/2014aa4b74125922.css","style"]
12
12
  :HL["/_next/static/media/797e433ab948586e-s.p.dbea232f.woff2","font",{"crossOrigin":"","type":"font/woff2"}]
13
13
  :HL["/_next/static/media/caa3a2e1cccd8315-s.p.853070df.woff2","font",{"crossOrigin":"","type":"font/woff2"}]
14
- 0:{"P":null,"b":"config-doc-build","c":["",""],"q":"","i":false,"f":[[["",{"children":["__PAGE__",{}]},"$undefined","$undefined",true],[["$","$1","c",{"children":[[["$","link","0",{"rel":"stylesheet","href":"/_next/static/chunks/2014aa4b74125922.css","precedence":"next","crossOrigin":"$undefined","nonce":"$undefined"}]],["$","html",null,{"lang":"ja","children":["$","body",null,{"className":"geist_a71539c9-module__T19VSG__variable geist_mono_8d43a2aa-module__8Li5zG__variable antialiased","children":["$","$L2",null,{"parallelRouterKey":"children","error":"$undefined","errorStyles":"$undefined","errorScripts":"$undefined","template":["$","$L3",null,{}],"templateStyles":"$undefined","templateScripts":"$undefined","notFound":[[["$","title",null,{"children":"404: This page could not be found."}],["$","div",null,{"style":{"fontFamily":"system-ui,\"Segoe UI\",Roboto,Helvetica,Arial,sans-serif,\"Apple Color Emoji\",\"Segoe UI Emoji\"","height":"100vh","textAlign":"center","display":"flex","flexDirection":"column","alignItems":"center","justifyContent":"center"},"children":["$","div",null,{"children":[["$","style",null,{"dangerouslySetInnerHTML":{"__html":"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}"}}],["$","h1",null,{"className":"next-error-h1","style":{"display":"inline-block","margin":"0 20px 0 0","padding":"0 23px 0 0","fontSize":24,"fontWeight":500,"verticalAlign":"top","lineHeight":"49px"},"children":404}],["$","div",null,{"style":{"display":"inline-block"},"children":["$","h2",null,{"style":{"fontSize":14,"fontWeight":400,"lineHeight":"49px","margin":0},"children":"This page could not be found."}]}]]}]}]],[]],"forbidden":"$undefined","unauthorized":"$undefined"}]}]}]]}],{"children":[["$","$1","c",{"children":[["$","$L4",null,{"Component":"$5","serverProvidedParams":{"searchParams":{},"params":{},"promises":["$@6","$@7"]}}],[["$","script","script-0",{"src":"/_next/static/chunks/5edfc5b1a4e490d6.js","async":true,"nonce":"$undefined"}]],["$","$L8",null,{"children":["$","$9",null,{"name":"Next.MetadataOutlet","children":"$@a"}]}]]}],{},null,false,false]},null,false,false],["$","$1","h",{"children":[null,["$","$Lb",null,{"children":"$Lc"}],["$","div",null,{"hidden":true,"children":["$","$Ld",null,{"children":["$","$9",null,{"name":"Next.Metadata","children":"$Le"}]}]}],["$","meta",null,{"name":"next-size-adjust","content":""}]]}],false]],"m":"$undefined","G":["$f",[]],"S":true}
14
+ 0:{"P":null,"b":"config-doc-build","c":["",""],"q":"","i":false,"f":[[["",{"children":["__PAGE__",{}]},"$undefined","$undefined",true],[["$","$1","c",{"children":[[["$","link","0",{"rel":"stylesheet","href":"/_next/static/chunks/2014aa4b74125922.css","precedence":"next","crossOrigin":"$undefined","nonce":"$undefined"}]],["$","html",null,{"lang":"ja","children":["$","body",null,{"className":"geist_a71539c9-module__T19VSG__variable geist_mono_8d43a2aa-module__8Li5zG__variable antialiased","children":["$","$L2",null,{"parallelRouterKey":"children","error":"$undefined","errorStyles":"$undefined","errorScripts":"$undefined","template":["$","$L3",null,{}],"templateStyles":"$undefined","templateScripts":"$undefined","notFound":[[["$","title",null,{"children":"404: This page could not be found."}],["$","div",null,{"style":{"fontFamily":"system-ui,\"Segoe UI\",Roboto,Helvetica,Arial,sans-serif,\"Apple Color Emoji\",\"Segoe UI Emoji\"","height":"100vh","textAlign":"center","display":"flex","flexDirection":"column","alignItems":"center","justifyContent":"center"},"children":["$","div",null,{"children":[["$","style",null,{"dangerouslySetInnerHTML":{"__html":"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}"}}],["$","h1",null,{"className":"next-error-h1","style":{"display":"inline-block","margin":"0 20px 0 0","padding":"0 23px 0 0","fontSize":24,"fontWeight":500,"verticalAlign":"top","lineHeight":"49px"},"children":404}],["$","div",null,{"style":{"display":"inline-block"},"children":["$","h2",null,{"style":{"fontSize":14,"fontWeight":400,"lineHeight":"49px","margin":0},"children":"This page could not be found."}]}]]}]}]],[]],"forbidden":"$undefined","unauthorized":"$undefined"}]}]}]]}],{"children":[["$","$1","c",{"children":[["$","$L4",null,{"Component":"$5","serverProvidedParams":{"searchParams":{},"params":{},"promises":["$@6","$@7"]}}],[["$","script","script-0",{"src":"/_next/static/chunks/e49ab4a9fc4760d2.js","async":true,"nonce":"$undefined"}]],["$","$L8",null,{"children":["$","$9",null,{"name":"Next.MetadataOutlet","children":"$@a"}]}]]}],{},null,false,false]},null,false,false],["$","$1","h",{"children":[null,["$","$Lb",null,{"children":"$Lc"}],["$","div",null,{"hidden":true,"children":["$","$Ld",null,{"children":["$","$9",null,{"name":"Next.Metadata","children":"$Le"}]}]}],["$","meta",null,{"name":"next-size-adjust","content":""}]]}],false]],"m":"$undefined","G":["$f",[]],"S":true}
15
15
  6:{}
16
16
  7:"$0:f:0:1:1:children:0:props:children:0:props:serverProvidedParams:params"
17
17
  c:[["$","meta","0",{"charSet":"utf-8"}],["$","meta","1",{"name":"viewport","content":"width=device-width, initial-scale=1"}]]
@@ -1,9 +1,9 @@
1
1
  1:"$Sreact.fragment"
2
2
  2:I[13914,["/_next/static/chunks/74b0a4bcb4aa2cd1.js"],"ClientPageRoot"]
3
- 3:I[52211,["/_next/static/chunks/5edfc5b1a4e490d6.js"],"default"]
3
+ 3:I[52211,["/_next/static/chunks/e49ab4a9fc4760d2.js"],"default"]
4
4
  6:I[98753,["/_next/static/chunks/74b0a4bcb4aa2cd1.js"],"OutletBoundary"]
5
5
  7:"$Sreact.suspense"
6
- 0:{"buildId":"config-doc-build","rsc":["$","$1","c",{"children":[["$","$L2",null,{"Component":"$3","serverProvidedParams":{"searchParams":{},"params":{},"promises":["$@4","$@5"]}}],[["$","script","script-0",{"src":"/_next/static/chunks/5edfc5b1a4e490d6.js","async":true}]],["$","$L6",null,{"children":["$","$7",null,{"name":"Next.MetadataOutlet","children":"$@8"}]}]]}],"loading":null,"isPartial":false}
6
+ 0:{"buildId":"config-doc-build","rsc":["$","$1","c",{"children":[["$","$L2",null,{"Component":"$3","serverProvidedParams":{"searchParams":{},"params":{},"promises":["$@4","$@5"]}}],[["$","script","script-0",{"src":"/_next/static/chunks/e49ab4a9fc4760d2.js","async":true}]],["$","$L6",null,{"children":["$","$7",null,{"name":"Next.MetadataOutlet","children":"$@8"}]}]]}],"loading":null,"isPartial":false}
7
7
  4:{}
8
8
  5:"$0:rsc:props:children:0:props:serverProvidedParams:params"
9
9
  8:null
@@ -2,7 +2,7 @@
2
2
  2:I[42402,["/_next/static/chunks/74b0a4bcb4aa2cd1.js"],"default"]
3
3
  3:I[27115,["/_next/static/chunks/74b0a4bcb4aa2cd1.js"],"default"]
4
4
  4:I[13914,["/_next/static/chunks/74b0a4bcb4aa2cd1.js"],"ClientPageRoot"]
5
- 5:I[52211,["/_next/static/chunks/5edfc5b1a4e490d6.js"],"default"]
5
+ 5:I[52211,["/_next/static/chunks/e49ab4a9fc4760d2.js"],"default"]
6
6
  8:I[98753,["/_next/static/chunks/74b0a4bcb4aa2cd1.js"],"OutletBoundary"]
7
7
  9:"$Sreact.suspense"
8
8
  b:I[98753,["/_next/static/chunks/74b0a4bcb4aa2cd1.js"],"ViewportBoundary"]
@@ -11,7 +11,7 @@ f:I[71118,[],"default"]
11
11
  :HL["/_next/static/chunks/2014aa4b74125922.css","style"]
12
12
  :HL["/_next/static/media/797e433ab948586e-s.p.dbea232f.woff2","font",{"crossOrigin":"","type":"font/woff2"}]
13
13
  :HL["/_next/static/media/caa3a2e1cccd8315-s.p.853070df.woff2","font",{"crossOrigin":"","type":"font/woff2"}]
14
- 0:{"P":null,"b":"config-doc-build","c":["",""],"q":"","i":false,"f":[[["",{"children":["__PAGE__",{}]},"$undefined","$undefined",true],[["$","$1","c",{"children":[[["$","link","0",{"rel":"stylesheet","href":"/_next/static/chunks/2014aa4b74125922.css","precedence":"next","crossOrigin":"$undefined","nonce":"$undefined"}]],["$","html",null,{"lang":"ja","children":["$","body",null,{"className":"geist_a71539c9-module__T19VSG__variable geist_mono_8d43a2aa-module__8Li5zG__variable antialiased","children":["$","$L2",null,{"parallelRouterKey":"children","error":"$undefined","errorStyles":"$undefined","errorScripts":"$undefined","template":["$","$L3",null,{}],"templateStyles":"$undefined","templateScripts":"$undefined","notFound":[[["$","title",null,{"children":"404: This page could not be found."}],["$","div",null,{"style":{"fontFamily":"system-ui,\"Segoe UI\",Roboto,Helvetica,Arial,sans-serif,\"Apple Color Emoji\",\"Segoe UI Emoji\"","height":"100vh","textAlign":"center","display":"flex","flexDirection":"column","alignItems":"center","justifyContent":"center"},"children":["$","div",null,{"children":[["$","style",null,{"dangerouslySetInnerHTML":{"__html":"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}"}}],["$","h1",null,{"className":"next-error-h1","style":{"display":"inline-block","margin":"0 20px 0 0","padding":"0 23px 0 0","fontSize":24,"fontWeight":500,"verticalAlign":"top","lineHeight":"49px"},"children":404}],["$","div",null,{"style":{"display":"inline-block"},"children":["$","h2",null,{"style":{"fontSize":14,"fontWeight":400,"lineHeight":"49px","margin":0},"children":"This page could not be found."}]}]]}]}]],[]],"forbidden":"$undefined","unauthorized":"$undefined"}]}]}]]}],{"children":[["$","$1","c",{"children":[["$","$L4",null,{"Component":"$5","serverProvidedParams":{"searchParams":{},"params":{},"promises":["$@6","$@7"]}}],[["$","script","script-0",{"src":"/_next/static/chunks/5edfc5b1a4e490d6.js","async":true,"nonce":"$undefined"}]],["$","$L8",null,{"children":["$","$9",null,{"name":"Next.MetadataOutlet","children":"$@a"}]}]]}],{},null,false,false]},null,false,false],["$","$1","h",{"children":[null,["$","$Lb",null,{"children":"$Lc"}],["$","div",null,{"hidden":true,"children":["$","$Ld",null,{"children":["$","$9",null,{"name":"Next.Metadata","children":"$Le"}]}]}],["$","meta",null,{"name":"next-size-adjust","content":""}]]}],false]],"m":"$undefined","G":["$f",[]],"S":true}
14
+ 0:{"P":null,"b":"config-doc-build","c":["",""],"q":"","i":false,"f":[[["",{"children":["__PAGE__",{}]},"$undefined","$undefined",true],[["$","$1","c",{"children":[[["$","link","0",{"rel":"stylesheet","href":"/_next/static/chunks/2014aa4b74125922.css","precedence":"next","crossOrigin":"$undefined","nonce":"$undefined"}]],["$","html",null,{"lang":"ja","children":["$","body",null,{"className":"geist_a71539c9-module__T19VSG__variable geist_mono_8d43a2aa-module__8Li5zG__variable antialiased","children":["$","$L2",null,{"parallelRouterKey":"children","error":"$undefined","errorStyles":"$undefined","errorScripts":"$undefined","template":["$","$L3",null,{}],"templateStyles":"$undefined","templateScripts":"$undefined","notFound":[[["$","title",null,{"children":"404: This page could not be found."}],["$","div",null,{"style":{"fontFamily":"system-ui,\"Segoe UI\",Roboto,Helvetica,Arial,sans-serif,\"Apple Color Emoji\",\"Segoe UI Emoji\"","height":"100vh","textAlign":"center","display":"flex","flexDirection":"column","alignItems":"center","justifyContent":"center"},"children":["$","div",null,{"children":[["$","style",null,{"dangerouslySetInnerHTML":{"__html":"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}"}}],["$","h1",null,{"className":"next-error-h1","style":{"display":"inline-block","margin":"0 20px 0 0","padding":"0 23px 0 0","fontSize":24,"fontWeight":500,"verticalAlign":"top","lineHeight":"49px"},"children":404}],["$","div",null,{"style":{"display":"inline-block"},"children":["$","h2",null,{"style":{"fontSize":14,"fontWeight":400,"lineHeight":"49px","margin":0},"children":"This page could not be found."}]}]]}]}]],[]],"forbidden":"$undefined","unauthorized":"$undefined"}]}]}]]}],{"children":[["$","$1","c",{"children":[["$","$L4",null,{"Component":"$5","serverProvidedParams":{"searchParams":{},"params":{},"promises":["$@6","$@7"]}}],[["$","script","script-0",{"src":"/_next/static/chunks/e49ab4a9fc4760d2.js","async":true,"nonce":"$undefined"}]],["$","$L8",null,{"children":["$","$9",null,{"name":"Next.MetadataOutlet","children":"$@a"}]}]]}],{},null,false,false]},null,false,false],["$","$1","h",{"children":[null,["$","$Lb",null,{"children":"$Lc"}],["$","div",null,{"hidden":true,"children":["$","$Ld",null,{"children":["$","$9",null,{"name":"Next.Metadata","children":"$Le"}]}]}],["$","meta",null,{"name":"next-size-adjust","content":""}]]}],false]],"m":"$undefined","G":["$f",[]],"S":true}
15
15
  6:{}
16
16
  7:"$0:f:0:1:1:children:0:props:children:0:props:serverProvidedParams:params"
17
17
  c:[["$","meta","0",{"charSet":"utf-8"}],["$","meta","1",{"name":"viewport","content":"width=device-width, initial-scale=1"}]]
@@ -1,2 +1,2 @@
1
1
  globalThis.__RSC_MANIFEST = globalThis.__RSC_MANIFEST || {};
2
- globalThis.__RSC_MANIFEST["/page"] = {"moduleLoading":{"prefix":"","crossOrigin":null},"clientModules":{"[project]/packages/web/node_modules/next/dist/esm/client/components/layout-router.js <module evaluation>":{"id":42402,"name":"*","chunks":["/_next/static/chunks/74b0a4bcb4aa2cd1.js"],"async":false},"[project]/packages/web/node_modules/next/dist/esm/client/components/layout-router.js":{"id":42402,"name":"*","chunks":["/_next/static/chunks/74b0a4bcb4aa2cd1.js"],"async":false},"[project]/packages/web/node_modules/next/dist/esm/client/components/render-from-template-context.js <module evaluation>":{"id":27115,"name":"*","chunks":["/_next/static/chunks/74b0a4bcb4aa2cd1.js"],"async":false},"[project]/packages/web/node_modules/next/dist/esm/client/components/render-from-template-context.js":{"id":27115,"name":"*","chunks":["/_next/static/chunks/74b0a4bcb4aa2cd1.js"],"async":false},"[project]/packages/web/node_modules/next/dist/esm/client/components/client-page.js <module evaluation>":{"id":13914,"name":"*","chunks":["/_next/static/chunks/74b0a4bcb4aa2cd1.js"],"async":false},"[project]/packages/web/node_modules/next/dist/esm/client/components/client-page.js":{"id":13914,"name":"*","chunks":["/_next/static/chunks/74b0a4bcb4aa2cd1.js"],"async":false},"[project]/packages/web/node_modules/next/dist/esm/client/components/client-segment.js <module evaluation>":{"id":94947,"name":"*","chunks":["/_next/static/chunks/74b0a4bcb4aa2cd1.js"],"async":false},"[project]/packages/web/node_modules/next/dist/esm/client/components/client-segment.js":{"id":94947,"name":"*","chunks":["/_next/static/chunks/74b0a4bcb4aa2cd1.js"],"async":false},"[project]/packages/web/node_modules/next/dist/esm/client/components/http-access-fallback/error-boundary.js <module evaluation>":{"id":70775,"name":"*","chunks":["/_next/static/chunks/74b0a4bcb4aa2cd1.js"],"async":false},"[project]/packages/web/node_modules/next/dist/esm/client/components/http-access-fallback/error-boundary.js":{"id":70775,"name":"*","chunks":["/_next/static/chunks/74b0a4bcb4aa2cd1.js"],"async":false},"[project]/packages/web/node_modules/next/dist/esm/lib/metadata/generate/icon-mark.js <module evaluation>":{"id":75060,"name":"*","chunks":["/_next/static/chunks/74b0a4bcb4aa2cd1.js"],"async":false},"[project]/packages/web/node_modules/next/dist/esm/lib/metadata/generate/icon-mark.js":{"id":75060,"name":"*","chunks":["/_next/static/chunks/74b0a4bcb4aa2cd1.js"],"async":false},"[project]/packages/web/node_modules/next/dist/esm/lib/framework/boundary-components.js <module evaluation>":{"id":98753,"name":"*","chunks":["/_next/static/chunks/74b0a4bcb4aa2cd1.js"],"async":false},"[project]/packages/web/node_modules/next/dist/esm/lib/framework/boundary-components.js":{"id":98753,"name":"*","chunks":["/_next/static/chunks/74b0a4bcb4aa2cd1.js"],"async":false},"[project]/packages/web/node_modules/next/dist/client/components/builtin/global-error.js <module evaluation>":{"id":71118,"name":"*","chunks":[],"async":false},"[project]/packages/web/node_modules/next/dist/client/components/builtin/global-error.js":{"id":71118,"name":"*","chunks":[],"async":false},"[project]/packages/web/app/page.tsx <module evaluation>":{"id":52211,"name":"*","chunks":["/_next/static/chunks/5edfc5b1a4e490d6.js"],"async":false},"[project]/packages/web/app/page.tsx":{"id":52211,"name":"*","chunks":["/_next/static/chunks/5edfc5b1a4e490d6.js"],"async":false}},"ssrModuleMapping":{"42402":{"*":{"id":68066,"name":"*","chunks":["server/chunks/ssr/[root-of-the-server]__991ad012._.js","server/chunks/ssr/b182f_next_dist_1df82653._.js"],"async":false}},"27115":{"*":{"id":84972,"name":"*","chunks":["server/chunks/ssr/[root-of-the-server]__991ad012._.js","server/chunks/ssr/b182f_next_dist_1df82653._.js"],"async":false}},"13914":{"*":{"id":1780,"name":"*","chunks":["server/chunks/ssr/[root-of-the-server]__991ad012._.js","server/chunks/ssr/b182f_next_dist_1df82653._.js"],"async":false}},"94947":{"*":{"id":31754,"name":"*","chunks":["server/chunks/ssr/[root-of-the-server]__991ad012._.js","server/chunks/ssr/b182f_next_dist_1df82653._.js"],"async":false}},"70775":{"*":{"id":89100,"name":"*","chunks":["server/chunks/ssr/[root-of-the-server]__991ad012._.js","server/chunks/ssr/b182f_next_dist_1df82653._.js"],"async":false}},"75060":{"*":{"id":71853,"name":"*","chunks":["server/chunks/ssr/[root-of-the-server]__991ad012._.js","server/chunks/ssr/b182f_next_dist_1df82653._.js"],"async":false}},"98753":{"*":{"id":84479,"name":"*","chunks":["server/chunks/ssr/[root-of-the-server]__991ad012._.js","server/chunks/ssr/b182f_next_dist_1df82653._.js"],"async":false}},"71118":{"*":{"id":34871,"name":"*","chunks":["server/chunks/ssr/[root-of-the-server]__3bab6b28._.js"],"async":false}},"52211":{"*":{"id":4226,"name":"*","chunks":["server/chunks/ssr/[root-of-the-server]__4d138e9c._.js","server/chunks/ssr/packages_web_app_page_tsx_6037ad34._.js"],"async":false}}},"edgeSSRModuleMapping":{},"rscModuleMapping":{"42402":{"*":{"id":24957,"name":"*","chunks":[],"async":false}},"27115":{"*":{"id":86935,"name":"*","chunks":[],"async":false}},"13914":{"*":{"id":35185,"name":"*","chunks":[],"async":false}},"94947":{"*":{"id":6585,"name":"*","chunks":[],"async":false}},"70775":{"*":{"id":31279,"name":"*","chunks":[],"async":false}},"75060":{"*":{"id":62774,"name":"*","chunks":[],"async":false}},"98753":{"*":{"id":46674,"name":"*","chunks":[],"async":false}},"71118":{"*":{"id":49794,"name":"*","chunks":[],"async":false}},"52211":{"*":{"id":65222,"name":"*","chunks":[],"async":false}}},"edgeRscModuleMapping":{},"entryCSSFiles":{"[project]/packages/web/app/favicon.ico":[],"[project]/packages/web/node_modules/next/dist/client/components/builtin/global-error":[],"[project]/packages/web/app/layout":[{"path":"static/chunks/2014aa4b74125922.css","inlined":false}],"[project]/packages/web/app/page":[{"path":"static/chunks/2014aa4b74125922.css","inlined":false}]},"entryJSFiles":{"[project]/packages/web/app/favicon.ico":["static/chunks/74b0a4bcb4aa2cd1.js"],"[project]/packages/web/node_modules/next/dist/client/components/builtin/global-error":[],"[project]/packages/web/app/layout":[],"[project]/packages/web/app/page":["static/chunks/5edfc5b1a4e490d6.js"]}}
2
+ globalThis.__RSC_MANIFEST["/page"] = {"moduleLoading":{"prefix":"","crossOrigin":null},"clientModules":{"[project]/packages/web/node_modules/next/dist/esm/client/components/layout-router.js <module evaluation>":{"id":42402,"name":"*","chunks":["/_next/static/chunks/74b0a4bcb4aa2cd1.js"],"async":false},"[project]/packages/web/node_modules/next/dist/esm/client/components/layout-router.js":{"id":42402,"name":"*","chunks":["/_next/static/chunks/74b0a4bcb4aa2cd1.js"],"async":false},"[project]/packages/web/node_modules/next/dist/esm/client/components/render-from-template-context.js <module evaluation>":{"id":27115,"name":"*","chunks":["/_next/static/chunks/74b0a4bcb4aa2cd1.js"],"async":false},"[project]/packages/web/node_modules/next/dist/esm/client/components/render-from-template-context.js":{"id":27115,"name":"*","chunks":["/_next/static/chunks/74b0a4bcb4aa2cd1.js"],"async":false},"[project]/packages/web/node_modules/next/dist/esm/client/components/client-page.js <module evaluation>":{"id":13914,"name":"*","chunks":["/_next/static/chunks/74b0a4bcb4aa2cd1.js"],"async":false},"[project]/packages/web/node_modules/next/dist/esm/client/components/client-page.js":{"id":13914,"name":"*","chunks":["/_next/static/chunks/74b0a4bcb4aa2cd1.js"],"async":false},"[project]/packages/web/node_modules/next/dist/esm/client/components/client-segment.js <module evaluation>":{"id":94947,"name":"*","chunks":["/_next/static/chunks/74b0a4bcb4aa2cd1.js"],"async":false},"[project]/packages/web/node_modules/next/dist/esm/client/components/client-segment.js":{"id":94947,"name":"*","chunks":["/_next/static/chunks/74b0a4bcb4aa2cd1.js"],"async":false},"[project]/packages/web/node_modules/next/dist/esm/client/components/http-access-fallback/error-boundary.js <module evaluation>":{"id":70775,"name":"*","chunks":["/_next/static/chunks/74b0a4bcb4aa2cd1.js"],"async":false},"[project]/packages/web/node_modules/next/dist/esm/client/components/http-access-fallback/error-boundary.js":{"id":70775,"name":"*","chunks":["/_next/static/chunks/74b0a4bcb4aa2cd1.js"],"async":false},"[project]/packages/web/node_modules/next/dist/esm/lib/metadata/generate/icon-mark.js <module evaluation>":{"id":75060,"name":"*","chunks":["/_next/static/chunks/74b0a4bcb4aa2cd1.js"],"async":false},"[project]/packages/web/node_modules/next/dist/esm/lib/metadata/generate/icon-mark.js":{"id":75060,"name":"*","chunks":["/_next/static/chunks/74b0a4bcb4aa2cd1.js"],"async":false},"[project]/packages/web/node_modules/next/dist/esm/lib/framework/boundary-components.js <module evaluation>":{"id":98753,"name":"*","chunks":["/_next/static/chunks/74b0a4bcb4aa2cd1.js"],"async":false},"[project]/packages/web/node_modules/next/dist/esm/lib/framework/boundary-components.js":{"id":98753,"name":"*","chunks":["/_next/static/chunks/74b0a4bcb4aa2cd1.js"],"async":false},"[project]/packages/web/node_modules/next/dist/client/components/builtin/global-error.js <module evaluation>":{"id":71118,"name":"*","chunks":[],"async":false},"[project]/packages/web/node_modules/next/dist/client/components/builtin/global-error.js":{"id":71118,"name":"*","chunks":[],"async":false},"[project]/packages/web/app/page.tsx <module evaluation>":{"id":52211,"name":"*","chunks":["/_next/static/chunks/e49ab4a9fc4760d2.js"],"async":false},"[project]/packages/web/app/page.tsx":{"id":52211,"name":"*","chunks":["/_next/static/chunks/e49ab4a9fc4760d2.js"],"async":false}},"ssrModuleMapping":{"42402":{"*":{"id":68066,"name":"*","chunks":["server/chunks/ssr/[root-of-the-server]__991ad012._.js","server/chunks/ssr/b182f_next_dist_1df82653._.js"],"async":false}},"27115":{"*":{"id":84972,"name":"*","chunks":["server/chunks/ssr/[root-of-the-server]__991ad012._.js","server/chunks/ssr/b182f_next_dist_1df82653._.js"],"async":false}},"13914":{"*":{"id":1780,"name":"*","chunks":["server/chunks/ssr/[root-of-the-server]__991ad012._.js","server/chunks/ssr/b182f_next_dist_1df82653._.js"],"async":false}},"94947":{"*":{"id":31754,"name":"*","chunks":["server/chunks/ssr/[root-of-the-server]__991ad012._.js","server/chunks/ssr/b182f_next_dist_1df82653._.js"],"async":false}},"70775":{"*":{"id":89100,"name":"*","chunks":["server/chunks/ssr/[root-of-the-server]__991ad012._.js","server/chunks/ssr/b182f_next_dist_1df82653._.js"],"async":false}},"75060":{"*":{"id":71853,"name":"*","chunks":["server/chunks/ssr/[root-of-the-server]__991ad012._.js","server/chunks/ssr/b182f_next_dist_1df82653._.js"],"async":false}},"98753":{"*":{"id":84479,"name":"*","chunks":["server/chunks/ssr/[root-of-the-server]__991ad012._.js","server/chunks/ssr/b182f_next_dist_1df82653._.js"],"async":false}},"71118":{"*":{"id":34871,"name":"*","chunks":["server/chunks/ssr/[root-of-the-server]__3bab6b28._.js"],"async":false}},"52211":{"*":{"id":4226,"name":"*","chunks":["server/chunks/ssr/[root-of-the-server]__4d138e9c._.js","server/chunks/ssr/packages_web_app_page_tsx_6037ad34._.js"],"async":false}}},"edgeSSRModuleMapping":{},"rscModuleMapping":{"42402":{"*":{"id":24957,"name":"*","chunks":[],"async":false}},"27115":{"*":{"id":86935,"name":"*","chunks":[],"async":false}},"13914":{"*":{"id":35185,"name":"*","chunks":[],"async":false}},"94947":{"*":{"id":6585,"name":"*","chunks":[],"async":false}},"70775":{"*":{"id":31279,"name":"*","chunks":[],"async":false}},"75060":{"*":{"id":62774,"name":"*","chunks":[],"async":false}},"98753":{"*":{"id":46674,"name":"*","chunks":[],"async":false}},"71118":{"*":{"id":49794,"name":"*","chunks":[],"async":false}},"52211":{"*":{"id":65222,"name":"*","chunks":[],"async":false}}},"edgeRscModuleMapping":{},"entryCSSFiles":{"[project]/packages/web/app/favicon.ico":[],"[project]/packages/web/node_modules/next/dist/client/components/builtin/global-error":[],"[project]/packages/web/app/layout":[{"path":"static/chunks/2014aa4b74125922.css","inlined":false}],"[project]/packages/web/app/page":[{"path":"static/chunks/2014aa4b74125922.css","inlined":false}]},"entryJSFiles":{"[project]/packages/web/app/favicon.ico":["static/chunks/74b0a4bcb4aa2cd1.js"],"[project]/packages/web/node_modules/next/dist/client/components/builtin/global-error":[],"[project]/packages/web/app/layout":[],"[project]/packages/web/app/page":["static/chunks/e49ab4a9fc4760d2.js"]}}
@@ -1,3 +1,3 @@
1
- module.exports=[4226,a=>{"use strict";var b=a.i(74569),c=a.i(1688);let d=a=>{let b=a.replace(/^([A-Z])|[\s-_]+(\w)/g,(a,b,c)=>c?c.toUpperCase():b.toLowerCase());return b.charAt(0).toUpperCase()+b.slice(1)},e=(...a)=>a.filter((a,b,c)=>!!a&&""!==a.trim()&&c.indexOf(a)===b).join(" ").trim();var f={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};let g=(0,c.forwardRef)(({color:a="currentColor",size:b=24,strokeWidth:d=2,absoluteStrokeWidth:g,className:h="",children:i,iconNode:j,...k},l)=>(0,c.createElement)("svg",{ref:l,...f,width:b,height:b,stroke:a,strokeWidth:g?24*Number(d)/Number(b):d,className:e("lucide",h),...!i&&!(a=>{for(let b in a)if(b.startsWith("aria-")||"role"===b||"title"===b)return!0})(k)&&{"aria-hidden":"true"},...k},[...j.map(([a,b])=>(0,c.createElement)(a,b)),...Array.isArray(i)?i:[i]])),h=(a,b)=>{let f=(0,c.forwardRef)(({className:f,...h},i)=>(0,c.createElement)(g,{ref:i,iconNode:b,className:e(`lucide-${d(a).replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase()}`,`lucide-${a}`,f),...h}));return f.displayName=d(a),f},i=h("chevron-right",[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]]),j=h("chevron-down",[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]]),k=h("file-text",[["path",{d:"M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z",key:"1oefj6"}],["path",{d:"M14 2v5a1 1 0 0 0 1 1h5",key:"wfsgrz"}],["path",{d:"M10 9H8",key:"b1mrlr"}],["path",{d:"M16 13H8",key:"t4e002"}],["path",{d:"M16 17H8",key:"z1uh3a"}]]);class l{static flattenConfig(a,b=""){let c={};for(let d in a){let e=b?`${b}:${d}`:d;a[d]&&"object"==typeof a[d]&&!Array.isArray(a[d])?Object.assign(c,this.flattenConfig(a[d],e)):c[e]=a[d]}return c}static buildTree(a,b=""){let c=[];for(let d in a){let e=b?`${b}:${d}`:d,f=a[d];f&&"object"==typeof f&&!Array.isArray(f)?c.push({key:d,fullPath:e,value:f,children:this.buildTree(f,e),hasDocumentation:!1,type:"object"}):c.push({key:d,fullPath:e,value:f,hasDocumentation:!1,type:Array.isArray(f)?"array":typeof f})}return c}}function m({config:a,docs:d,onSelectProperty:e,onEditProperty:f,selectedPath:g}){let[h,m]=(0,c.useState)(new Set),n=(a,c=0)=>{let l=void 0!==d.properties[a.fullPath],o=h.has(a.fullPath),p=g===a.fullPath;return(0,b.jsxs)("div",{children:[(0,b.jsxs)("div",{style:{paddingLeft:`${20*c}px`},className:`group flex items-center gap-2 py-2 px-3 cursor-pointer rounded-lg transition-all duration-150 ${p?"bg-gradient-to-r from-blue-100 to-indigo-100 border-l-4 border-blue-500 shadow-sm":"hover:bg-gradient-to-r hover:from-gray-50 hover:to-gray-100"}`,children:[a.children&&a.children.length>0?(0,b.jsx)("button",{onClick:()=>{var b;let c;return b=a.fullPath,void((c=new Set(h)).has(b)?c.delete(b):c.add(b),m(c))},className:"p-1 hover:bg-blue-100 rounded-md transition-colors",children:o?(0,b.jsx)(j,{className:"w-4 h-4 text-blue-600"}):(0,b.jsx)(i,{className:"w-4 h-4 text-gray-600"})}):(0,b.jsx)("div",{className:"w-6"}),(0,b.jsxs)("div",{onClick:()=>e(a.fullPath),className:"flex-1 flex items-center gap-2",children:[(0,b.jsx)("span",{className:`${a.children?"font-bold text-gray-800":"font-medium text-gray-700"}`,children:a.key}),!a.children&&(0,b.jsxs)("span",{className:"text-sm text-gray-500 truncate max-w-[200px]",children:[": ",JSON.stringify(a.value)]}),l&&(0,b.jsxs)("div",{className:"flex items-center gap-1 px-2 py-0.5 bg-green-100 border border-green-300 rounded-full",children:[(0,b.jsx)(k,{className:"w-3 h-3 text-green-600"}),(0,b.jsx)("span",{className:"text-xs text-green-700 font-medium",children:"Doc"})]})]}),!a.children&&(0,b.jsx)("button",{onClick:b=>{b.stopPropagation(),f(a.fullPath)},className:"p-1 hover:bg-gray-200 rounded",title:"編集"})]}),a.children&&o&&(0,b.jsx)("div",{children:a.children.map(a=>n(a,c+1))})]},a.fullPath)},o=l.buildTree(a);return(0,b.jsxs)("div",{className:"h-full flex flex-col border-2 border-gray-100 rounded-xl bg-white shadow-sm",children:[(0,b.jsxs)("div",{className:"flex items-center gap-2 p-3 border-b-2 border-gray-100 bg-gradient-to-r from-gray-50 to-gray-100",children:[(0,b.jsx)("button",{onClick:()=>{var b;let c,d;m(new Set((b=l.buildTree(a),c=[],d=a=>{a.children&&a.children.length>0&&(c.push(a.fullPath),a.children.forEach(d))},b.forEach(d),c)))},className:"px-4 py-1.5 text-sm font-medium bg-white border-2 border-blue-200 text-blue-600 rounded-lg hover:bg-blue-50 hover:border-blue-300 transition-all duration-200 shadow-sm hover:shadow-md",children:"すべて展開"}),(0,b.jsx)("button",{onClick:()=>{m(new Set)},className:"px-4 py-1.5 text-sm font-medium bg-white border-2 border-gray-200 text-gray-600 rounded-lg hover:bg-gray-50 hover:border-gray-300 transition-all duration-200 shadow-sm hover:shadow-md",children:"すべて閉じる"})]}),(0,b.jsx)("div",{className:"flex-1 overflow-y-auto p-3",children:o.map(a=>n(a))})]})}let n=h("folder",[["path",{d:"M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z",key:"1kt360"}]]),o=h("file",[["path",{d:"M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z",key:"1oefj6"}],["path",{d:"M14 2v5a1 1 0 0 0 1 1h5",key:"wfsgrz"}]]),p=h("chevron-up",[["path",{d:"m18 15-6-6-6 6",key:"153udz"}]]);function q({isOpen:a,currentPath:d,onSelect:e,onClose:f,multiSelect:g=!1,filterJsonOnly:h=!1}){let[i,j]=(0,c.useState)(d),[k,l]=(0,c.useState)([]),[m,q]=(0,c.useState)(!1),[r,s]=(0,c.useState)([]);(0,c.useEffect)(()=>{a&&(j(d),s([]))},[a,d]),(0,c.useEffect)(()=>{a&&t(i)},[a,i]);let t=async a=>{q(!0);try{let b=await fetch("/api/files/browse",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({directory:a})}),c=await b.json();if(c.success){let a=h?c.data.items.filter(a=>"directory"===a.type||".json"===a.extension):c.data.items;l(a)}else console.error("API returned error:",c.error)}catch(a){console.error("Failed to load directory:",a)}finally{q(!1)}},u=()=>{s([]),f()};return a?(0,b.jsx)("div",{className:"fixed inset-0 bg-black bg-opacity-50 flex items-center justify-center z-50",children:(0,b.jsxs)("div",{className:"bg-white rounded-lg shadow-xl w-full max-w-2xl max-h-[80vh] flex flex-col",children:[(0,b.jsxs)("div",{className:"flex items-center justify-between p-4 border-b",children:[(0,b.jsx)("h2",{className:"text-lg font-semibold",children:"ファイルを選択"}),(0,b.jsx)("button",{onClick:u,className:"text-gray-500 hover:text-gray-700",children:"✕"})]}),(0,b.jsxs)("div",{className:"flex items-center gap-2 p-4 border-b bg-gray-50",children:[(0,b.jsx)("button",{onClick:()=>{let a=i.replace(/\//g,"\\").split("\\").filter(a=>a);if(a.length>1){let b=a.slice(0,-1);j(1===b.length&&b[0].includes(":")?b[0]+"\\":b[0].includes(":")?b[0]+"\\"+b.slice(1).join("\\"):b.join("\\"))}else 1!==a.length||a[0].includes(":")||j(".")},className:"p-2 hover:bg-gray-200 rounded flex-shrink-0",title:"上のディレクトリへ",children:(0,b.jsx)(p,{className:"w-5 h-5"})}),(0,b.jsxs)("span",{className:"text-sm text-gray-600 flex-1 truncate",children:["パス: ",i]})]}),(0,b.jsx)("div",{className:"flex-1 overflow-y-auto p-4",children:m?(0,b.jsx)("div",{className:"text-center text-gray-500",children:"読み込み中..."}):(0,b.jsx)("div",{className:"space-y-1",children:k.map(a=>{let c=r.includes(a.path);return(0,b.jsxs)("div",{onClick:()=>{"directory"===a.type?j(a.path):g?s(b=>b.includes(a.path)?b.filter(b=>b!==a.path):[...b,a.path]):s([a.path])},className:`flex items-center gap-2 p-2 rounded cursor-pointer hover:bg-gray-100 ${c?"bg-blue-100":""}`,children:["directory"===a.type?(0,b.jsx)(n,{className:"w-5 h-5 text-blue-500"}):(0,b.jsx)(o,{className:"w-5 h-5 text-green-500"}),(0,b.jsx)("span",{className:"text-sm",children:a.name}),c&&g&&(0,b.jsx)("span",{className:"ml-auto text-blue-500",children:"✓"})]},a.path)})})}),(0,b.jsxs)("div",{className:"flex items-center justify-between p-4 border-t",children:[g&&r.length>0&&(0,b.jsxs)("div",{className:"text-sm text-gray-600",children:[r.length,"件選択中"]}),(0,b.jsxs)("div",{className:"flex items-center gap-2 ml-auto",children:[(0,b.jsx)("button",{onClick:u,className:"px-4 py-2 text-gray-600 hover:bg-gray-100 rounded",children:"キャンセル"}),(0,b.jsx)("button",{onClick:()=>{r.length>0&&(e(r),s([]),f())},disabled:0===r.length,className:"px-4 py-2 bg-blue-500 text-white rounded hover:bg-blue-600 disabled:bg-gray-300 disabled:cursor-not-allowed",children:"選択"})]})]})]})}):null}let r=h("x",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]]),s=h("download",[["path",{d:"M12 15V3",key:"m9g1x1"}],["path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4",key:"ih7n3h"}],["path",{d:"m7 10 5 5 5-5",key:"brsn70"}]]),t={format:"html",autoExport:!0,fileName:"config-doc"};function u({isOpen:a,onClose:d,onExport:e,currentSettings:f,rootPath:g="."}){let[h,i]=(0,c.useState)(f||t),[j,k]=(0,c.useState)(!1);(0,c.useEffect)(()=>{f&&i(f)},[f]);let l=(0,c.useMemo)(()=>{let a=g.replace(/\//g,"\\"),b=h.fileName||"config-doc",c="markdown"===h.format||"markdown-table"===h.format?"md":"html";return`${a}\\.config_doc\\output\\${b}.${c}`},[h.format,h.fileName,g]);if(!a)return null;let m=async()=>{k(!0);try{await e(h),d()}catch(a){console.error("Export failed:",a)}finally{k(!1)}};return(0,b.jsx)("div",{className:"fixed inset-0 bg-black bg-opacity-50 flex items-center justify-center z-50",children:(0,b.jsxs)("div",{className:"bg-white rounded-lg shadow-xl max-w-md w-full mx-4",children:[(0,b.jsxs)("div",{className:"flex items-center justify-between p-6 border-b",children:[(0,b.jsx)("h2",{className:"text-xl font-semibold text-gray-800",children:"エクスポート設定"}),(0,b.jsx)("button",{onClick:d,className:"text-gray-400 hover:text-gray-600 transition-colors",children:(0,b.jsx)(r,{className:"w-5 h-5"})})]}),(0,b.jsxs)("div",{className:"p-6 space-y-6",children:[(0,b.jsxs)("div",{children:[(0,b.jsx)("label",{className:"block text-sm font-medium text-gray-700 mb-2",children:"出力先パス"}),(0,b.jsx)("div",{className:"px-3 py-2 bg-gray-50 border border-gray-300 rounded-md text-sm text-gray-700 font-mono break-all",children:l}),(0,b.jsx)("p",{className:"mt-1 text-xs text-gray-500",children:"html"===h.format?"HTMLファイルの出力先":"markdown-table"===h.format?"Markdownテーブル形式ファイルの出力先":"Markdownファイルの出力先"})]}),(0,b.jsxs)("div",{children:[(0,b.jsx)("label",{className:"block text-sm font-medium text-gray-700 mb-2",children:"ファイル名"}),(0,b.jsx)("input",{type:"text",value:h.fileName||"config-doc",onChange:a=>i({...h,fileName:a.target.value}),className:"w-full px-3 py-2 border border-gray-300 rounded-md focus:outline-none focus:ring-2 focus:ring-blue-500",placeholder:"config-doc"}),(0,b.jsx)("p",{className:"mt-1 text-xs text-gray-500",children:"拡張子なしのファイル名を指定します(チーム共有設定)"})]}),(0,b.jsxs)("div",{children:[(0,b.jsx)("label",{className:"block text-sm font-medium text-gray-700 mb-2",children:"出力形式"}),(0,b.jsxs)("select",{value:h.format,onChange:a=>i({...h,format:a.target.value}),className:"w-full px-3 py-2 border border-gray-300 rounded-md focus:outline-none focus:ring-2 focus:ring-blue-500",children:[(0,b.jsx)("option",{value:"html",children:"HTML"}),(0,b.jsx)("option",{value:"markdown",children:"Markdown"}),(0,b.jsx)("option",{value:"markdown-table",children:"Markdown (テーブル形式)"})]}),(0,b.jsx)("p",{className:"mt-1 text-xs text-gray-500",children:"html"===h.format?"スタイル付きのHTMLファイルとして出力します":"markdown-table"===h.format?"Markdownテーブル形式で出力します(プロパティ名、説明、値、備考)":"テキストベースのMarkdownファイルとして出力します"})]}),(0,b.jsxs)("div",{className:"flex items-start",children:[(0,b.jsx)("div",{className:"flex items-center h-5",children:(0,b.jsx)("input",{id:"auto-export",type:"checkbox",checked:h.autoExport,onChange:a=>i({...h,autoExport:a.target.checked}),className:"w-4 h-4 text-blue-600 border-gray-300 rounded focus:ring-blue-500"})}),(0,b.jsxs)("div",{className:"ml-3",children:[(0,b.jsx)("label",{htmlFor:"auto-export",className:"text-sm font-medium text-gray-700 cursor-pointer",children:"保存時に自動エクスポート"}),(0,b.jsx)("p",{className:"text-xs text-gray-500 mt-1",children:"ドキュメントを保存したときに自動的にHTMLファイルを更新します"})]})]}),h.lastExportedAt&&(0,b.jsx)("div",{className:"pt-4 border-t",children:(0,b.jsxs)("p",{className:"text-xs text-gray-500",children:["最終エクスポート: ",new Date(h.lastExportedAt).toLocaleString("ja-JP")]})})]}),(0,b.jsxs)("div",{className:"flex items-center justify-end gap-3 p-6 border-t bg-gray-50 rounded-b-lg",children:[(0,b.jsx)("button",{onClick:d,className:"px-4 py-2 text-sm font-medium text-gray-700 bg-white border border-gray-300 rounded-md hover:bg-gray-50 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-blue-500",children:"キャンセル"}),(0,b.jsxs)("button",{onClick:m,disabled:j,className:"flex items-center gap-2 px-4 py-2 text-sm font-medium text-white bg-blue-600 border border-transparent rounded-md hover:bg-blue-700 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-blue-500 disabled:opacity-50 disabled:cursor-not-allowed",children:[(0,b.jsx)(s,{className:"w-4 h-4"}),j?"エクスポート中...":"エクスポート"]})]})]})})}let v=h("circle-check-big",[["path",{d:"M21.801 10A10 10 0 1 1 17 3.335",key:"yps3ct"}],["path",{d:"m9 11 3 3L22 4",key:"1pflzl"}]]),w=h("circle-x",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m15 9-6 6",key:"1uzhvr"}],["path",{d:"m9 9 6 6",key:"z0biqf"}]]),x=h("circle-alert",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["line",{x1:"12",x2:"12",y1:"8",y2:"12",key:"1pkeuh"}],["line",{x1:"12",x2:"12.01",y1:"16",y2:"16",key:"4dfq90"}]]);function y({message:a,type:d,duration:e=3e3,onClose:f}){let[g,h]=(0,c.useState)(!1);(0,c.useEffect)(()=>{setTimeout(()=>h(!0),10);let a=setTimeout(()=>{h(!1),setTimeout(f,300)},e);return()=>clearTimeout(a)},[e,f]);let i={success:(0,b.jsx)(v,{className:"w-5 h-5 text-green-500"}),error:(0,b.jsx)(w,{className:"w-5 h-5 text-red-500"}),warning:(0,b.jsx)(x,{className:"w-5 h-5 text-yellow-500"})};return(0,b.jsx)("div",{className:`fixed bottom-4 left-4 z-50 transition-all duration-300 ${g?"opacity-100 translate-y-0":"opacity-0 translate-y-2"}`,children:(0,b.jsxs)("div",{className:`flex items-center gap-3 px-4 py-3 rounded-lg shadow-lg border ${{success:"bg-green-50 border-green-200",error:"bg-red-50 border-red-200",warning:"bg-yellow-50 border-yellow-200"}[d]} min-w-[300px] max-w-[500px]`,children:[i[d],(0,b.jsx)("span",{className:"flex-1 text-sm text-gray-800",children:a}),(0,b.jsx)("button",{onClick:()=>{h(!1),setTimeout(f,300)},className:"text-gray-400 hover:text-gray-600 transition-colors",children:(0,b.jsx)(r,{className:"w-4 h-4"})})]})})}function z({toasts:a,onRemove:c}){return(0,b.jsx)(b.Fragment,{children:a.map((a,d)=>(0,b.jsx)("div",{style:{bottom:`${16+80*d}px`},className:"fixed left-4 z-50",children:(0,b.jsx)(y,{message:a.message,type:a.type,onClose:()=>c(a.id)})},a.id))})}let A=h("folder-open",[["path",{d:"m6 14 1.5-2.9A2 2 0 0 1 9.24 10H20a2 2 0 0 1 1.94 2.5l-1.54 6a2 2 0 0 1-1.95 1.5H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h3.9a2 2 0 0 1 1.69.9l.81 1.2a2 2 0 0 0 1.67.9H18a2 2 0 0 1 2 2v2",key:"usdka0"}]]),B=h("save",[["path",{d:"M15.2 3a2 2 0 0 1 1.4.6l3.8 3.8a2 2 0 0 1 .6 1.4V19a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2z",key:"1c8476"}],["path",{d:"M17 21v-7a1 1 0 0 0-1-1H8a1 1 0 0 0-1 1v7",key:"1ydtos"}],["path",{d:"M7 3v4a1 1 0 0 0 1 1h7",key:"t51u73"}]]);function C(){let[a,d]=(0,c.useState)([]),[e,f]=(0,c.useState)(0),[g,h]=(0,c.useState)(""),[i,j]=(0,c.useState)(!1),[l,n]=(0,c.useState)(!1),[o,p]=(0,c.useState)(!1),[t,v]=(0,c.useState)("."),[w,x]=(0,c.useState)(null),[y,C]=(0,c.useState)(null),[D,E]=(0,c.useState)(!1),[F,G]=(0,c.useState)(),[H,I]=(0,c.useState)([]),J=(a,b="success")=>{let c=Date.now().toString();I(d=>[...d,{id:c,message:a,type:b}])},K=(a,b)=>!!a&&!!b&&(a.description!==b.description||a.notes!==b.notes),L=a[e];(0,c.useEffect)(()=>{(async()=>{try{let a=await fetch("/api/project"),b=await a.json();if(b.success&&(v(b.data.rootPath),b.data.hasConfigDoc)){let a=await fetch("/api/config/metadata"),b=await a.json();if(b.success&&b.data?.configFiles)for(let a of b.data.configFiles)await M(a.filePath)}let c=await fetch("/api/export/settings"),d=await c.json();d.success&&G(d.data)}catch(a){console.error("Failed to load saved configs:",a)}finally{p(!0)}})()},[]);let M=async a=>{try{let b=await fetch("/api/config/load",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({filePath:a})}),c=await b.json();c.success&&d(b=>b.some(b=>b.filePath===a)?b:[...b,{filePath:a,configData:c.data.configData,docs:c.data.docs}])}catch(a){console.error("Failed to load config file:",a)}},N=async a=>{try{let b=await fetch("/api/config/metadata",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({configFilePaths:a})}),c=await b.json();c.deletedDocsFiles&&c.deletedDocsFiles.length>0&&J(`${c.deletedDocsFiles.length}件のドキュメントファイルを削除しました`,"warning")}catch(a){console.error("Failed to update metadata:",a)}},O=(a,b)=>{let c=a.replace(/\\/g,"/"),d=b.replace(/\\/g,"/");if(!c.match(/^[a-zA-Z]:\//)&&!c.startsWith("/"))return a;if(c.startsWith(d)){let a=c.substring(d.length);return a.startsWith("/")?a.substring(1):a}return a},P=async b=>{let c=[];for(let d of b){let b=O(d,t);if(!a.some(a=>a.filePath===b))try{let a=await fetch("/api/config/load",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({filePath:d})}),e=await a.json();e.success?c.push({filePath:b,configData:e.data.configData,docs:e.data.docs}):J(`設定ファイルの読み込みに失敗しました (${d}): ${e.error}`,"error")}catch(a){console.error("Failed to load config:",a),J(`設定ファイルの読み込み中にエラーが発生しました: ${d}`,"error")}}c.length>0&&d(a=>{let b=[...a,...c];return N(b.map(a=>a.filePath)),b})},Q=async b=>{let c=a[b];(!c.docs||!(Object.keys(c.docs.properties).length>0)||confirm("既に説明文が設定されていますが、削除してよろしいですか?"))&&(d(a=>{let c=a.filter((a,c)=>c!==b);return N(c.map(a=>a.filePath)),c}),e>=b&&e>0&&f(e-1),h(""),x(null),E(!1))},R=a=>{if(D&&!confirm("保存されていない変更があります。破棄しますか?"))return;h(a);let b=L.docs.properties[a];if(b){let a={...b};x(a),C(a)}else{let b={path:a,description:"",notes:"",modifiedAt:new Date().toISOString()};x(b),C(b)}E(!1)},S=async()=>{if(w&&L)try{let a={...w,modifiedAt:new Date().toISOString()},b=await fetch("/api/config/save",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({configFilePath:L.filePath,propertyPath:g,propertyDoc:a})}),c=await b.json();c.success?(d(b=>b.map((b,c)=>c===e?{...b,docs:{...b.docs,properties:{...b.docs.properties,[g]:a}}}:b)),x(a),C(a),E(!1),J("保存しました"),F?.autoExport&&await T()):J("保存に失敗しました: "+c.error,"error")}catch(a){console.error("Failed to save:",a),J("保存中にエラーが発生しました","error")}},T=async()=>{if(F)try{if((await fetch("/api/export",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({format:F.format,fileName:F.fileName})})).ok){let a={...F,lastExportedAt:new Date().toISOString()};G(a),await fetch("/api/export/settings",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({settings:a})})}}catch(a){console.error("Auto export failed:",a)}},U=async a=>{try{let b=await fetch("/api/export",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({format:a.format,fileName:a.fileName})}),c=await b.json();if(c.success){let b={...a,lastExportedAt:new Date().toISOString()};G(b),await fetch("/api/export/settings",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({settings:b})}),J(`エクスポートしました: ${c.outputPath}`)}else J("エクスポートに失敗しました: "+c.error,"error")}catch(a){console.error("Export failed:",a),J("エクスポート中にエラーが発生しました","error")}};return(0,b.jsxs)("div",{className:"min-h-screen bg-gradient-to-br from-blue-50 via-indigo-50 to-purple-50",children:[(0,b.jsx)("header",{className:"bg-white/80 backdrop-blur-md border-b border-gray-200 shadow-sm sticky top-0 z-50",children:(0,b.jsxs)("div",{className:"container mx-auto px-6 py-4 flex items-center justify-between",children:[(0,b.jsxs)("div",{className:"flex items-center gap-3",children:[(0,b.jsx)("div",{className:"w-10 h-10 bg-gradient-to-br from-blue-600 to-purple-600 rounded-lg flex items-center justify-center shadow-lg",children:(0,b.jsx)(k,{className:"w-6 h-6 text-white"})}),(0,b.jsxs)("div",{children:[(0,b.jsx)("h1",{className:"text-2xl font-bold bg-gradient-to-r from-blue-600 to-purple-600 bg-clip-text text-transparent",children:"ConfigDoc"}),(0,b.jsx)("p",{className:"text-xs text-gray-500",children:"Configuration Documentation Tool"})]})]}),(0,b.jsxs)("button",{onClick:()=>n(!0),className:"flex items-center gap-2 px-5 py-2.5 bg-gradient-to-r from-green-500 to-emerald-600 text-white rounded-lg hover:from-green-600 hover:to-emerald-700 shadow-md hover:shadow-lg transition-all duration-200 transform hover:scale-105",title:"エクスポート",children:[(0,b.jsx)(s,{className:"w-5 h-5"}),(0,b.jsx)("span",{className:"font-medium",children:"エクスポート"})]})]})}),(0,b.jsxs)("main",{className:"container mx-auto px-6 py-8",children:[(0,b.jsxs)("div",{className:"bg-white/90 backdrop-blur-sm rounded-2xl shadow-xl border border-gray-100 p-6 mb-8 hover:shadow-2xl transition-shadow duration-300",children:[(0,b.jsxs)("div",{className:"flex items-center justify-between mb-4",children:[(0,b.jsxs)("div",{className:"flex items-center gap-2",children:[(0,b.jsx)("div",{className:"w-8 h-8 bg-gradient-to-br from-blue-500 to-blue-600 rounded-lg flex items-center justify-center",children:(0,b.jsx)(A,{className:"w-5 h-5 text-white"})}),(0,b.jsx)("h2",{className:"text-xl font-bold text-gray-800",children:"設定ファイル"})]}),(0,b.jsxs)("button",{onClick:()=>j(!0),className:"flex items-center gap-2 px-4 py-2 bg-gradient-to-r from-blue-500 to-blue-600 text-white rounded-lg hover:from-blue-600 hover:to-blue-700 shadow-md hover:shadow-lg transition-all duration-200 transform hover:scale-105",children:[(0,b.jsx)(A,{className:"w-5 h-5"}),(0,b.jsx)("span",{className:"font-medium",children:"ファイルを追加"})]})]}),a.length>0?(0,b.jsx)("div",{className:"flex flex-wrap gap-3",children:a.map((a,c)=>(0,b.jsxs)("div",{onClick:()=>{f(c),h(""),x(null),E(!1)},className:`group flex items-center gap-2 px-4 py-2.5 rounded-xl border-2 cursor-pointer transition-all duration-200 ${e===c?"bg-gradient-to-r from-blue-50 to-indigo-50 border-blue-400 shadow-md":"bg-white border-gray-200 hover:border-blue-300 hover:shadow-md"}`,children:[(0,b.jsx)("span",{className:`text-sm font-medium ${e===c?"text-blue-700":"text-gray-700"}`,children:a.filePath.split(/[/\\]/).pop()}),(0,b.jsx)("button",{onClick:a=>{a.stopPropagation(),Q(c)},className:"text-gray-400 hover:text-red-500 transition-colors opacity-0 group-hover:opacity-100",children:(0,b.jsx)(r,{className:"w-4 h-4"})})]},a.filePath))}):(0,b.jsxs)("div",{className:"text-center py-12 bg-gradient-to-br from-gray-50 to-gray-100 rounded-xl border-2 border-dashed border-gray-300",children:[(0,b.jsx)(A,{className:"w-16 h-16 text-gray-400 mx-auto mb-3"}),(0,b.jsx)("p",{className:"text-sm text-gray-600 font-medium",children:"設定ファイルを選択してください"}),(0,b.jsx)("p",{className:"text-xs text-gray-500 mt-1",children:"「ファイルを追加」ボタンから開始"})]})]}),L&&(0,b.jsxs)("div",{className:"grid grid-cols-1 lg:grid-cols-2 gap-6",children:[(0,b.jsxs)("div",{className:"bg-white/90 backdrop-blur-sm rounded-2xl shadow-xl border border-gray-100 p-6 flex flex-col max-h-[calc(100vh-350px)] hover:shadow-2xl transition-shadow duration-300",children:[(0,b.jsxs)("div",{className:"flex items-center gap-2 mb-4",children:[(0,b.jsx)("div",{className:"w-8 h-8 bg-gradient-to-br from-purple-500 to-purple-600 rounded-lg flex items-center justify-center",children:(0,b.jsx)(k,{className:"w-5 h-5 text-white"})}),(0,b.jsx)("h2",{className:"text-xl font-bold text-gray-800",children:"JSON構造"})]}),(0,b.jsx)("div",{className:"overflow-y-auto flex-1",children:(0,b.jsx)(m,{config:L.configData,docs:L.docs,onSelectProperty:R,onEditProperty:R,selectedPath:g})})]}),(0,b.jsxs)("div",{className:"bg-white/90 backdrop-blur-sm rounded-2xl shadow-xl border border-gray-100 p-6 flex flex-col max-h-[calc(100vh-250px)] hover:shadow-2xl transition-shadow duration-300",children:[(0,b.jsxs)("div",{className:"flex items-center justify-between mb-4",children:[(0,b.jsxs)("div",{className:"flex items-center gap-2",children:[(0,b.jsx)("div",{className:"w-8 h-8 bg-gradient-to-br from-indigo-500 to-indigo-600 rounded-lg flex items-center justify-center",children:(0,b.jsx)(B,{className:"w-5 h-5 text-white"})}),(0,b.jsx)("h2",{className:"text-xl font-bold text-gray-800",children:"プロパティ詳細"})]}),D&&(0,b.jsxs)("button",{onClick:S,className:"flex items-center gap-2 px-4 py-2 bg-gradient-to-r from-green-500 to-emerald-600 text-white rounded-lg hover:from-green-600 hover:to-emerald-700 shadow-md hover:shadow-lg transition-all duration-200 transform hover:scale-105",children:[(0,b.jsx)(B,{className:"w-4 h-4"}),(0,b.jsx)("span",{className:"font-medium",children:"保存"})]})]}),(0,b.jsx)("div",{className:"overflow-y-auto flex-1",children:g&&w?(0,b.jsxs)("div",{className:"space-y-6",children:[(0,b.jsxs)("div",{children:[(0,b.jsx)("label",{className:"block text-sm font-semibold text-gray-700 mb-2",children:"パス"}),(0,b.jsx)("div",{className:"text-sm text-gray-700 bg-gradient-to-r from-blue-50 to-indigo-50 p-3 rounded-lg font-mono border border-blue-200 shadow-sm",children:g})]}),(0,b.jsxs)("div",{children:[(0,b.jsx)("label",{className:"block text-sm font-semibold text-gray-700 mb-2",children:"説明"}),(0,b.jsx)("textarea",{value:w.description,onChange:a=>{let b={...w,description:a.target.value};x(b),E(K(b,y))},className:"w-full border-2 border-gray-200 rounded-lg p-3 min-h-[120px] text-sm focus:border-blue-400 focus:ring-2 focus:ring-blue-200 transition-all duration-200 shadow-sm hover:shadow-md",placeholder:"このプロパティの説明を入力してください"})]}),(0,b.jsxs)("div",{children:[(0,b.jsx)("label",{className:"block text-sm font-semibold text-gray-700 mb-2",children:"備考"}),(0,b.jsx)("textarea",{value:w.notes,onChange:a=>{let b={...w,notes:a.target.value};x(b),E(K(b,y))},className:"w-full border-2 border-gray-200 rounded-lg p-3 min-h-[100px] text-sm focus:border-blue-400 focus:ring-2 focus:ring-blue-200 transition-all duration-200 shadow-sm hover:shadow-md",placeholder:"追加のメモや注意事項"})]})]}):(0,b.jsxs)("div",{className:"flex flex-col items-center justify-center py-20",children:[(0,b.jsx)("div",{className:"w-20 h-20 bg-gradient-to-br from-gray-100 to-gray-200 rounded-full flex items-center justify-center mb-4",children:(0,b.jsx)(k,{className:"w-10 h-10 text-gray-400"})}),(0,b.jsx)("p",{className:"text-sm text-gray-600 font-medium",children:"プロパティを選択してください"}),(0,b.jsx)("p",{className:"text-xs text-gray-500 mt-1",children:"左側のツリーから項目を選択"})]})})]})]})]}),(0,b.jsx)(q,{isOpen:i,currentPath:t,multiSelect:!0,filterJsonOnly:!0,onSelect:a=>{P(a),j(!1)},onClose:()=>j(!1)}),(0,b.jsx)(u,{isOpen:l,onClose:()=>n(!1),onExport:U,currentSettings:F,rootPath:t}),(0,b.jsx)(z,{toasts:H,onRemove:a=>{I(b=>b.filter(b=>b.id!==a))}})]})}a.s(["default",()=>C],4226)}];
1
+ module.exports=[4226,a=>{"use strict";var b=a.i(74569),c=a.i(1688);let d=a=>{let b=a.replace(/^([A-Z])|[\s-_]+(\w)/g,(a,b,c)=>c?c.toUpperCase():b.toLowerCase());return b.charAt(0).toUpperCase()+b.slice(1)},e=(...a)=>a.filter((a,b,c)=>!!a&&""!==a.trim()&&c.indexOf(a)===b).join(" ").trim();var f={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};let g=(0,c.forwardRef)(({color:a="currentColor",size:b=24,strokeWidth:d=2,absoluteStrokeWidth:g,className:h="",children:i,iconNode:j,...k},l)=>(0,c.createElement)("svg",{ref:l,...f,width:b,height:b,stroke:a,strokeWidth:g?24*Number(d)/Number(b):d,className:e("lucide",h),...!i&&!(a=>{for(let b in a)if(b.startsWith("aria-")||"role"===b||"title"===b)return!0})(k)&&{"aria-hidden":"true"},...k},[...j.map(([a,b])=>(0,c.createElement)(a,b)),...Array.isArray(i)?i:[i]])),h=(a,b)=>{let f=(0,c.forwardRef)(({className:f,...h},i)=>(0,c.createElement)(g,{ref:i,iconNode:b,className:e(`lucide-${d(a).replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase()}`,`lucide-${a}`,f),...h}));return f.displayName=d(a),f},i=h("chevron-right",[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]]),j=h("chevron-down",[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]]),k=h("file-text",[["path",{d:"M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z",key:"1oefj6"}],["path",{d:"M14 2v5a1 1 0 0 0 1 1h5",key:"wfsgrz"}],["path",{d:"M10 9H8",key:"b1mrlr"}],["path",{d:"M16 13H8",key:"t4e002"}],["path",{d:"M16 17H8",key:"z1uh3a"}]]);class l{static flattenConfig(a,b=""){let c={};for(let d in a){let e=b?`${b}:${d}`:d;a[d]&&"object"==typeof a[d]&&!Array.isArray(a[d])?Object.assign(c,this.flattenConfig(a[d],e)):c[e]=a[d]}return c}static buildTree(a,b=""){let c=[];for(let d in a){let e=b?`${b}:${d}`:d,f=a[d];f&&"object"==typeof f&&!Array.isArray(f)?c.push({key:d,fullPath:e,value:f,children:this.buildTree(f,e),hasDocumentation:!1,type:"object"}):c.push({key:d,fullPath:e,value:f,hasDocumentation:!1,type:Array.isArray(f)?"array":typeof f})}return c}}function m({config:a,docs:d,onSelectProperty:e,onEditProperty:f,selectedPath:g}){let[h,m]=(0,c.useState)(new Set),n=(a,c=0)=>{let l=void 0!==d.properties[a.fullPath],o=h.has(a.fullPath),p=g===a.fullPath;return(0,b.jsxs)("div",{children:[(0,b.jsxs)("div",{style:{paddingLeft:`${20*c}px`},className:`group flex items-center gap-2 py-2 px-3 cursor-pointer rounded-lg transition-all duration-150 ${p?"bg-gradient-to-r from-blue-100 to-indigo-100 border-l-4 border-blue-500 shadow-sm":"hover:bg-gradient-to-r hover:from-gray-50 hover:to-gray-100"}`,children:[a.children&&a.children.length>0?(0,b.jsx)("button",{onClick:()=>{var b;let c;return b=a.fullPath,void((c=new Set(h)).has(b)?c.delete(b):c.add(b),m(c))},className:"p-1 hover:bg-blue-100 rounded-md transition-colors",children:o?(0,b.jsx)(j,{className:"w-4 h-4 text-blue-600"}):(0,b.jsx)(i,{className:"w-4 h-4 text-gray-600"})}):(0,b.jsx)("div",{className:"w-6"}),(0,b.jsxs)("div",{onClick:()=>e(a.fullPath),className:"flex-1 flex items-center gap-2",children:[(0,b.jsx)("span",{className:`${a.children?"font-bold text-gray-800":"font-medium text-gray-700"}`,children:a.key}),!a.children&&(0,b.jsxs)("span",{className:"text-sm text-gray-500 truncate max-w-[200px]",children:[": ",JSON.stringify(a.value)]}),l&&(0,b.jsxs)("div",{className:"flex items-center gap-1 px-2 py-0.5 bg-green-100 border border-green-300 rounded-full",children:[(0,b.jsx)(k,{className:"w-3 h-3 text-green-600"}),(0,b.jsx)("span",{className:"text-xs text-green-700 font-medium",children:"Doc"})]})]}),!a.children&&(0,b.jsx)("button",{onClick:b=>{b.stopPropagation(),f(a.fullPath)},className:"p-1 hover:bg-gray-200 rounded",title:"編集"})]}),a.children&&o&&(0,b.jsx)("div",{children:a.children.map(a=>n(a,c+1))})]},a.fullPath)},o=l.buildTree(a);return(0,b.jsxs)("div",{className:"h-full flex flex-col border-2 border-gray-100 rounded-xl bg-white shadow-sm",children:[(0,b.jsxs)("div",{className:"flex items-center gap-2 p-3 border-b-2 border-gray-100 bg-gradient-to-r from-gray-50 to-gray-100",children:[(0,b.jsx)("button",{onClick:()=>{var b;let c,d;m(new Set((b=l.buildTree(a),c=[],d=a=>{a.children&&a.children.length>0&&(c.push(a.fullPath),a.children.forEach(d))},b.forEach(d),c)))},className:"px-4 py-1.5 text-sm font-medium bg-white border-2 border-blue-200 text-blue-600 rounded-lg hover:bg-blue-50 hover:border-blue-300 transition-all duration-200 shadow-sm hover:shadow-md",children:"すべて展開"}),(0,b.jsx)("button",{onClick:()=>{m(new Set)},className:"px-4 py-1.5 text-sm font-medium bg-white border-2 border-gray-200 text-gray-600 rounded-lg hover:bg-gray-50 hover:border-gray-300 transition-all duration-200 shadow-sm hover:shadow-md",children:"すべて閉じる"})]}),(0,b.jsx)("div",{className:"flex-1 overflow-y-auto p-3",children:o.map(a=>n(a))})]})}let n=h("folder",[["path",{d:"M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z",key:"1kt360"}]]),o=h("file",[["path",{d:"M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z",key:"1oefj6"}],["path",{d:"M14 2v5a1 1 0 0 0 1 1h5",key:"wfsgrz"}]]),p=h("arrow-up",[["path",{d:"m5 12 7-7 7 7",key:"hav0vg"}],["path",{d:"M12 19V5",key:"x0mq9r"}]]);function q({isOpen:a,currentPath:d,onSelect:e,onClose:f,multiSelect:g=!1,filterJsonOnly:h=!1}){let[i,j]=(0,c.useState)(d),[k,l]=(0,c.useState)([]),[m,q]=(0,c.useState)(!1),[r,s]=(0,c.useState)([]);(0,c.useEffect)(()=>{a&&(j(d),s([]))},[a,d]),(0,c.useEffect)(()=>{a&&t(i)},[a,i]);let t=async a=>{q(!0);try{let b=await fetch("/api/files/browse",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({directory:a})}),c=await b.json();if(c.success){let a=h?c.data.items.filter(a=>"directory"===a.type||".json"===a.extension):c.data.items;l(a)}else console.error("API returned error:",c.error)}catch(a){console.error("Failed to load directory:",a)}finally{q(!1)}},u=()=>{s([]),f()};return a?(0,b.jsx)("div",{className:"fixed inset-0 bg-black bg-opacity-50 flex items-center justify-center z-50",children:(0,b.jsxs)("div",{className:"bg-white rounded-lg shadow-xl w-full max-w-2xl max-h-[80vh] flex flex-col",children:[(0,b.jsxs)("div",{className:"flex items-center justify-between p-4 border-b",children:[(0,b.jsx)("h2",{className:"text-lg font-semibold",children:"ファイルを選択"}),(0,b.jsx)("button",{onClick:u,className:"text-gray-500 hover:text-gray-700",children:"✕"})]}),(0,b.jsxs)("div",{className:"flex items-center gap-2 p-4 border-b bg-gray-50",children:[(0,b.jsx)("button",{onClick:()=>{let a=i.replace(/\//g,"\\").split("\\").filter(a=>a);if(a.length>1){let b=a.slice(0,-1);j(1===b.length&&b[0].includes(":")?b[0]+"\\":b[0].includes(":")?b[0]+"\\"+b.slice(1).join("\\"):b.join("\\"))}else 1!==a.length||a[0].includes(":")||j(".")},className:"p-2 hover:bg-gray-200 rounded flex-shrink-0",title:"上のディレクトリへ",children:(0,b.jsx)(p,{className:"w-5 h-5"})}),(0,b.jsxs)("span",{className:"text-sm text-gray-600 flex-1 truncate",children:["パス: ",i]})]}),(0,b.jsx)("div",{className:"flex-1 overflow-y-auto p-4",children:m?(0,b.jsx)("div",{className:"text-center text-gray-500",children:"読み込み中..."}):(0,b.jsx)("div",{className:"space-y-1",children:k.map(a=>{let c=r.includes(a.path);return(0,b.jsxs)("div",{onClick:()=>{"directory"===a.type?j(a.path):g?s(b=>b.includes(a.path)?b.filter(b=>b!==a.path):[...b,a.path]):s([a.path])},className:`flex items-center gap-2 p-2 rounded cursor-pointer hover:bg-gray-100 ${c?"bg-blue-100":""}`,children:["directory"===a.type?(0,b.jsx)(n,{className:"w-5 h-5 text-blue-500"}):(0,b.jsx)(o,{className:"w-5 h-5 text-green-500"}),(0,b.jsx)("span",{className:"text-sm",children:a.name}),c&&g&&(0,b.jsx)("span",{className:"ml-auto text-blue-500",children:"✓"})]},a.path)})})}),(0,b.jsxs)("div",{className:"flex items-center justify-between p-4 border-t",children:[g&&r.length>0&&(0,b.jsxs)("div",{className:"text-sm text-gray-600",children:[r.length,"件選択中"]}),(0,b.jsxs)("div",{className:"flex items-center gap-2 ml-auto",children:[(0,b.jsx)("button",{onClick:u,className:"px-4 py-2 text-gray-600 hover:bg-gray-100 rounded",children:"キャンセル"}),(0,b.jsx)("button",{onClick:()=>{r.length>0&&(e(r),s([]),f())},disabled:0===r.length,className:"px-4 py-2 bg-blue-500 text-white rounded hover:bg-blue-600 disabled:bg-gray-300 disabled:cursor-not-allowed",children:"選択"})]})]})]})}):null}let r=h("x",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]]),s=h("download",[["path",{d:"M12 15V3",key:"m9g1x1"}],["path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4",key:"ih7n3h"}],["path",{d:"m7 10 5 5 5-5",key:"brsn70"}]]),t={format:"html",autoExport:!0,fileName:"config-doc"};function u({isOpen:a,onClose:d,onExport:e,currentSettings:f,rootPath:g="."}){let[h,i]=(0,c.useState)(f||t),[j,k]=(0,c.useState)(!1);(0,c.useEffect)(()=>{f&&i(f)},[f]);let l=(0,c.useMemo)(()=>{let a=g.replace(/\//g,"\\"),b=h.fileName||"config-doc",c="markdown"===h.format||"markdown-table"===h.format?"md":"html";return`${a}\\.config_doc\\output\\${b}.${c}`},[h.format,h.fileName,g]);if(!a)return null;let m=async()=>{k(!0);try{await e(h),d()}catch(a){console.error("Export failed:",a)}finally{k(!1)}};return(0,b.jsx)("div",{className:"fixed inset-0 bg-black bg-opacity-50 flex items-center justify-center z-50",children:(0,b.jsxs)("div",{className:"bg-white rounded-lg shadow-xl max-w-md w-full mx-4",children:[(0,b.jsxs)("div",{className:"flex items-center justify-between p-6 border-b",children:[(0,b.jsx)("h2",{className:"text-xl font-semibold text-gray-800",children:"エクスポート設定"}),(0,b.jsx)("button",{onClick:d,className:"text-gray-400 hover:text-gray-600 transition-colors",children:(0,b.jsx)(r,{className:"w-5 h-5"})})]}),(0,b.jsxs)("div",{className:"p-6 space-y-6",children:[(0,b.jsxs)("div",{children:[(0,b.jsx)("label",{className:"block text-sm font-medium text-gray-700 mb-2",children:"出力先パス"}),(0,b.jsx)("div",{className:"px-3 py-2 bg-gray-50 border border-gray-300 rounded-md text-sm text-gray-700 font-mono break-all",children:l}),(0,b.jsx)("p",{className:"mt-1 text-xs text-gray-500",children:"html"===h.format?"HTMLファイルの出力先":"markdown-table"===h.format?"Markdownテーブル形式ファイルの出力先":"Markdownファイルの出力先"})]}),(0,b.jsxs)("div",{children:[(0,b.jsx)("label",{className:"block text-sm font-medium text-gray-700 mb-2",children:"ファイル名"}),(0,b.jsx)("input",{type:"text",value:h.fileName||"config-doc",onChange:a=>i({...h,fileName:a.target.value}),className:"w-full px-3 py-2 border border-gray-300 rounded-md focus:outline-none focus:ring-2 focus:ring-blue-500",placeholder:"config-doc"}),(0,b.jsx)("p",{className:"mt-1 text-xs text-gray-500",children:"拡張子なしのファイル名を指定します(チーム共有設定)"})]}),(0,b.jsxs)("div",{children:[(0,b.jsx)("label",{className:"block text-sm font-medium text-gray-700 mb-2",children:"出力形式"}),(0,b.jsxs)("select",{value:h.format,onChange:a=>i({...h,format:a.target.value}),className:"w-full px-3 py-2 border border-gray-300 rounded-md focus:outline-none focus:ring-2 focus:ring-blue-500",children:[(0,b.jsx)("option",{value:"html",children:"HTML"}),(0,b.jsx)("option",{value:"markdown",children:"Markdown"}),(0,b.jsx)("option",{value:"markdown-table",children:"Markdown (テーブル形式)"})]}),(0,b.jsx)("p",{className:"mt-1 text-xs text-gray-500",children:"html"===h.format?"スタイル付きのHTMLファイルとして出力します":"markdown-table"===h.format?"Markdownテーブル形式で出力します(プロパティ名、説明、値、備考)":"テキストベースのMarkdownファイルとして出力します"})]}),(0,b.jsxs)("div",{className:"flex items-start",children:[(0,b.jsx)("div",{className:"flex items-center h-5",children:(0,b.jsx)("input",{id:"auto-export",type:"checkbox",checked:h.autoExport,onChange:a=>i({...h,autoExport:a.target.checked}),className:"w-4 h-4 text-blue-600 border-gray-300 rounded focus:ring-blue-500"})}),(0,b.jsxs)("div",{className:"ml-3",children:[(0,b.jsx)("label",{htmlFor:"auto-export",className:"text-sm font-medium text-gray-700 cursor-pointer",children:"保存時に自動エクスポート"}),(0,b.jsx)("p",{className:"text-xs text-gray-500 mt-1",children:"ドキュメントを保存したときに自動的にHTMLファイルを更新します"})]})]}),h.lastExportedAt&&(0,b.jsx)("div",{className:"pt-4 border-t",children:(0,b.jsxs)("p",{className:"text-xs text-gray-500",children:["最終エクスポート: ",new Date(h.lastExportedAt).toLocaleString("ja-JP")]})})]}),(0,b.jsxs)("div",{className:"flex items-center justify-end gap-3 p-6 border-t bg-gray-50 rounded-b-lg",children:[(0,b.jsx)("button",{onClick:d,className:"px-4 py-2 text-sm font-medium text-gray-700 bg-white border border-gray-300 rounded-md hover:bg-gray-50 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-blue-500",children:"キャンセル"}),(0,b.jsxs)("button",{onClick:m,disabled:j,className:"flex items-center gap-2 px-4 py-2 text-sm font-medium text-white bg-blue-600 border border-transparent rounded-md hover:bg-blue-700 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-blue-500 disabled:opacity-50 disabled:cursor-not-allowed",children:[(0,b.jsx)(s,{className:"w-4 h-4"}),j?"エクスポート中...":"エクスポート"]})]})]})})}let v=h("circle-check-big",[["path",{d:"M21.801 10A10 10 0 1 1 17 3.335",key:"yps3ct"}],["path",{d:"m9 11 3 3L22 4",key:"1pflzl"}]]),w=h("circle-x",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m15 9-6 6",key:"1uzhvr"}],["path",{d:"m9 9 6 6",key:"z0biqf"}]]),x=h("circle-alert",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["line",{x1:"12",x2:"12",y1:"8",y2:"12",key:"1pkeuh"}],["line",{x1:"12",x2:"12.01",y1:"16",y2:"16",key:"4dfq90"}]]);function y({message:a,type:d,duration:e=3e3,onClose:f}){let[g,h]=(0,c.useState)(!1);(0,c.useEffect)(()=>{setTimeout(()=>h(!0),10);let a=setTimeout(()=>{h(!1),setTimeout(f,300)},e);return()=>clearTimeout(a)},[e,f]);let i={success:(0,b.jsx)(v,{className:"w-5 h-5 text-green-500"}),error:(0,b.jsx)(w,{className:"w-5 h-5 text-red-500"}),warning:(0,b.jsx)(x,{className:"w-5 h-5 text-yellow-500"})};return(0,b.jsx)("div",{className:`fixed bottom-4 left-4 z-50 transition-all duration-300 ${g?"opacity-100 translate-y-0":"opacity-0 translate-y-2"}`,children:(0,b.jsxs)("div",{className:`flex items-center gap-3 px-4 py-3 rounded-lg shadow-lg border ${{success:"bg-green-50 border-green-200",error:"bg-red-50 border-red-200",warning:"bg-yellow-50 border-yellow-200"}[d]} min-w-[300px] max-w-[500px]`,children:[i[d],(0,b.jsx)("span",{className:"flex-1 text-sm text-gray-800",children:a}),(0,b.jsx)("button",{onClick:()=>{h(!1),setTimeout(f,300)},className:"text-gray-400 hover:text-gray-600 transition-colors",children:(0,b.jsx)(r,{className:"w-4 h-4"})})]})})}function z({toasts:a,onRemove:c}){return(0,b.jsx)(b.Fragment,{children:a.map((a,d)=>(0,b.jsx)("div",{style:{bottom:`${16+80*d}px`},className:"fixed left-4 z-50",children:(0,b.jsx)(y,{message:a.message,type:a.type,onClose:()=>c(a.id)})},a.id))})}let A=h("folder-open",[["path",{d:"m6 14 1.5-2.9A2 2 0 0 1 9.24 10H20a2 2 0 0 1 1.94 2.5l-1.54 6a2 2 0 0 1-1.95 1.5H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h3.9a2 2 0 0 1 1.69.9l.81 1.2a2 2 0 0 0 1.67.9H18a2 2 0 0 1 2 2v2",key:"usdka0"}]]),B=h("save",[["path",{d:"M15.2 3a2 2 0 0 1 1.4.6l3.8 3.8a2 2 0 0 1 .6 1.4V19a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2z",key:"1c8476"}],["path",{d:"M17 21v-7a1 1 0 0 0-1-1H8a1 1 0 0 0-1 1v7",key:"1ydtos"}],["path",{d:"M7 3v4a1 1 0 0 0 1 1h7",key:"t51u73"}]]);function C(){let[a,d]=(0,c.useState)([]),[e,f]=(0,c.useState)(0),[g,h]=(0,c.useState)(""),[i,j]=(0,c.useState)(!1),[l,n]=(0,c.useState)(!1),[o,p]=(0,c.useState)(!1),[t,v]=(0,c.useState)("."),[w,x]=(0,c.useState)(null),[y,C]=(0,c.useState)(null),[D,E]=(0,c.useState)(!1),[F,G]=(0,c.useState)(),[H,I]=(0,c.useState)([]),J=(a,b="success")=>{let c=Date.now().toString();I(d=>[...d,{id:c,message:a,type:b}])},K=(a,b)=>!!a&&!!b&&(a.description!==b.description||a.notes!==b.notes),L=a[e];(0,c.useEffect)(()=>{(async()=>{try{let a=await fetch("/api/project"),b=await a.json();if(b.success&&(v(b.data.rootPath),b.data.hasConfigDoc)){let a=await fetch("/api/config/metadata"),b=await a.json();if(b.success&&b.data?.configFiles)for(let a of b.data.configFiles)await M(a.filePath)}let c=await fetch("/api/export/settings"),d=await c.json();d.success&&G(d.data)}catch(a){console.error("Failed to load saved configs:",a)}finally{p(!0)}})()},[]);let M=async a=>{try{let b=await fetch("/api/config/load",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({filePath:a})}),c=await b.json();c.success&&d(b=>b.some(b=>b.filePath===a)?b:[...b,{filePath:a,configData:c.data.configData,docs:c.data.docs}])}catch(a){console.error("Failed to load config file:",a)}},N=async a=>{try{let b=await fetch("/api/config/metadata",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({configFilePaths:a})}),c=await b.json();c.deletedDocsFiles&&c.deletedDocsFiles.length>0&&J(`${c.deletedDocsFiles.length}件のドキュメントファイルを削除しました`,"warning")}catch(a){console.error("Failed to update metadata:",a)}},O=(a,b)=>{let c=a.replace(/\\/g,"/"),d=b.replace(/\\/g,"/");if(!c.match(/^[a-zA-Z]:\//)&&!c.startsWith("/"))return a;if(c.startsWith(d)){let a=c.substring(d.length);return a.startsWith("/")?a.substring(1):a}return a},P=async b=>{let c=[];for(let d of b){let b=O(d,t);if(!a.some(a=>a.filePath===b))try{let a=await fetch("/api/config/load",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({filePath:d})}),e=await a.json();e.success?c.push({filePath:b,configData:e.data.configData,docs:e.data.docs}):J(`設定ファイルの読み込みに失敗しました (${d}): ${e.error}`,"error")}catch(a){console.error("Failed to load config:",a),J(`設定ファイルの読み込み中にエラーが発生しました: ${d}`,"error")}}c.length>0&&d(a=>{let b=[...a,...c];return N(b.map(a=>a.filePath)),b})},Q=async b=>{let c=a[b];(!c.docs||!(Object.keys(c.docs.properties).length>0)||confirm("既に説明文が設定されていますが、削除してよろしいですか?"))&&(d(a=>{let c=a.filter((a,c)=>c!==b);return N(c.map(a=>a.filePath)),c}),e>=b&&e>0&&f(e-1),h(""),x(null),E(!1))},R=a=>{if(D&&!confirm("保存されていない変更があります。破棄しますか?"))return;h(a);let b=L.docs.properties[a];if(b){let a={...b};x(a),C(a)}else{let b={path:a,description:"",notes:"",modifiedAt:new Date().toISOString()};x(b),C(b)}E(!1)},S=async()=>{if(w&&L)try{let a={...w,modifiedAt:new Date().toISOString()},b=await fetch("/api/config/save",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({configFilePath:L.filePath,propertyPath:g,propertyDoc:a})}),c=await b.json();c.success?(d(b=>b.map((b,c)=>c===e?{...b,docs:{...b.docs,properties:{...b.docs.properties,[g]:a}}}:b)),x(a),C(a),E(!1),J("保存しました"),F?.autoExport&&await T()):J("保存に失敗しました: "+c.error,"error")}catch(a){console.error("Failed to save:",a),J("保存中にエラーが発生しました","error")}},T=async()=>{if(F)try{if((await fetch("/api/export",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({format:F.format,fileName:F.fileName})})).ok){let a={...F,lastExportedAt:new Date().toISOString()};G(a),await fetch("/api/export/settings",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({settings:a})})}}catch(a){console.error("Auto export failed:",a)}},U=async a=>{try{let b=await fetch("/api/export",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({format:a.format,fileName:a.fileName})}),c=await b.json();if(c.success){let b={...a,lastExportedAt:new Date().toISOString()};G(b),await fetch("/api/export/settings",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({settings:b})}),J(`エクスポートしました: ${c.outputPath}`)}else J("エクスポートに失敗しました: "+c.error,"error")}catch(a){console.error("Export failed:",a),J("エクスポート中にエラーが発生しました","error")}};return(0,b.jsxs)("div",{className:"min-h-screen bg-gradient-to-br from-blue-50 via-indigo-50 to-purple-50",children:[(0,b.jsx)("header",{className:"bg-white/80 backdrop-blur-md border-b border-gray-200 shadow-sm sticky top-0 z-50",children:(0,b.jsxs)("div",{className:"container mx-auto px-6 py-4 flex items-center justify-between",children:[(0,b.jsxs)("div",{className:"flex items-center gap-3",children:[(0,b.jsx)("div",{className:"w-10 h-10 bg-gradient-to-br from-blue-600 to-purple-600 rounded-lg flex items-center justify-center shadow-lg",children:(0,b.jsx)(k,{className:"w-6 h-6 text-white"})}),(0,b.jsxs)("div",{children:[(0,b.jsx)("h1",{className:"text-2xl font-bold bg-gradient-to-r from-blue-600 to-purple-600 bg-clip-text text-transparent",children:"ConfigDoc"}),(0,b.jsx)("p",{className:"text-xs text-gray-500",children:"Configuration Documentation Tool"})]})]}),(0,b.jsxs)("button",{onClick:()=>n(!0),className:"flex items-center gap-2 px-5 py-2.5 bg-gradient-to-r from-green-500 to-emerald-600 text-white rounded-lg hover:from-green-600 hover:to-emerald-700 shadow-md hover:shadow-lg transition-all duration-200 transform hover:scale-105",title:"エクスポート",children:[(0,b.jsx)(s,{className:"w-5 h-5"}),(0,b.jsx)("span",{className:"font-medium",children:"エクスポート"})]})]})}),(0,b.jsxs)("main",{className:"container mx-auto px-6 py-8",children:[(0,b.jsxs)("div",{className:"bg-white/90 backdrop-blur-sm rounded-2xl shadow-xl border border-gray-100 p-6 mb-8 hover:shadow-2xl transition-shadow duration-300",children:[(0,b.jsxs)("div",{className:"flex items-center justify-between mb-4",children:[(0,b.jsxs)("div",{className:"flex items-center gap-2",children:[(0,b.jsx)("div",{className:"w-8 h-8 bg-gradient-to-br from-blue-500 to-blue-600 rounded-lg flex items-center justify-center",children:(0,b.jsx)(A,{className:"w-5 h-5 text-white"})}),(0,b.jsx)("h2",{className:"text-xl font-bold text-gray-800",children:"設定ファイル"})]}),(0,b.jsxs)("button",{onClick:()=>j(!0),className:"flex items-center gap-2 px-4 py-2 bg-gradient-to-r from-blue-500 to-blue-600 text-white rounded-lg hover:from-blue-600 hover:to-blue-700 shadow-md hover:shadow-lg transition-all duration-200 transform hover:scale-105",children:[(0,b.jsx)(A,{className:"w-5 h-5"}),(0,b.jsx)("span",{className:"font-medium",children:"ファイルを追加"})]})]}),a.length>0?(0,b.jsx)("div",{className:"flex flex-wrap gap-3",children:a.map((c,d)=>(0,b.jsxs)("div",{onClick:()=>{f(d),h(""),x(null),E(!1)},className:`group flex items-center gap-2 px-4 py-2.5 rounded-xl border-2 cursor-pointer transition-all duration-200 ${e===d?"bg-gradient-to-r from-blue-50 to-indigo-50 border-blue-400 shadow-md":"bg-white border-gray-200 hover:border-blue-300 hover:shadow-md"}`,children:[(0,b.jsx)("span",{className:`text-sm font-medium ${e===d?"text-blue-700":"text-gray-700"}`,children:((a,b)=>{let c=a.split(/[/\\]/).pop()||a,d=b.filter(a=>a.split(/[/\\]/).pop()===c);if(1===d.length)return c;let e=a.split(/[/\\]/);for(let b=1;b<e.length;b++){let c=e.slice(-b-1).join("/");if(0===d.filter(d=>c===d.split(/[/\\]/).slice(-b-1).join("/")&&d!==a).length)return c}return a})(c.filePath,a.map(a=>a.filePath))}),(0,b.jsx)("button",{onClick:a=>{a.stopPropagation(),Q(d)},className:"text-gray-400 hover:text-red-500 transition-colors opacity-0 group-hover:opacity-100",children:(0,b.jsx)(r,{className:"w-4 h-4"})})]},c.filePath))}):(0,b.jsxs)("div",{className:"text-center py-12 bg-gradient-to-br from-gray-50 to-gray-100 rounded-xl border-2 border-dashed border-gray-300",children:[(0,b.jsx)(A,{className:"w-16 h-16 text-gray-400 mx-auto mb-3"}),(0,b.jsx)("p",{className:"text-sm text-gray-600 font-medium",children:"設定ファイルを選択してください"}),(0,b.jsx)("p",{className:"text-xs text-gray-500 mt-1",children:"「ファイルを追加」ボタンから開始"})]})]}),L&&(0,b.jsxs)("div",{className:"grid grid-cols-1 lg:grid-cols-2 gap-6",children:[(0,b.jsxs)("div",{className:"bg-white/90 backdrop-blur-sm rounded-2xl shadow-xl border border-gray-100 p-6 flex flex-col max-h-[calc(100vh-350px)] hover:shadow-2xl transition-shadow duration-300",children:[(0,b.jsxs)("div",{className:"flex items-center gap-2 mb-4",children:[(0,b.jsx)("div",{className:"w-8 h-8 bg-gradient-to-br from-purple-500 to-purple-600 rounded-lg flex items-center justify-center",children:(0,b.jsx)(k,{className:"w-5 h-5 text-white"})}),(0,b.jsx)("h2",{className:"text-xl font-bold text-gray-800",children:"JSON構造"})]}),(0,b.jsx)("div",{className:"overflow-y-auto flex-1",children:(0,b.jsx)(m,{config:L.configData,docs:L.docs,onSelectProperty:R,onEditProperty:R,selectedPath:g})})]}),(0,b.jsxs)("div",{className:"bg-white/90 backdrop-blur-sm rounded-2xl shadow-xl border border-gray-100 p-6 flex flex-col max-h-[calc(100vh-250px)] hover:shadow-2xl transition-shadow duration-300",children:[(0,b.jsxs)("div",{className:"flex items-center justify-between mb-4",children:[(0,b.jsxs)("div",{className:"flex items-center gap-2",children:[(0,b.jsx)("div",{className:"w-8 h-8 bg-gradient-to-br from-indigo-500 to-indigo-600 rounded-lg flex items-center justify-center",children:(0,b.jsx)(B,{className:"w-5 h-5 text-white"})}),(0,b.jsx)("h2",{className:"text-xl font-bold text-gray-800",children:"プロパティ詳細"})]}),D&&(0,b.jsxs)("button",{onClick:S,className:"flex items-center gap-2 px-4 py-2 bg-gradient-to-r from-green-500 to-emerald-600 text-white rounded-lg hover:from-green-600 hover:to-emerald-700 shadow-md hover:shadow-lg transition-all duration-200 transform hover:scale-105",children:[(0,b.jsx)(B,{className:"w-4 h-4"}),(0,b.jsx)("span",{className:"font-medium",children:"保存"})]})]}),(0,b.jsx)("div",{className:"overflow-y-auto flex-1",children:g&&w?(0,b.jsxs)("div",{className:"space-y-6",children:[(0,b.jsxs)("div",{children:[(0,b.jsx)("label",{className:"block text-sm font-semibold text-gray-700 mb-2",children:"パス"}),(0,b.jsx)("div",{className:"text-sm text-gray-700 bg-gradient-to-r from-blue-50 to-indigo-50 p-3 rounded-lg font-mono border border-blue-200 shadow-sm",children:g})]}),(0,b.jsxs)("div",{children:[(0,b.jsx)("label",{className:"block text-sm font-semibold text-gray-700 mb-2",children:"説明"}),(0,b.jsx)("textarea",{value:w.description,onChange:a=>{let b={...w,description:a.target.value};x(b),E(K(b,y))},className:"w-full border-2 border-gray-200 rounded-lg p-3 min-h-[120px] text-sm focus:border-blue-400 focus:ring-2 focus:ring-blue-200 transition-all duration-200 shadow-sm hover:shadow-md",placeholder:"このプロパティの説明を入力してください"})]}),(0,b.jsxs)("div",{children:[(0,b.jsx)("label",{className:"block text-sm font-semibold text-gray-700 mb-2",children:"備考"}),(0,b.jsx)("textarea",{value:w.notes,onChange:a=>{let b={...w,notes:a.target.value};x(b),E(K(b,y))},className:"w-full border-2 border-gray-200 rounded-lg p-3 min-h-[100px] text-sm focus:border-blue-400 focus:ring-2 focus:ring-blue-200 transition-all duration-200 shadow-sm hover:shadow-md",placeholder:"追加のメモや注意事項"})]})]}):(0,b.jsxs)("div",{className:"flex flex-col items-center justify-center py-20",children:[(0,b.jsx)("div",{className:"w-20 h-20 bg-gradient-to-br from-gray-100 to-gray-200 rounded-full flex items-center justify-center mb-4",children:(0,b.jsx)(k,{className:"w-10 h-10 text-gray-400"})}),(0,b.jsx)("p",{className:"text-sm text-gray-600 font-medium",children:"プロパティを選択してください"}),(0,b.jsx)("p",{className:"text-xs text-gray-500 mt-1",children:"左側のツリーから項目を選択"})]})})]})]})]}),(0,b.jsx)(q,{isOpen:i,currentPath:t,multiSelect:!0,filterJsonOnly:!0,onSelect:a=>{P(a),j(!1)},onClose:()=>j(!1)}),(0,b.jsx)(u,{isOpen:l,onClose:()=>n(!1),onExport:U,currentSettings:F,rootPath:t}),(0,b.jsx)(z,{toasts:H,onRemove:a=>{I(b=>b.filter(b=>b.id!==a))}})]})}a.s(["default",()=>C],4226)}];
2
2
 
3
3
  //# sourceMappingURL=packages_web_app_page_tsx_6037ad34._.js.map
@@ -0,0 +1 @@
1
+ (globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,52211,e=>{"use strict";var t=e.i(52420),r=e.i(20063);let a=e=>{let t=e.replace(/^([A-Z])|[\s-_]+(\w)/g,(e,t,r)=>r?r.toUpperCase():t.toLowerCase());return t.charAt(0).toUpperCase()+t.slice(1)},s=(...e)=>e.filter((e,t,r)=>!!e&&""!==e.trim()&&r.indexOf(e)===t).join(" ").trim();var l={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};let o=(0,r.forwardRef)(({color:e="currentColor",size:t=24,strokeWidth:a=2,absoluteStrokeWidth:o,className:i="",children:n,iconNode:d,...c},h)=>(0,r.createElement)("svg",{ref:h,...l,width:t,height:t,stroke:e,strokeWidth:o?24*Number(a)/Number(t):a,className:s("lucide",i),...!n&&!(e=>{for(let t in e)if(t.startsWith("aria-")||"role"===t||"title"===t)return!0})(c)&&{"aria-hidden":"true"},...c},[...d.map(([e,t])=>(0,r.createElement)(e,t)),...Array.isArray(n)?n:[n]])),i=(e,t)=>{let l=(0,r.forwardRef)(({className:l,...i},n)=>(0,r.createElement)(o,{ref:n,iconNode:t,className:s(`lucide-${a(e).replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase()}`,`lucide-${e}`,l),...i}));return l.displayName=a(e),l},n=i("chevron-right",[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]]),d=i("chevron-down",[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]]),c=i("file-text",[["path",{d:"M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z",key:"1oefj6"}],["path",{d:"M14 2v5a1 1 0 0 0 1 1h5",key:"wfsgrz"}],["path",{d:"M10 9H8",key:"b1mrlr"}],["path",{d:"M16 13H8",key:"t4e002"}],["path",{d:"M16 17H8",key:"z1uh3a"}]]);class h{static flattenConfig(e,t=""){let r={};for(let a in e){let s=t?`${t}:${a}`:a;e[a]&&"object"==typeof e[a]&&!Array.isArray(e[a])?Object.assign(r,this.flattenConfig(e[a],s)):r[s]=e[a]}return r}static buildTree(e,t=""){let r=[];for(let a in e){let s=t?`${t}:${a}`:a,l=e[a];l&&"object"==typeof l&&!Array.isArray(l)?r.push({key:a,fullPath:s,value:l,children:this.buildTree(l,s),hasDocumentation:!1,type:"object"}):r.push({key:a,fullPath:s,value:l,hasDocumentation:!1,type:Array.isArray(l)?"array":typeof l})}return r}}function m({config:e,docs:a,onSelectProperty:s,onEditProperty:l,selectedPath:o}){let[i,m]=(0,r.useState)(new Set),x=(e,r=0)=>{let h=void 0!==a.properties[e.fullPath],u=i.has(e.fullPath),f=o===e.fullPath;return(0,t.jsxs)("div",{children:[(0,t.jsxs)("div",{style:{paddingLeft:`${20*r}px`},className:`group flex items-center gap-2 py-2 px-3 cursor-pointer rounded-lg transition-all duration-150 ${f?"bg-gradient-to-r from-blue-100 to-indigo-100 border-l-4 border-blue-500 shadow-sm":"hover:bg-gradient-to-r hover:from-gray-50 hover:to-gray-100"}`,children:[e.children&&e.children.length>0?(0,t.jsx)("button",{onClick:()=>{var t;let r;return t=e.fullPath,void((r=new Set(i)).has(t)?r.delete(t):r.add(t),m(r))},className:"p-1 hover:bg-blue-100 rounded-md transition-colors",children:u?(0,t.jsx)(d,{className:"w-4 h-4 text-blue-600"}):(0,t.jsx)(n,{className:"w-4 h-4 text-gray-600"})}):(0,t.jsx)("div",{className:"w-6"}),(0,t.jsxs)("div",{onClick:()=>s(e.fullPath),className:"flex-1 flex items-center gap-2",children:[(0,t.jsx)("span",{className:`${e.children?"font-bold text-gray-800":"font-medium text-gray-700"}`,children:e.key}),!e.children&&(0,t.jsxs)("span",{className:"text-sm text-gray-500 truncate max-w-[200px]",children:[": ",JSON.stringify(e.value)]}),h&&(0,t.jsxs)("div",{className:"flex items-center gap-1 px-2 py-0.5 bg-green-100 border border-green-300 rounded-full",children:[(0,t.jsx)(c,{className:"w-3 h-3 text-green-600"}),(0,t.jsx)("span",{className:"text-xs text-green-700 font-medium",children:"Doc"})]})]}),!e.children&&(0,t.jsx)("button",{onClick:t=>{t.stopPropagation(),l(e.fullPath)},className:"p-1 hover:bg-gray-200 rounded",title:"編集"})]}),e.children&&u&&(0,t.jsx)("div",{children:e.children.map(e=>x(e,r+1))})]},e.fullPath)},u=h.buildTree(e);return(0,t.jsxs)("div",{className:"h-full flex flex-col border-2 border-gray-100 rounded-xl bg-white shadow-sm",children:[(0,t.jsxs)("div",{className:"flex items-center gap-2 p-3 border-b-2 border-gray-100 bg-gradient-to-r from-gray-50 to-gray-100",children:[(0,t.jsx)("button",{onClick:()=>{var t;let r,a;m(new Set((t=h.buildTree(e),r=[],a=e=>{e.children&&e.children.length>0&&(r.push(e.fullPath),e.children.forEach(a))},t.forEach(a),r)))},className:"px-4 py-1.5 text-sm font-medium bg-white border-2 border-blue-200 text-blue-600 rounded-lg hover:bg-blue-50 hover:border-blue-300 transition-all duration-200 shadow-sm hover:shadow-md",children:"すべて展開"}),(0,t.jsx)("button",{onClick:()=>{m(new Set)},className:"px-4 py-1.5 text-sm font-medium bg-white border-2 border-gray-200 text-gray-600 rounded-lg hover:bg-gray-50 hover:border-gray-300 transition-all duration-200 shadow-sm hover:shadow-md",children:"すべて閉じる"})]}),(0,t.jsx)("div",{className:"flex-1 overflow-y-auto p-3",children:u.map(e=>x(e))})]})}let x=i("folder",[["path",{d:"M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z",key:"1kt360"}]]),u=i("file",[["path",{d:"M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z",key:"1oefj6"}],["path",{d:"M14 2v5a1 1 0 0 0 1 1h5",key:"wfsgrz"}]]),f=i("arrow-up",[["path",{d:"m5 12 7-7 7 7",key:"hav0vg"}],["path",{d:"M12 19V5",key:"x0mq9r"}]]);function g({isOpen:e,currentPath:a,onSelect:s,onClose:l,multiSelect:o=!1,filterJsonOnly:i=!1}){let[n,d]=(0,r.useState)(a),[c,h]=(0,r.useState)([]),[m,g]=(0,r.useState)(!1),[p,b]=(0,r.useState)([]);(0,r.useEffect)(()=>{e&&(d(a),b([]))},[e,a]),(0,r.useEffect)(()=>{e&&y(n)},[e,n]);let y=async e=>{g(!0);try{let t=await fetch("/api/files/browse",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({directory:e})}),r=await t.json();if(r.success){let e=i?r.data.items.filter(e=>"directory"===e.type||".json"===e.extension):r.data.items;h(e)}else console.error("API returned error:",r.error)}catch(e){console.error("Failed to load directory:",e)}finally{g(!1)}},j=()=>{b([]),l()};return e?(0,t.jsx)("div",{className:"fixed inset-0 bg-black bg-opacity-50 flex items-center justify-center z-50",children:(0,t.jsxs)("div",{className:"bg-white rounded-lg shadow-xl w-full max-w-2xl max-h-[80vh] flex flex-col",children:[(0,t.jsxs)("div",{className:"flex items-center justify-between p-4 border-b",children:[(0,t.jsx)("h2",{className:"text-lg font-semibold",children:"ファイルを選択"}),(0,t.jsx)("button",{onClick:j,className:"text-gray-500 hover:text-gray-700",children:"✕"})]}),(0,t.jsxs)("div",{className:"flex items-center gap-2 p-4 border-b bg-gray-50",children:[(0,t.jsx)("button",{onClick:()=>{let e=n.replace(/\//g,"\\").split("\\").filter(e=>e);if(e.length>1){let t=e.slice(0,-1);d(1===t.length&&t[0].includes(":")?t[0]+"\\":t[0].includes(":")?t[0]+"\\"+t.slice(1).join("\\"):t.join("\\"))}else 1!==e.length||e[0].includes(":")||d(".")},className:"p-2 hover:bg-gray-200 rounded flex-shrink-0",title:"上のディレクトリへ",children:(0,t.jsx)(f,{className:"w-5 h-5"})}),(0,t.jsxs)("span",{className:"text-sm text-gray-600 flex-1 truncate",children:["パス: ",n]})]}),(0,t.jsx)("div",{className:"flex-1 overflow-y-auto p-4",children:m?(0,t.jsx)("div",{className:"text-center text-gray-500",children:"読み込み中..."}):(0,t.jsx)("div",{className:"space-y-1",children:c.map(e=>{let r=p.includes(e.path);return(0,t.jsxs)("div",{onClick:()=>{"directory"===e.type?d(e.path):o?b(t=>t.includes(e.path)?t.filter(t=>t!==e.path):[...t,e.path]):b([e.path])},className:`flex items-center gap-2 p-2 rounded cursor-pointer hover:bg-gray-100 ${r?"bg-blue-100":""}`,children:["directory"===e.type?(0,t.jsx)(x,{className:"w-5 h-5 text-blue-500"}):(0,t.jsx)(u,{className:"w-5 h-5 text-green-500"}),(0,t.jsx)("span",{className:"text-sm",children:e.name}),r&&o&&(0,t.jsx)("span",{className:"ml-auto text-blue-500",children:"✓"})]},e.path)})})}),(0,t.jsxs)("div",{className:"flex items-center justify-between p-4 border-t",children:[o&&p.length>0&&(0,t.jsxs)("div",{className:"text-sm text-gray-600",children:[p.length,"件選択中"]}),(0,t.jsxs)("div",{className:"flex items-center gap-2 ml-auto",children:[(0,t.jsx)("button",{onClick:j,className:"px-4 py-2 text-gray-600 hover:bg-gray-100 rounded",children:"キャンセル"}),(0,t.jsx)("button",{onClick:()=>{p.length>0&&(s(p),b([]),l())},disabled:0===p.length,className:"px-4 py-2 bg-blue-500 text-white rounded hover:bg-blue-600 disabled:bg-gray-300 disabled:cursor-not-allowed",children:"選択"})]})]})]})}):null}let p=i("x",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]]),b=i("download",[["path",{d:"M12 15V3",key:"m9g1x1"}],["path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4",key:"ih7n3h"}],["path",{d:"m7 10 5 5 5-5",key:"brsn70"}]]),y={format:"html",autoExport:!0,fileName:"config-doc"};function j({isOpen:e,onClose:a,onExport:s,currentSettings:l,rootPath:o="."}){let[i,n]=(0,r.useState)(l||y),[d,c]=(0,r.useState)(!1);(0,r.useEffect)(()=>{l&&n(l)},[l]);let h=(0,r.useMemo)(()=>{let e=o.replace(/\//g,"\\"),t=i.fileName||"config-doc",r="markdown"===i.format||"markdown-table"===i.format?"md":"html";return`${e}\\.config_doc\\output\\${t}.${r}`},[i.format,i.fileName,o]);if(!e)return null;let m=async()=>{c(!0);try{await s(i),a()}catch(e){console.error("Export failed:",e)}finally{c(!1)}};return(0,t.jsx)("div",{className:"fixed inset-0 bg-black bg-opacity-50 flex items-center justify-center z-50",children:(0,t.jsxs)("div",{className:"bg-white rounded-lg shadow-xl max-w-md w-full mx-4",children:[(0,t.jsxs)("div",{className:"flex items-center justify-between p-6 border-b",children:[(0,t.jsx)("h2",{className:"text-xl font-semibold text-gray-800",children:"エクスポート設定"}),(0,t.jsx)("button",{onClick:a,className:"text-gray-400 hover:text-gray-600 transition-colors",children:(0,t.jsx)(p,{className:"w-5 h-5"})})]}),(0,t.jsxs)("div",{className:"p-6 space-y-6",children:[(0,t.jsxs)("div",{children:[(0,t.jsx)("label",{className:"block text-sm font-medium text-gray-700 mb-2",children:"出力先パス"}),(0,t.jsx)("div",{className:"px-3 py-2 bg-gray-50 border border-gray-300 rounded-md text-sm text-gray-700 font-mono break-all",children:h}),(0,t.jsx)("p",{className:"mt-1 text-xs text-gray-500",children:"html"===i.format?"HTMLファイルの出力先":"markdown-table"===i.format?"Markdownテーブル形式ファイルの出力先":"Markdownファイルの出力先"})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("label",{className:"block text-sm font-medium text-gray-700 mb-2",children:"ファイル名"}),(0,t.jsx)("input",{type:"text",value:i.fileName||"config-doc",onChange:e=>n({...i,fileName:e.target.value}),className:"w-full px-3 py-2 border border-gray-300 rounded-md focus:outline-none focus:ring-2 focus:ring-blue-500",placeholder:"config-doc"}),(0,t.jsx)("p",{className:"mt-1 text-xs text-gray-500",children:"拡張子なしのファイル名を指定します(チーム共有設定)"})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("label",{className:"block text-sm font-medium text-gray-700 mb-2",children:"出力形式"}),(0,t.jsxs)("select",{value:i.format,onChange:e=>n({...i,format:e.target.value}),className:"w-full px-3 py-2 border border-gray-300 rounded-md focus:outline-none focus:ring-2 focus:ring-blue-500",children:[(0,t.jsx)("option",{value:"html",children:"HTML"}),(0,t.jsx)("option",{value:"markdown",children:"Markdown"}),(0,t.jsx)("option",{value:"markdown-table",children:"Markdown (テーブル形式)"})]}),(0,t.jsx)("p",{className:"mt-1 text-xs text-gray-500",children:"html"===i.format?"スタイル付きのHTMLファイルとして出力します":"markdown-table"===i.format?"Markdownテーブル形式で出力します(プロパティ名、説明、値、備考)":"テキストベースのMarkdownファイルとして出力します"})]}),(0,t.jsxs)("div",{className:"flex items-start",children:[(0,t.jsx)("div",{className:"flex items-center h-5",children:(0,t.jsx)("input",{id:"auto-export",type:"checkbox",checked:i.autoExport,onChange:e=>n({...i,autoExport:e.target.checked}),className:"w-4 h-4 text-blue-600 border-gray-300 rounded focus:ring-blue-500"})}),(0,t.jsxs)("div",{className:"ml-3",children:[(0,t.jsx)("label",{htmlFor:"auto-export",className:"text-sm font-medium text-gray-700 cursor-pointer",children:"保存時に自動エクスポート"}),(0,t.jsx)("p",{className:"text-xs text-gray-500 mt-1",children:"ドキュメントを保存したときに自動的にHTMLファイルを更新します"})]})]}),i.lastExportedAt&&(0,t.jsx)("div",{className:"pt-4 border-t",children:(0,t.jsxs)("p",{className:"text-xs text-gray-500",children:["最終エクスポート: ",new Date(i.lastExportedAt).toLocaleString("ja-JP")]})})]}),(0,t.jsxs)("div",{className:"flex items-center justify-end gap-3 p-6 border-t bg-gray-50 rounded-b-lg",children:[(0,t.jsx)("button",{onClick:a,className:"px-4 py-2 text-sm font-medium text-gray-700 bg-white border border-gray-300 rounded-md hover:bg-gray-50 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-blue-500",children:"キャンセル"}),(0,t.jsxs)("button",{onClick:m,disabled:d,className:"flex items-center gap-2 px-4 py-2 text-sm font-medium text-white bg-blue-600 border border-transparent rounded-md hover:bg-blue-700 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-blue-500 disabled:opacity-50 disabled:cursor-not-allowed",children:[(0,t.jsx)(b,{className:"w-4 h-4"}),d?"エクスポート中...":"エクスポート"]})]})]})})}let w=i("circle-check-big",[["path",{d:"M21.801 10A10 10 0 1 1 17 3.335",key:"yps3ct"}],["path",{d:"m9 11 3 3L22 4",key:"1pflzl"}]]),N=i("circle-x",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m15 9-6 6",key:"1uzhvr"}],["path",{d:"m9 9 6 6",key:"z0biqf"}]]),v=i("circle-alert",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["line",{x1:"12",x2:"12",y1:"8",y2:"12",key:"1pkeuh"}],["line",{x1:"12",x2:"12.01",y1:"16",y2:"16",key:"4dfq90"}]]);function k({message:e,type:a,duration:s=3e3,onClose:l}){let[o,i]=(0,r.useState)(!1);(0,r.useEffect)(()=>{setTimeout(()=>i(!0),10);let e=setTimeout(()=>{i(!1),setTimeout(l,300)},s);return()=>clearTimeout(e)},[s,l]);let n={success:(0,t.jsx)(w,{className:"w-5 h-5 text-green-500"}),error:(0,t.jsx)(N,{className:"w-5 h-5 text-red-500"}),warning:(0,t.jsx)(v,{className:"w-5 h-5 text-yellow-500"})};return(0,t.jsx)("div",{className:`fixed bottom-4 left-4 z-50 transition-all duration-300 ${o?"opacity-100 translate-y-0":"opacity-0 translate-y-2"}`,children:(0,t.jsxs)("div",{className:`flex items-center gap-3 px-4 py-3 rounded-lg shadow-lg border ${{success:"bg-green-50 border-green-200",error:"bg-red-50 border-red-200",warning:"bg-yellow-50 border-yellow-200"}[a]} min-w-[300px] max-w-[500px]`,children:[n[a],(0,t.jsx)("span",{className:"flex-1 text-sm text-gray-800",children:e}),(0,t.jsx)("button",{onClick:()=>{i(!1),setTimeout(l,300)},className:"text-gray-400 hover:text-gray-600 transition-colors",children:(0,t.jsx)(p,{className:"w-4 h-4"})})]})})}function S({toasts:e,onRemove:r}){return(0,t.jsx)(t.Fragment,{children:e.map((e,a)=>(0,t.jsx)("div",{style:{bottom:`${16+80*a}px`},className:"fixed left-4 z-50",children:(0,t.jsx)(k,{message:e.message,type:e.type,onClose:()=>r(e.id)})},e.id))})}let C=i("folder-open",[["path",{d:"m6 14 1.5-2.9A2 2 0 0 1 9.24 10H20a2 2 0 0 1 1.94 2.5l-1.54 6a2 2 0 0 1-1.95 1.5H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h3.9a2 2 0 0 1 1.69.9l.81 1.2a2 2 0 0 0 1.67.9H18a2 2 0 0 1 2 2v2",key:"usdka0"}]]),P=i("save",[["path",{d:"M15.2 3a2 2 0 0 1 1.4.6l3.8 3.8a2 2 0 0 1 .6 1.4V19a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2z",key:"1c8476"}],["path",{d:"M17 21v-7a1 1 0 0 0-1-1H8a1 1 0 0 0-1 1v7",key:"1ydtos"}],["path",{d:"M7 3v4a1 1 0 0 0 1 1h7",key:"t51u73"}]]);function T(){let[e,a]=(0,r.useState)([]),[s,l]=(0,r.useState)(0),[o,i]=(0,r.useState)(""),[n,d]=(0,r.useState)(!1),[h,x]=(0,r.useState)(!1),[u,f]=(0,r.useState)(!1),[y,w]=(0,r.useState)("."),[N,v]=(0,r.useState)(null),[k,T]=(0,r.useState)(null),[O,A]=(0,r.useState)(!1),[M,$]=(0,r.useState)(),[E,D]=(0,r.useState)([]),z=(e,t="success")=>{let r=Date.now().toString();D(a=>[...a,{id:r,message:e,type:t}])},F=(e,t)=>!!e&&!!t&&(e.description!==t.description||e.notes!==t.notes),H=e[s];(0,r.useEffect)(()=>{(async()=>{try{let e=await fetch("/api/project"),t=await e.json();if(t.success&&(w(t.data.rootPath),t.data.hasConfigDoc)){let e=await fetch("/api/config/metadata"),t=await e.json();if(t.success&&t.data?.configFiles)for(let e of t.data.configFiles)await J(e.filePath)}let r=await fetch("/api/export/settings"),a=await r.json();a.success&&$(a.data)}catch(e){console.error("Failed to load saved configs:",e)}finally{f(!0)}})()},[]);let J=async e=>{try{let t=await fetch("/api/config/load",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({filePath:e})}),r=await t.json();r.success&&a(t=>t.some(t=>t.filePath===e)?t:[...t,{filePath:e,configData:r.data.configData,docs:r.data.docs}])}catch(e){console.error("Failed to load config file:",e)}},L=async e=>{try{let t=await fetch("/api/config/metadata",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({configFilePaths:e})}),r=await t.json();r.deletedDocsFiles&&r.deletedDocsFiles.length>0&&z(`${r.deletedDocsFiles.length}件のドキュメントファイルを削除しました`,"warning")}catch(e){console.error("Failed to update metadata:",e)}},V=(e,t)=>{let r=e.replace(/\\/g,"/"),a=t.replace(/\\/g,"/");if(!r.match(/^[a-zA-Z]:\//)&&!r.startsWith("/"))return e;if(r.startsWith(a)){let e=r.substring(a.length);return e.startsWith("/")?e.substring(1):e}return e},W=async t=>{let r=[];for(let a of t){let t=V(a,y);if(!e.some(e=>e.filePath===t))try{let e=await fetch("/api/config/load",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({filePath:a})}),s=await e.json();s.success?r.push({filePath:t,configData:s.data.configData,docs:s.data.docs}):z(`設定ファイルの読み込みに失敗しました (${a}): ${s.error}`,"error")}catch(e){console.error("Failed to load config:",e),z(`設定ファイルの読み込み中にエラーが発生しました: ${a}`,"error")}}r.length>0&&a(e=>{let t=[...e,...r];return L(t.map(e=>e.filePath)),t})},q=async t=>{let r=e[t];(!r.docs||!(Object.keys(r.docs.properties).length>0)||confirm("既に説明文が設定されていますが、削除してよろしいですか?"))&&(a(e=>{let r=e.filter((e,r)=>r!==t);return L(r.map(e=>e.filePath)),r}),s>=t&&s>0&&l(s-1),i(""),v(null),A(!1))},I=e=>{if(O&&!confirm("保存されていない変更があります。破棄しますか?"))return;i(e);let t=H.docs.properties[e];if(t){let e={...t};v(e),T(e)}else{let t={path:e,description:"",notes:"",modifiedAt:new Date().toISOString()};v(t),T(t)}A(!1)},R=async()=>{if(N&&H)try{let e={...N,modifiedAt:new Date().toISOString()},t=await fetch("/api/config/save",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({configFilePath:H.filePath,propertyPath:o,propertyDoc:e})}),r=await t.json();r.success?(a(t=>t.map((t,r)=>r===s?{...t,docs:{...t.docs,properties:{...t.docs.properties,[o]:e}}}:t)),v(e),T(e),A(!1),z("保存しました"),M?.autoExport&&await U()):z("保存に失敗しました: "+r.error,"error")}catch(e){console.error("Failed to save:",e),z("保存中にエラーが発生しました","error")}},U=async()=>{if(M)try{if((await fetch("/api/export",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({format:M.format,fileName:M.fileName})})).ok){let e={...M,lastExportedAt:new Date().toISOString()};$(e),await fetch("/api/export/settings",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({settings:e})})}}catch(e){console.error("Auto export failed:",e)}},Z=async e=>{try{let t=await fetch("/api/export",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({format:e.format,fileName:e.fileName})}),r=await t.json();if(r.success){let t={...e,lastExportedAt:new Date().toISOString()};$(t),await fetch("/api/export/settings",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({settings:t})}),z(`エクスポートしました: ${r.outputPath}`)}else z("エクスポートに失敗しました: "+r.error,"error")}catch(e){console.error("Export failed:",e),z("エクスポート中にエラーが発生しました","error")}};return(0,t.jsxs)("div",{className:"min-h-screen bg-gradient-to-br from-blue-50 via-indigo-50 to-purple-50",children:[(0,t.jsx)("header",{className:"bg-white/80 backdrop-blur-md border-b border-gray-200 shadow-sm sticky top-0 z-50",children:(0,t.jsxs)("div",{className:"container mx-auto px-6 py-4 flex items-center justify-between",children:[(0,t.jsxs)("div",{className:"flex items-center gap-3",children:[(0,t.jsx)("div",{className:"w-10 h-10 bg-gradient-to-br from-blue-600 to-purple-600 rounded-lg flex items-center justify-center shadow-lg",children:(0,t.jsx)(c,{className:"w-6 h-6 text-white"})}),(0,t.jsxs)("div",{children:[(0,t.jsx)("h1",{className:"text-2xl font-bold bg-gradient-to-r from-blue-600 to-purple-600 bg-clip-text text-transparent",children:"ConfigDoc"}),(0,t.jsx)("p",{className:"text-xs text-gray-500",children:"Configuration Documentation Tool"})]})]}),(0,t.jsxs)("button",{onClick:()=>x(!0),className:"flex items-center gap-2 px-5 py-2.5 bg-gradient-to-r from-green-500 to-emerald-600 text-white rounded-lg hover:from-green-600 hover:to-emerald-700 shadow-md hover:shadow-lg transition-all duration-200 transform hover:scale-105",title:"エクスポート",children:[(0,t.jsx)(b,{className:"w-5 h-5"}),(0,t.jsx)("span",{className:"font-medium",children:"エクスポート"})]})]})}),(0,t.jsxs)("main",{className:"container mx-auto px-6 py-8",children:[(0,t.jsxs)("div",{className:"bg-white/90 backdrop-blur-sm rounded-2xl shadow-xl border border-gray-100 p-6 mb-8 hover:shadow-2xl transition-shadow duration-300",children:[(0,t.jsxs)("div",{className:"flex items-center justify-between mb-4",children:[(0,t.jsxs)("div",{className:"flex items-center gap-2",children:[(0,t.jsx)("div",{className:"w-8 h-8 bg-gradient-to-br from-blue-500 to-blue-600 rounded-lg flex items-center justify-center",children:(0,t.jsx)(C,{className:"w-5 h-5 text-white"})}),(0,t.jsx)("h2",{className:"text-xl font-bold text-gray-800",children:"設定ファイル"})]}),(0,t.jsxs)("button",{onClick:()=>d(!0),className:"flex items-center gap-2 px-4 py-2 bg-gradient-to-r from-blue-500 to-blue-600 text-white rounded-lg hover:from-blue-600 hover:to-blue-700 shadow-md hover:shadow-lg transition-all duration-200 transform hover:scale-105",children:[(0,t.jsx)(C,{className:"w-5 h-5"}),(0,t.jsx)("span",{className:"font-medium",children:"ファイルを追加"})]})]}),e.length>0?(0,t.jsx)("div",{className:"flex flex-wrap gap-3",children:e.map((r,a)=>(0,t.jsxs)("div",{onClick:()=>{l(a),i(""),v(null),A(!1)},className:`group flex items-center gap-2 px-4 py-2.5 rounded-xl border-2 cursor-pointer transition-all duration-200 ${s===a?"bg-gradient-to-r from-blue-50 to-indigo-50 border-blue-400 shadow-md":"bg-white border-gray-200 hover:border-blue-300 hover:shadow-md"}`,children:[(0,t.jsx)("span",{className:`text-sm font-medium ${s===a?"text-blue-700":"text-gray-700"}`,children:((e,t)=>{let r=e.split(/[/\\]/).pop()||e,a=t.filter(e=>e.split(/[/\\]/).pop()===r);if(1===a.length)return r;let s=e.split(/[/\\]/);for(let t=1;t<s.length;t++){let r=s.slice(-t-1).join("/");if(0===a.filter(a=>r===a.split(/[/\\]/).slice(-t-1).join("/")&&a!==e).length)return r}return e})(r.filePath,e.map(e=>e.filePath))}),(0,t.jsx)("button",{onClick:e=>{e.stopPropagation(),q(a)},className:"text-gray-400 hover:text-red-500 transition-colors opacity-0 group-hover:opacity-100",children:(0,t.jsx)(p,{className:"w-4 h-4"})})]},r.filePath))}):(0,t.jsxs)("div",{className:"text-center py-12 bg-gradient-to-br from-gray-50 to-gray-100 rounded-xl border-2 border-dashed border-gray-300",children:[(0,t.jsx)(C,{className:"w-16 h-16 text-gray-400 mx-auto mb-3"}),(0,t.jsx)("p",{className:"text-sm text-gray-600 font-medium",children:"設定ファイルを選択してください"}),(0,t.jsx)("p",{className:"text-xs text-gray-500 mt-1",children:"「ファイルを追加」ボタンから開始"})]})]}),H&&(0,t.jsxs)("div",{className:"grid grid-cols-1 lg:grid-cols-2 gap-6",children:[(0,t.jsxs)("div",{className:"bg-white/90 backdrop-blur-sm rounded-2xl shadow-xl border border-gray-100 p-6 flex flex-col max-h-[calc(100vh-350px)] hover:shadow-2xl transition-shadow duration-300",children:[(0,t.jsxs)("div",{className:"flex items-center gap-2 mb-4",children:[(0,t.jsx)("div",{className:"w-8 h-8 bg-gradient-to-br from-purple-500 to-purple-600 rounded-lg flex items-center justify-center",children:(0,t.jsx)(c,{className:"w-5 h-5 text-white"})}),(0,t.jsx)("h2",{className:"text-xl font-bold text-gray-800",children:"JSON構造"})]}),(0,t.jsx)("div",{className:"overflow-y-auto flex-1",children:(0,t.jsx)(m,{config:H.configData,docs:H.docs,onSelectProperty:I,onEditProperty:I,selectedPath:o})})]}),(0,t.jsxs)("div",{className:"bg-white/90 backdrop-blur-sm rounded-2xl shadow-xl border border-gray-100 p-6 flex flex-col max-h-[calc(100vh-250px)] hover:shadow-2xl transition-shadow duration-300",children:[(0,t.jsxs)("div",{className:"flex items-center justify-between mb-4",children:[(0,t.jsxs)("div",{className:"flex items-center gap-2",children:[(0,t.jsx)("div",{className:"w-8 h-8 bg-gradient-to-br from-indigo-500 to-indigo-600 rounded-lg flex items-center justify-center",children:(0,t.jsx)(P,{className:"w-5 h-5 text-white"})}),(0,t.jsx)("h2",{className:"text-xl font-bold text-gray-800",children:"プロパティ詳細"})]}),O&&(0,t.jsxs)("button",{onClick:R,className:"flex items-center gap-2 px-4 py-2 bg-gradient-to-r from-green-500 to-emerald-600 text-white rounded-lg hover:from-green-600 hover:to-emerald-700 shadow-md hover:shadow-lg transition-all duration-200 transform hover:scale-105",children:[(0,t.jsx)(P,{className:"w-4 h-4"}),(0,t.jsx)("span",{className:"font-medium",children:"保存"})]})]}),(0,t.jsx)("div",{className:"overflow-y-auto flex-1",children:o&&N?(0,t.jsxs)("div",{className:"space-y-6",children:[(0,t.jsxs)("div",{children:[(0,t.jsx)("label",{className:"block text-sm font-semibold text-gray-700 mb-2",children:"パス"}),(0,t.jsx)("div",{className:"text-sm text-gray-700 bg-gradient-to-r from-blue-50 to-indigo-50 p-3 rounded-lg font-mono border border-blue-200 shadow-sm",children:o})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("label",{className:"block text-sm font-semibold text-gray-700 mb-2",children:"説明"}),(0,t.jsx)("textarea",{value:N.description,onChange:e=>{let t={...N,description:e.target.value};v(t),A(F(t,k))},className:"w-full border-2 border-gray-200 rounded-lg p-3 min-h-[120px] text-sm focus:border-blue-400 focus:ring-2 focus:ring-blue-200 transition-all duration-200 shadow-sm hover:shadow-md",placeholder:"このプロパティの説明を入力してください"})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("label",{className:"block text-sm font-semibold text-gray-700 mb-2",children:"備考"}),(0,t.jsx)("textarea",{value:N.notes,onChange:e=>{let t={...N,notes:e.target.value};v(t),A(F(t,k))},className:"w-full border-2 border-gray-200 rounded-lg p-3 min-h-[100px] text-sm focus:border-blue-400 focus:ring-2 focus:ring-blue-200 transition-all duration-200 shadow-sm hover:shadow-md",placeholder:"追加のメモや注意事項"})]})]}):(0,t.jsxs)("div",{className:"flex flex-col items-center justify-center py-20",children:[(0,t.jsx)("div",{className:"w-20 h-20 bg-gradient-to-br from-gray-100 to-gray-200 rounded-full flex items-center justify-center mb-4",children:(0,t.jsx)(c,{className:"w-10 h-10 text-gray-400"})}),(0,t.jsx)("p",{className:"text-sm text-gray-600 font-medium",children:"プロパティを選択してください"}),(0,t.jsx)("p",{className:"text-xs text-gray-500 mt-1",children:"左側のツリーから項目を選択"})]})})]})]})]}),(0,t.jsx)(g,{isOpen:n,currentPath:y,multiSelect:!0,filterJsonOnly:!0,onSelect:e=>{W(e),d(!1)},onClose:()=>d(!1)}),(0,t.jsx)(j,{isOpen:h,onClose:()=>x(!1),onExport:Z,currentSettings:M,rootPath:y}),(0,t.jsx)(S,{toasts:E,onRemove:e=>{D(t=>t.filter(t=>t.id!==e))}})]})}e.s(["default",()=>T],52211)}]);
@@ -0,0 +1 @@
1
+ (globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,52211,e=>{"use strict";var t=e.i(52420),r=e.i(20063);let a=e=>{let t=e.replace(/^([A-Z])|[\s-_]+(\w)/g,(e,t,r)=>r?r.toUpperCase():t.toLowerCase());return t.charAt(0).toUpperCase()+t.slice(1)},s=(...e)=>e.filter((e,t,r)=>!!e&&""!==e.trim()&&r.indexOf(e)===t).join(" ").trim();var l={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};let o=(0,r.forwardRef)(({color:e="currentColor",size:t=24,strokeWidth:a=2,absoluteStrokeWidth:o,className:i="",children:n,iconNode:d,...c},h)=>(0,r.createElement)("svg",{ref:h,...l,width:t,height:t,stroke:e,strokeWidth:o?24*Number(a)/Number(t):a,className:s("lucide",i),...!n&&!(e=>{for(let t in e)if(t.startsWith("aria-")||"role"===t||"title"===t)return!0})(c)&&{"aria-hidden":"true"},...c},[...d.map(([e,t])=>(0,r.createElement)(e,t)),...Array.isArray(n)?n:[n]])),i=(e,t)=>{let l=(0,r.forwardRef)(({className:l,...i},n)=>(0,r.createElement)(o,{ref:n,iconNode:t,className:s(`lucide-${a(e).replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase()}`,`lucide-${e}`,l),...i}));return l.displayName=a(e),l},n=i("chevron-right",[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]]),d=i("chevron-down",[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]]),c=i("file-text",[["path",{d:"M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z",key:"1oefj6"}],["path",{d:"M14 2v5a1 1 0 0 0 1 1h5",key:"wfsgrz"}],["path",{d:"M10 9H8",key:"b1mrlr"}],["path",{d:"M16 13H8",key:"t4e002"}],["path",{d:"M16 17H8",key:"z1uh3a"}]]);class h{static flattenConfig(e,t=""){let r={};for(let a in e){let s=t?`${t}:${a}`:a;e[a]&&"object"==typeof e[a]&&!Array.isArray(e[a])?Object.assign(r,this.flattenConfig(e[a],s)):r[s]=e[a]}return r}static buildTree(e,t=""){let r=[];for(let a in e){let s=t?`${t}:${a}`:a,l=e[a];l&&"object"==typeof l&&!Array.isArray(l)?r.push({key:a,fullPath:s,value:l,children:this.buildTree(l,s),hasDocumentation:!1,type:"object"}):r.push({key:a,fullPath:s,value:l,hasDocumentation:!1,type:Array.isArray(l)?"array":typeof l})}return r}}function m({config:e,docs:a,onSelectProperty:s,onEditProperty:l,selectedPath:o}){let[i,m]=(0,r.useState)(new Set),x=(e,r=0)=>{let h=void 0!==a.properties[e.fullPath],u=i.has(e.fullPath),f=o===e.fullPath;return(0,t.jsxs)("div",{children:[(0,t.jsxs)("div",{style:{paddingLeft:`${20*r}px`},className:`group flex items-center gap-2 py-2 px-3 cursor-pointer rounded-lg transition-all duration-150 ${f?"bg-gradient-to-r from-blue-100 to-indigo-100 border-l-4 border-blue-500 shadow-sm":"hover:bg-gradient-to-r hover:from-gray-50 hover:to-gray-100"}`,children:[e.children&&e.children.length>0?(0,t.jsx)("button",{onClick:()=>{var t;let r;return t=e.fullPath,void((r=new Set(i)).has(t)?r.delete(t):r.add(t),m(r))},className:"p-1 hover:bg-blue-100 rounded-md transition-colors",children:u?(0,t.jsx)(d,{className:"w-4 h-4 text-blue-600"}):(0,t.jsx)(n,{className:"w-4 h-4 text-gray-600"})}):(0,t.jsx)("div",{className:"w-6"}),(0,t.jsxs)("div",{onClick:()=>s(e.fullPath),className:"flex-1 flex items-center gap-2",children:[(0,t.jsx)("span",{className:`${e.children?"font-bold text-gray-800":"font-medium text-gray-700"}`,children:e.key}),!e.children&&(0,t.jsxs)("span",{className:"text-sm text-gray-500 truncate max-w-[200px]",children:[": ",JSON.stringify(e.value)]}),h&&(0,t.jsxs)("div",{className:"flex items-center gap-1 px-2 py-0.5 bg-green-100 border border-green-300 rounded-full",children:[(0,t.jsx)(c,{className:"w-3 h-3 text-green-600"}),(0,t.jsx)("span",{className:"text-xs text-green-700 font-medium",children:"Doc"})]})]}),!e.children&&(0,t.jsx)("button",{onClick:t=>{t.stopPropagation(),l(e.fullPath)},className:"p-1 hover:bg-gray-200 rounded",title:"編集"})]}),e.children&&u&&(0,t.jsx)("div",{children:e.children.map(e=>x(e,r+1))})]},e.fullPath)},u=h.buildTree(e);return(0,t.jsxs)("div",{className:"h-full flex flex-col border-2 border-gray-100 rounded-xl bg-white shadow-sm",children:[(0,t.jsxs)("div",{className:"flex items-center gap-2 p-3 border-b-2 border-gray-100 bg-gradient-to-r from-gray-50 to-gray-100",children:[(0,t.jsx)("button",{onClick:()=>{var t;let r,a;m(new Set((t=h.buildTree(e),r=[],a=e=>{e.children&&e.children.length>0&&(r.push(e.fullPath),e.children.forEach(a))},t.forEach(a),r)))},className:"px-4 py-1.5 text-sm font-medium bg-white border-2 border-blue-200 text-blue-600 rounded-lg hover:bg-blue-50 hover:border-blue-300 transition-all duration-200 shadow-sm hover:shadow-md",children:"すべて展開"}),(0,t.jsx)("button",{onClick:()=>{m(new Set)},className:"px-4 py-1.5 text-sm font-medium bg-white border-2 border-gray-200 text-gray-600 rounded-lg hover:bg-gray-50 hover:border-gray-300 transition-all duration-200 shadow-sm hover:shadow-md",children:"すべて閉じる"})]}),(0,t.jsx)("div",{className:"flex-1 overflow-y-auto p-3",children:u.map(e=>x(e))})]})}let x=i("folder",[["path",{d:"M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z",key:"1kt360"}]]),u=i("file",[["path",{d:"M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z",key:"1oefj6"}],["path",{d:"M14 2v5a1 1 0 0 0 1 1h5",key:"wfsgrz"}]]),f=i("arrow-up",[["path",{d:"m5 12 7-7 7 7",key:"hav0vg"}],["path",{d:"M12 19V5",key:"x0mq9r"}]]);function g({isOpen:e,currentPath:a,onSelect:s,onClose:l,multiSelect:o=!1,filterJsonOnly:i=!1}){let[n,d]=(0,r.useState)(a),[c,h]=(0,r.useState)([]),[m,g]=(0,r.useState)(!1),[p,b]=(0,r.useState)([]);(0,r.useEffect)(()=>{e&&(d(a),b([]))},[e,a]),(0,r.useEffect)(()=>{e&&y(n)},[e,n]);let y=async e=>{g(!0);try{let t=await fetch("/api/files/browse",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({directory:e})}),r=await t.json();if(r.success){let e=i?r.data.items.filter(e=>"directory"===e.type||".json"===e.extension):r.data.items;h(e)}else console.error("API returned error:",r.error)}catch(e){console.error("Failed to load directory:",e)}finally{g(!1)}},j=()=>{b([]),l()};return e?(0,t.jsx)("div",{className:"fixed inset-0 bg-black bg-opacity-50 flex items-center justify-center z-50",children:(0,t.jsxs)("div",{className:"bg-white rounded-lg shadow-xl w-full max-w-2xl max-h-[80vh] flex flex-col",children:[(0,t.jsxs)("div",{className:"flex items-center justify-between p-4 border-b",children:[(0,t.jsx)("h2",{className:"text-lg font-semibold",children:"ファイルを選択"}),(0,t.jsx)("button",{onClick:j,className:"text-gray-500 hover:text-gray-700",children:"✕"})]}),(0,t.jsxs)("div",{className:"flex items-center gap-2 p-4 border-b bg-gray-50",children:[(0,t.jsx)("button",{onClick:()=>{let e=n.replace(/\//g,"\\").split("\\").filter(e=>e);if(e.length>1){let t=e.slice(0,-1);d(1===t.length&&t[0].includes(":")?t[0]+"\\":t[0].includes(":")?t[0]+"\\"+t.slice(1).join("\\"):t.join("\\"))}else 1!==e.length||e[0].includes(":")||d(".")},className:"p-2 hover:bg-gray-200 rounded flex-shrink-0",title:"上のディレクトリへ",children:(0,t.jsx)(f,{className:"w-5 h-5"})}),(0,t.jsxs)("span",{className:"text-sm text-gray-600 flex-1 truncate",children:["パス: ",n]})]}),(0,t.jsx)("div",{className:"flex-1 overflow-y-auto p-4",children:m?(0,t.jsx)("div",{className:"text-center text-gray-500",children:"読み込み中..."}):(0,t.jsx)("div",{className:"space-y-1",children:c.map(e=>{let r=p.includes(e.path);return(0,t.jsxs)("div",{onClick:()=>{"directory"===e.type?d(e.path):o?b(t=>t.includes(e.path)?t.filter(t=>t!==e.path):[...t,e.path]):b([e.path])},className:`flex items-center gap-2 p-2 rounded cursor-pointer hover:bg-gray-100 ${r?"bg-blue-100":""}`,children:["directory"===e.type?(0,t.jsx)(x,{className:"w-5 h-5 text-blue-500"}):(0,t.jsx)(u,{className:"w-5 h-5 text-green-500"}),(0,t.jsx)("span",{className:"text-sm",children:e.name}),r&&o&&(0,t.jsx)("span",{className:"ml-auto text-blue-500",children:"✓"})]},e.path)})})}),(0,t.jsxs)("div",{className:"flex items-center justify-between p-4 border-t",children:[o&&p.length>0&&(0,t.jsxs)("div",{className:"text-sm text-gray-600",children:[p.length,"件選択中"]}),(0,t.jsxs)("div",{className:"flex items-center gap-2 ml-auto",children:[(0,t.jsx)("button",{onClick:j,className:"px-4 py-2 text-gray-600 hover:bg-gray-100 rounded",children:"キャンセル"}),(0,t.jsx)("button",{onClick:()=>{p.length>0&&(s(p),b([]),l())},disabled:0===p.length,className:"px-4 py-2 bg-blue-500 text-white rounded hover:bg-blue-600 disabled:bg-gray-300 disabled:cursor-not-allowed",children:"選択"})]})]})]})}):null}let p=i("x",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]]),b=i("download",[["path",{d:"M12 15V3",key:"m9g1x1"}],["path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4",key:"ih7n3h"}],["path",{d:"m7 10 5 5 5-5",key:"brsn70"}]]),y={format:"html",autoExport:!0,fileName:"config-doc"};function j({isOpen:e,onClose:a,onExport:s,currentSettings:l,rootPath:o="."}){let[i,n]=(0,r.useState)(l||y),[d,c]=(0,r.useState)(!1);(0,r.useEffect)(()=>{l&&n(l)},[l]);let h=(0,r.useMemo)(()=>{let e=o.replace(/\//g,"\\"),t=i.fileName||"config-doc",r="markdown"===i.format||"markdown-table"===i.format?"md":"html";return`${e}\\.config_doc\\output\\${t}.${r}`},[i.format,i.fileName,o]);if(!e)return null;let m=async()=>{c(!0);try{await s(i),a()}catch(e){console.error("Export failed:",e)}finally{c(!1)}};return(0,t.jsx)("div",{className:"fixed inset-0 bg-black bg-opacity-50 flex items-center justify-center z-50",children:(0,t.jsxs)("div",{className:"bg-white rounded-lg shadow-xl max-w-md w-full mx-4",children:[(0,t.jsxs)("div",{className:"flex items-center justify-between p-6 border-b",children:[(0,t.jsx)("h2",{className:"text-xl font-semibold text-gray-800",children:"エクスポート設定"}),(0,t.jsx)("button",{onClick:a,className:"text-gray-400 hover:text-gray-600 transition-colors",children:(0,t.jsx)(p,{className:"w-5 h-5"})})]}),(0,t.jsxs)("div",{className:"p-6 space-y-6",children:[(0,t.jsxs)("div",{children:[(0,t.jsx)("label",{className:"block text-sm font-medium text-gray-700 mb-2",children:"出力先パス"}),(0,t.jsx)("div",{className:"px-3 py-2 bg-gray-50 border border-gray-300 rounded-md text-sm text-gray-700 font-mono break-all",children:h}),(0,t.jsx)("p",{className:"mt-1 text-xs text-gray-500",children:"html"===i.format?"HTMLファイルの出力先":"markdown-table"===i.format?"Markdownテーブル形式ファイルの出力先":"Markdownファイルの出力先"})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("label",{className:"block text-sm font-medium text-gray-700 mb-2",children:"ファイル名"}),(0,t.jsx)("input",{type:"text",value:i.fileName||"config-doc",onChange:e=>n({...i,fileName:e.target.value}),className:"w-full px-3 py-2 border border-gray-300 rounded-md focus:outline-none focus:ring-2 focus:ring-blue-500",placeholder:"config-doc"}),(0,t.jsx)("p",{className:"mt-1 text-xs text-gray-500",children:"拡張子なしのファイル名を指定します(チーム共有設定)"})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("label",{className:"block text-sm font-medium text-gray-700 mb-2",children:"出力形式"}),(0,t.jsxs)("select",{value:i.format,onChange:e=>n({...i,format:e.target.value}),className:"w-full px-3 py-2 border border-gray-300 rounded-md focus:outline-none focus:ring-2 focus:ring-blue-500",children:[(0,t.jsx)("option",{value:"html",children:"HTML"}),(0,t.jsx)("option",{value:"markdown",children:"Markdown"}),(0,t.jsx)("option",{value:"markdown-table",children:"Markdown (テーブル形式)"})]}),(0,t.jsx)("p",{className:"mt-1 text-xs text-gray-500",children:"html"===i.format?"スタイル付きのHTMLファイルとして出力します":"markdown-table"===i.format?"Markdownテーブル形式で出力します(プロパティ名、説明、値、備考)":"テキストベースのMarkdownファイルとして出力します"})]}),(0,t.jsxs)("div",{className:"flex items-start",children:[(0,t.jsx)("div",{className:"flex items-center h-5",children:(0,t.jsx)("input",{id:"auto-export",type:"checkbox",checked:i.autoExport,onChange:e=>n({...i,autoExport:e.target.checked}),className:"w-4 h-4 text-blue-600 border-gray-300 rounded focus:ring-blue-500"})}),(0,t.jsxs)("div",{className:"ml-3",children:[(0,t.jsx)("label",{htmlFor:"auto-export",className:"text-sm font-medium text-gray-700 cursor-pointer",children:"保存時に自動エクスポート"}),(0,t.jsx)("p",{className:"text-xs text-gray-500 mt-1",children:"ドキュメントを保存したときに自動的にHTMLファイルを更新します"})]})]}),i.lastExportedAt&&(0,t.jsx)("div",{className:"pt-4 border-t",children:(0,t.jsxs)("p",{className:"text-xs text-gray-500",children:["最終エクスポート: ",new Date(i.lastExportedAt).toLocaleString("ja-JP")]})})]}),(0,t.jsxs)("div",{className:"flex items-center justify-end gap-3 p-6 border-t bg-gray-50 rounded-b-lg",children:[(0,t.jsx)("button",{onClick:a,className:"px-4 py-2 text-sm font-medium text-gray-700 bg-white border border-gray-300 rounded-md hover:bg-gray-50 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-blue-500",children:"キャンセル"}),(0,t.jsxs)("button",{onClick:m,disabled:d,className:"flex items-center gap-2 px-4 py-2 text-sm font-medium text-white bg-blue-600 border border-transparent rounded-md hover:bg-blue-700 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-blue-500 disabled:opacity-50 disabled:cursor-not-allowed",children:[(0,t.jsx)(b,{className:"w-4 h-4"}),d?"エクスポート中...":"エクスポート"]})]})]})})}let w=i("circle-check-big",[["path",{d:"M21.801 10A10 10 0 1 1 17 3.335",key:"yps3ct"}],["path",{d:"m9 11 3 3L22 4",key:"1pflzl"}]]),N=i("circle-x",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m15 9-6 6",key:"1uzhvr"}],["path",{d:"m9 9 6 6",key:"z0biqf"}]]),v=i("circle-alert",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["line",{x1:"12",x2:"12",y1:"8",y2:"12",key:"1pkeuh"}],["line",{x1:"12",x2:"12.01",y1:"16",y2:"16",key:"4dfq90"}]]);function k({message:e,type:a,duration:s=3e3,onClose:l}){let[o,i]=(0,r.useState)(!1);(0,r.useEffect)(()=>{setTimeout(()=>i(!0),10);let e=setTimeout(()=>{i(!1),setTimeout(l,300)},s);return()=>clearTimeout(e)},[s,l]);let n={success:(0,t.jsx)(w,{className:"w-5 h-5 text-green-500"}),error:(0,t.jsx)(N,{className:"w-5 h-5 text-red-500"}),warning:(0,t.jsx)(v,{className:"w-5 h-5 text-yellow-500"})};return(0,t.jsx)("div",{className:`fixed bottom-4 left-4 z-50 transition-all duration-300 ${o?"opacity-100 translate-y-0":"opacity-0 translate-y-2"}`,children:(0,t.jsxs)("div",{className:`flex items-center gap-3 px-4 py-3 rounded-lg shadow-lg border ${{success:"bg-green-50 border-green-200",error:"bg-red-50 border-red-200",warning:"bg-yellow-50 border-yellow-200"}[a]} min-w-[300px] max-w-[500px]`,children:[n[a],(0,t.jsx)("span",{className:"flex-1 text-sm text-gray-800",children:e}),(0,t.jsx)("button",{onClick:()=>{i(!1),setTimeout(l,300)},className:"text-gray-400 hover:text-gray-600 transition-colors",children:(0,t.jsx)(p,{className:"w-4 h-4"})})]})})}function S({toasts:e,onRemove:r}){return(0,t.jsx)(t.Fragment,{children:e.map((e,a)=>(0,t.jsx)("div",{style:{bottom:`${16+80*a}px`},className:"fixed left-4 z-50",children:(0,t.jsx)(k,{message:e.message,type:e.type,onClose:()=>r(e.id)})},e.id))})}let C=i("folder-open",[["path",{d:"m6 14 1.5-2.9A2 2 0 0 1 9.24 10H20a2 2 0 0 1 1.94 2.5l-1.54 6a2 2 0 0 1-1.95 1.5H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h3.9a2 2 0 0 1 1.69.9l.81 1.2a2 2 0 0 0 1.67.9H18a2 2 0 0 1 2 2v2",key:"usdka0"}]]),P=i("save",[["path",{d:"M15.2 3a2 2 0 0 1 1.4.6l3.8 3.8a2 2 0 0 1 .6 1.4V19a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2z",key:"1c8476"}],["path",{d:"M17 21v-7a1 1 0 0 0-1-1H8a1 1 0 0 0-1 1v7",key:"1ydtos"}],["path",{d:"M7 3v4a1 1 0 0 0 1 1h7",key:"t51u73"}]]);function T(){let[e,a]=(0,r.useState)([]),[s,l]=(0,r.useState)(0),[o,i]=(0,r.useState)(""),[n,d]=(0,r.useState)(!1),[h,x]=(0,r.useState)(!1),[u,f]=(0,r.useState)(!1),[y,w]=(0,r.useState)("."),[N,v]=(0,r.useState)(null),[k,T]=(0,r.useState)(null),[O,A]=(0,r.useState)(!1),[M,$]=(0,r.useState)(),[E,D]=(0,r.useState)([]),z=(e,t="success")=>{let r=Date.now().toString();D(a=>[...a,{id:r,message:e,type:t}])},F=(e,t)=>!!e&&!!t&&(e.description!==t.description||e.notes!==t.notes),H=e[s];(0,r.useEffect)(()=>{(async()=>{try{let e=await fetch("/api/project"),t=await e.json();if(t.success&&(w(t.data.rootPath),t.data.hasConfigDoc)){let e=await fetch("/api/config/metadata"),t=await e.json();if(t.success&&t.data?.configFiles)for(let e of t.data.configFiles)await J(e.filePath)}let r=await fetch("/api/export/settings"),a=await r.json();a.success&&$(a.data)}catch(e){console.error("Failed to load saved configs:",e)}finally{f(!0)}})()},[]);let J=async e=>{try{let t=await fetch("/api/config/load",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({filePath:e})}),r=await t.json();r.success&&a(t=>t.some(t=>t.filePath===e)?t:[...t,{filePath:e,configData:r.data.configData,docs:r.data.docs}])}catch(e){console.error("Failed to load config file:",e)}},L=async e=>{try{let t=await fetch("/api/config/metadata",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({configFilePaths:e})}),r=await t.json();r.deletedDocsFiles&&r.deletedDocsFiles.length>0&&z(`${r.deletedDocsFiles.length}件のドキュメントファイルを削除しました`,"warning")}catch(e){console.error("Failed to update metadata:",e)}},V=(e,t)=>{let r=e.replace(/\\/g,"/"),a=t.replace(/\\/g,"/");if(!r.match(/^[a-zA-Z]:\//)&&!r.startsWith("/"))return e;if(r.startsWith(a)){let e=r.substring(a.length);return e.startsWith("/")?e.substring(1):e}return e},W=async t=>{let r=[];for(let a of t){let t=V(a,y);if(!e.some(e=>e.filePath===t))try{let e=await fetch("/api/config/load",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({filePath:a})}),s=await e.json();s.success?r.push({filePath:t,configData:s.data.configData,docs:s.data.docs}):z(`設定ファイルの読み込みに失敗しました (${a}): ${s.error}`,"error")}catch(e){console.error("Failed to load config:",e),z(`設定ファイルの読み込み中にエラーが発生しました: ${a}`,"error")}}r.length>0&&a(e=>{let t=[...e,...r];return L(t.map(e=>e.filePath)),t})},q=async t=>{let r=e[t];(!r.docs||!(Object.keys(r.docs.properties).length>0)||confirm("既に説明文が設定されていますが、削除してよろしいですか?"))&&(a(e=>{let r=e.filter((e,r)=>r!==t);return L(r.map(e=>e.filePath)),r}),s>=t&&s>0&&l(s-1),i(""),v(null),A(!1))},I=e=>{if(O&&!confirm("保存されていない変更があります。破棄しますか?"))return;i(e);let t=H.docs.properties[e];if(t){let e={...t};v(e),T(e)}else{let t={path:e,description:"",notes:"",modifiedAt:new Date().toISOString()};v(t),T(t)}A(!1)},R=async()=>{if(N&&H)try{let e={...N,modifiedAt:new Date().toISOString()},t=await fetch("/api/config/save",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({configFilePath:H.filePath,propertyPath:o,propertyDoc:e})}),r=await t.json();r.success?(a(t=>t.map((t,r)=>r===s?{...t,docs:{...t.docs,properties:{...t.docs.properties,[o]:e}}}:t)),v(e),T(e),A(!1),z("保存しました"),M?.autoExport&&await U()):z("保存に失敗しました: "+r.error,"error")}catch(e){console.error("Failed to save:",e),z("保存中にエラーが発生しました","error")}},U=async()=>{if(M)try{if((await fetch("/api/export",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({format:M.format,fileName:M.fileName})})).ok){let e={...M,lastExportedAt:new Date().toISOString()};$(e),await fetch("/api/export/settings",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({settings:e})})}}catch(e){console.error("Auto export failed:",e)}},Z=async e=>{try{let t=await fetch("/api/export",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({format:e.format,fileName:e.fileName})}),r=await t.json();if(r.success){let t={...e,lastExportedAt:new Date().toISOString()};$(t),await fetch("/api/export/settings",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({settings:t})}),z(`エクスポートしました: ${r.outputPath}`)}else z("エクスポートに失敗しました: "+r.error,"error")}catch(e){console.error("Export failed:",e),z("エクスポート中にエラーが発生しました","error")}};return(0,t.jsxs)("div",{className:"min-h-screen bg-gradient-to-br from-blue-50 via-indigo-50 to-purple-50",children:[(0,t.jsx)("header",{className:"bg-white/80 backdrop-blur-md border-b border-gray-200 shadow-sm sticky top-0 z-50",children:(0,t.jsxs)("div",{className:"container mx-auto px-6 py-4 flex items-center justify-between",children:[(0,t.jsxs)("div",{className:"flex items-center gap-3",children:[(0,t.jsx)("div",{className:"w-10 h-10 bg-gradient-to-br from-blue-600 to-purple-600 rounded-lg flex items-center justify-center shadow-lg",children:(0,t.jsx)(c,{className:"w-6 h-6 text-white"})}),(0,t.jsxs)("div",{children:[(0,t.jsx)("h1",{className:"text-2xl font-bold bg-gradient-to-r from-blue-600 to-purple-600 bg-clip-text text-transparent",children:"ConfigDoc"}),(0,t.jsx)("p",{className:"text-xs text-gray-500",children:"Configuration Documentation Tool"})]})]}),(0,t.jsxs)("button",{onClick:()=>x(!0),className:"flex items-center gap-2 px-5 py-2.5 bg-gradient-to-r from-green-500 to-emerald-600 text-white rounded-lg hover:from-green-600 hover:to-emerald-700 shadow-md hover:shadow-lg transition-all duration-200 transform hover:scale-105",title:"エクスポート",children:[(0,t.jsx)(b,{className:"w-5 h-5"}),(0,t.jsx)("span",{className:"font-medium",children:"エクスポート"})]})]})}),(0,t.jsxs)("main",{className:"container mx-auto px-6 py-8",children:[(0,t.jsxs)("div",{className:"bg-white/90 backdrop-blur-sm rounded-2xl shadow-xl border border-gray-100 p-6 mb-8 hover:shadow-2xl transition-shadow duration-300",children:[(0,t.jsxs)("div",{className:"flex items-center justify-between mb-4",children:[(0,t.jsxs)("div",{className:"flex items-center gap-2",children:[(0,t.jsx)("div",{className:"w-8 h-8 bg-gradient-to-br from-blue-500 to-blue-600 rounded-lg flex items-center justify-center",children:(0,t.jsx)(C,{className:"w-5 h-5 text-white"})}),(0,t.jsx)("h2",{className:"text-xl font-bold text-gray-800",children:"設定ファイル"})]}),(0,t.jsxs)("button",{onClick:()=>d(!0),className:"flex items-center gap-2 px-4 py-2 bg-gradient-to-r from-blue-500 to-blue-600 text-white rounded-lg hover:from-blue-600 hover:to-blue-700 shadow-md hover:shadow-lg transition-all duration-200 transform hover:scale-105",children:[(0,t.jsx)(C,{className:"w-5 h-5"}),(0,t.jsx)("span",{className:"font-medium",children:"ファイルを追加"})]})]}),e.length>0?(0,t.jsx)("div",{className:"flex flex-wrap gap-3",children:e.map((r,a)=>(0,t.jsxs)("div",{onClick:()=>{l(a),i(""),v(null),A(!1)},className:`group flex items-center gap-2 px-4 py-2.5 rounded-xl border-2 cursor-pointer transition-all duration-200 ${s===a?"bg-gradient-to-r from-blue-50 to-indigo-50 border-blue-400 shadow-md":"bg-white border-gray-200 hover:border-blue-300 hover:shadow-md"}`,children:[(0,t.jsx)("span",{className:`text-sm font-medium ${s===a?"text-blue-700":"text-gray-700"}`,children:((e,t)=>{let r=e.split(/[/\\]/).pop()||e,a=t.filter(e=>e.split(/[/\\]/).pop()===r);if(1===a.length)return r;let s=e.split(/[/\\]/);for(let t=1;t<s.length;t++){let r=s.slice(-t-1).join("/");if(0===a.filter(a=>r===a.split(/[/\\]/).slice(-t-1).join("/")&&a!==e).length)return r}return e})(r.filePath,e.map(e=>e.filePath))}),(0,t.jsx)("button",{onClick:e=>{e.stopPropagation(),q(a)},className:"text-gray-400 hover:text-red-500 transition-colors opacity-0 group-hover:opacity-100",children:(0,t.jsx)(p,{className:"w-4 h-4"})})]},r.filePath))}):(0,t.jsxs)("div",{className:"text-center py-12 bg-gradient-to-br from-gray-50 to-gray-100 rounded-xl border-2 border-dashed border-gray-300",children:[(0,t.jsx)(C,{className:"w-16 h-16 text-gray-400 mx-auto mb-3"}),(0,t.jsx)("p",{className:"text-sm text-gray-600 font-medium",children:"設定ファイルを選択してください"}),(0,t.jsx)("p",{className:"text-xs text-gray-500 mt-1",children:"「ファイルを追加」ボタンから開始"})]})]}),H&&(0,t.jsxs)("div",{className:"grid grid-cols-1 lg:grid-cols-2 gap-6",children:[(0,t.jsxs)("div",{className:"bg-white/90 backdrop-blur-sm rounded-2xl shadow-xl border border-gray-100 p-6 flex flex-col max-h-[calc(100vh-350px)] hover:shadow-2xl transition-shadow duration-300",children:[(0,t.jsxs)("div",{className:"flex items-center gap-2 mb-4",children:[(0,t.jsx)("div",{className:"w-8 h-8 bg-gradient-to-br from-purple-500 to-purple-600 rounded-lg flex items-center justify-center",children:(0,t.jsx)(c,{className:"w-5 h-5 text-white"})}),(0,t.jsx)("h2",{className:"text-xl font-bold text-gray-800",children:"JSON構造"})]}),(0,t.jsx)("div",{className:"overflow-y-auto flex-1",children:(0,t.jsx)(m,{config:H.configData,docs:H.docs,onSelectProperty:I,onEditProperty:I,selectedPath:o})})]}),(0,t.jsxs)("div",{className:"bg-white/90 backdrop-blur-sm rounded-2xl shadow-xl border border-gray-100 p-6 flex flex-col max-h-[calc(100vh-250px)] hover:shadow-2xl transition-shadow duration-300",children:[(0,t.jsxs)("div",{className:"flex items-center justify-between mb-4",children:[(0,t.jsxs)("div",{className:"flex items-center gap-2",children:[(0,t.jsx)("div",{className:"w-8 h-8 bg-gradient-to-br from-indigo-500 to-indigo-600 rounded-lg flex items-center justify-center",children:(0,t.jsx)(P,{className:"w-5 h-5 text-white"})}),(0,t.jsx)("h2",{className:"text-xl font-bold text-gray-800",children:"プロパティ詳細"})]}),O&&(0,t.jsxs)("button",{onClick:R,className:"flex items-center gap-2 px-4 py-2 bg-gradient-to-r from-green-500 to-emerald-600 text-white rounded-lg hover:from-green-600 hover:to-emerald-700 shadow-md hover:shadow-lg transition-all duration-200 transform hover:scale-105",children:[(0,t.jsx)(P,{className:"w-4 h-4"}),(0,t.jsx)("span",{className:"font-medium",children:"保存"})]})]}),(0,t.jsx)("div",{className:"overflow-y-auto flex-1",children:o&&N?(0,t.jsxs)("div",{className:"space-y-6",children:[(0,t.jsxs)("div",{children:[(0,t.jsx)("label",{className:"block text-sm font-semibold text-gray-700 mb-2",children:"パス"}),(0,t.jsx)("div",{className:"text-sm text-gray-700 bg-gradient-to-r from-blue-50 to-indigo-50 p-3 rounded-lg font-mono border border-blue-200 shadow-sm",children:o})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("label",{className:"block text-sm font-semibold text-gray-700 mb-2",children:"説明"}),(0,t.jsx)("textarea",{value:N.description,onChange:e=>{let t={...N,description:e.target.value};v(t),A(F(t,k))},className:"w-full border-2 border-gray-200 rounded-lg p-3 min-h-[120px] text-sm focus:border-blue-400 focus:ring-2 focus:ring-blue-200 transition-all duration-200 shadow-sm hover:shadow-md",placeholder:"このプロパティの説明を入力してください"})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("label",{className:"block text-sm font-semibold text-gray-700 mb-2",children:"備考"}),(0,t.jsx)("textarea",{value:N.notes,onChange:e=>{let t={...N,notes:e.target.value};v(t),A(F(t,k))},className:"w-full border-2 border-gray-200 rounded-lg p-3 min-h-[100px] text-sm focus:border-blue-400 focus:ring-2 focus:ring-blue-200 transition-all duration-200 shadow-sm hover:shadow-md",placeholder:"追加のメモや注意事項"})]})]}):(0,t.jsxs)("div",{className:"flex flex-col items-center justify-center py-20",children:[(0,t.jsx)("div",{className:"w-20 h-20 bg-gradient-to-br from-gray-100 to-gray-200 rounded-full flex items-center justify-center mb-4",children:(0,t.jsx)(c,{className:"w-10 h-10 text-gray-400"})}),(0,t.jsx)("p",{className:"text-sm text-gray-600 font-medium",children:"プロパティを選択してください"}),(0,t.jsx)("p",{className:"text-xs text-gray-500 mt-1",children:"左側のツリーから項目を選択"})]})})]})]})]}),(0,t.jsx)(g,{isOpen:n,currentPath:y,multiSelect:!0,filterJsonOnly:!0,onSelect:e=>{W(e),d(!1)},onClose:()=>d(!1)}),(0,t.jsx)(j,{isOpen:h,onClose:()=>x(!1),onExport:Z,currentSettings:M,rootPath:y}),(0,t.jsx)(S,{toasts:E,onRemove:e=>{D(t=>t.filter(t=>t.id!==e))}})]})}e.s(["default",()=>T],52211)}]);
@@ -1 +0,0 @@
1
- (globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,52211,e=>{"use strict";var t=e.i(52420),r=e.i(20063);let a=e=>{let t=e.replace(/^([A-Z])|[\s-_]+(\w)/g,(e,t,r)=>r?r.toUpperCase():t.toLowerCase());return t.charAt(0).toUpperCase()+t.slice(1)},s=(...e)=>e.filter((e,t,r)=>!!e&&""!==e.trim()&&r.indexOf(e)===t).join(" ").trim();var l={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};let o=(0,r.forwardRef)(({color:e="currentColor",size:t=24,strokeWidth:a=2,absoluteStrokeWidth:o,className:i="",children:n,iconNode:d,...c},h)=>(0,r.createElement)("svg",{ref:h,...l,width:t,height:t,stroke:e,strokeWidth:o?24*Number(a)/Number(t):a,className:s("lucide",i),...!n&&!(e=>{for(let t in e)if(t.startsWith("aria-")||"role"===t||"title"===t)return!0})(c)&&{"aria-hidden":"true"},...c},[...d.map(([e,t])=>(0,r.createElement)(e,t)),...Array.isArray(n)?n:[n]])),i=(e,t)=>{let l=(0,r.forwardRef)(({className:l,...i},n)=>(0,r.createElement)(o,{ref:n,iconNode:t,className:s(`lucide-${a(e).replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase()}`,`lucide-${e}`,l),...i}));return l.displayName=a(e),l},n=i("chevron-right",[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]]),d=i("chevron-down",[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]]),c=i("file-text",[["path",{d:"M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z",key:"1oefj6"}],["path",{d:"M14 2v5a1 1 0 0 0 1 1h5",key:"wfsgrz"}],["path",{d:"M10 9H8",key:"b1mrlr"}],["path",{d:"M16 13H8",key:"t4e002"}],["path",{d:"M16 17H8",key:"z1uh3a"}]]);class h{static flattenConfig(e,t=""){let r={};for(let a in e){let s=t?`${t}:${a}`:a;e[a]&&"object"==typeof e[a]&&!Array.isArray(e[a])?Object.assign(r,this.flattenConfig(e[a],s)):r[s]=e[a]}return r}static buildTree(e,t=""){let r=[];for(let a in e){let s=t?`${t}:${a}`:a,l=e[a];l&&"object"==typeof l&&!Array.isArray(l)?r.push({key:a,fullPath:s,value:l,children:this.buildTree(l,s),hasDocumentation:!1,type:"object"}):r.push({key:a,fullPath:s,value:l,hasDocumentation:!1,type:Array.isArray(l)?"array":typeof l})}return r}}function m({config:e,docs:a,onSelectProperty:s,onEditProperty:l,selectedPath:o}){let[i,m]=(0,r.useState)(new Set),x=(e,r=0)=>{let h=void 0!==a.properties[e.fullPath],u=i.has(e.fullPath),g=o===e.fullPath;return(0,t.jsxs)("div",{children:[(0,t.jsxs)("div",{style:{paddingLeft:`${20*r}px`},className:`group flex items-center gap-2 py-2 px-3 cursor-pointer rounded-lg transition-all duration-150 ${g?"bg-gradient-to-r from-blue-100 to-indigo-100 border-l-4 border-blue-500 shadow-sm":"hover:bg-gradient-to-r hover:from-gray-50 hover:to-gray-100"}`,children:[e.children&&e.children.length>0?(0,t.jsx)("button",{onClick:()=>{var t;let r;return t=e.fullPath,void((r=new Set(i)).has(t)?r.delete(t):r.add(t),m(r))},className:"p-1 hover:bg-blue-100 rounded-md transition-colors",children:u?(0,t.jsx)(d,{className:"w-4 h-4 text-blue-600"}):(0,t.jsx)(n,{className:"w-4 h-4 text-gray-600"})}):(0,t.jsx)("div",{className:"w-6"}),(0,t.jsxs)("div",{onClick:()=>s(e.fullPath),className:"flex-1 flex items-center gap-2",children:[(0,t.jsx)("span",{className:`${e.children?"font-bold text-gray-800":"font-medium text-gray-700"}`,children:e.key}),!e.children&&(0,t.jsxs)("span",{className:"text-sm text-gray-500 truncate max-w-[200px]",children:[": ",JSON.stringify(e.value)]}),h&&(0,t.jsxs)("div",{className:"flex items-center gap-1 px-2 py-0.5 bg-green-100 border border-green-300 rounded-full",children:[(0,t.jsx)(c,{className:"w-3 h-3 text-green-600"}),(0,t.jsx)("span",{className:"text-xs text-green-700 font-medium",children:"Doc"})]})]}),!e.children&&(0,t.jsx)("button",{onClick:t=>{t.stopPropagation(),l(e.fullPath)},className:"p-1 hover:bg-gray-200 rounded",title:"編集"})]}),e.children&&u&&(0,t.jsx)("div",{children:e.children.map(e=>x(e,r+1))})]},e.fullPath)},u=h.buildTree(e);return(0,t.jsxs)("div",{className:"h-full flex flex-col border-2 border-gray-100 rounded-xl bg-white shadow-sm",children:[(0,t.jsxs)("div",{className:"flex items-center gap-2 p-3 border-b-2 border-gray-100 bg-gradient-to-r from-gray-50 to-gray-100",children:[(0,t.jsx)("button",{onClick:()=>{var t;let r,a;m(new Set((t=h.buildTree(e),r=[],a=e=>{e.children&&e.children.length>0&&(r.push(e.fullPath),e.children.forEach(a))},t.forEach(a),r)))},className:"px-4 py-1.5 text-sm font-medium bg-white border-2 border-blue-200 text-blue-600 rounded-lg hover:bg-blue-50 hover:border-blue-300 transition-all duration-200 shadow-sm hover:shadow-md",children:"すべて展開"}),(0,t.jsx)("button",{onClick:()=>{m(new Set)},className:"px-4 py-1.5 text-sm font-medium bg-white border-2 border-gray-200 text-gray-600 rounded-lg hover:bg-gray-50 hover:border-gray-300 transition-all duration-200 shadow-sm hover:shadow-md",children:"すべて閉じる"})]}),(0,t.jsx)("div",{className:"flex-1 overflow-y-auto p-3",children:u.map(e=>x(e))})]})}let x=i("folder",[["path",{d:"M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z",key:"1kt360"}]]),u=i("file",[["path",{d:"M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z",key:"1oefj6"}],["path",{d:"M14 2v5a1 1 0 0 0 1 1h5",key:"wfsgrz"}]]),g=i("chevron-up",[["path",{d:"m18 15-6-6-6 6",key:"153udz"}]]);function f({isOpen:e,currentPath:a,onSelect:s,onClose:l,multiSelect:o=!1,filterJsonOnly:i=!1}){let[n,d]=(0,r.useState)(a),[c,h]=(0,r.useState)([]),[m,f]=(0,r.useState)(!1),[p,b]=(0,r.useState)([]);(0,r.useEffect)(()=>{e&&(d(a),b([]))},[e,a]),(0,r.useEffect)(()=>{e&&y(n)},[e,n]);let y=async e=>{f(!0);try{let t=await fetch("/api/files/browse",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({directory:e})}),r=await t.json();if(r.success){let e=i?r.data.items.filter(e=>"directory"===e.type||".json"===e.extension):r.data.items;h(e)}else console.error("API returned error:",r.error)}catch(e){console.error("Failed to load directory:",e)}finally{f(!1)}},j=()=>{b([]),l()};return e?(0,t.jsx)("div",{className:"fixed inset-0 bg-black bg-opacity-50 flex items-center justify-center z-50",children:(0,t.jsxs)("div",{className:"bg-white rounded-lg shadow-xl w-full max-w-2xl max-h-[80vh] flex flex-col",children:[(0,t.jsxs)("div",{className:"flex items-center justify-between p-4 border-b",children:[(0,t.jsx)("h2",{className:"text-lg font-semibold",children:"ファイルを選択"}),(0,t.jsx)("button",{onClick:j,className:"text-gray-500 hover:text-gray-700",children:"✕"})]}),(0,t.jsxs)("div",{className:"flex items-center gap-2 p-4 border-b bg-gray-50",children:[(0,t.jsx)("button",{onClick:()=>{let e=n.replace(/\//g,"\\").split("\\").filter(e=>e);if(e.length>1){let t=e.slice(0,-1);d(1===t.length&&t[0].includes(":")?t[0]+"\\":t[0].includes(":")?t[0]+"\\"+t.slice(1).join("\\"):t.join("\\"))}else 1!==e.length||e[0].includes(":")||d(".")},className:"p-2 hover:bg-gray-200 rounded flex-shrink-0",title:"上のディレクトリへ",children:(0,t.jsx)(g,{className:"w-5 h-5"})}),(0,t.jsxs)("span",{className:"text-sm text-gray-600 flex-1 truncate",children:["パス: ",n]})]}),(0,t.jsx)("div",{className:"flex-1 overflow-y-auto p-4",children:m?(0,t.jsx)("div",{className:"text-center text-gray-500",children:"読み込み中..."}):(0,t.jsx)("div",{className:"space-y-1",children:c.map(e=>{let r=p.includes(e.path);return(0,t.jsxs)("div",{onClick:()=>{"directory"===e.type?d(e.path):o?b(t=>t.includes(e.path)?t.filter(t=>t!==e.path):[...t,e.path]):b([e.path])},className:`flex items-center gap-2 p-2 rounded cursor-pointer hover:bg-gray-100 ${r?"bg-blue-100":""}`,children:["directory"===e.type?(0,t.jsx)(x,{className:"w-5 h-5 text-blue-500"}):(0,t.jsx)(u,{className:"w-5 h-5 text-green-500"}),(0,t.jsx)("span",{className:"text-sm",children:e.name}),r&&o&&(0,t.jsx)("span",{className:"ml-auto text-blue-500",children:"✓"})]},e.path)})})}),(0,t.jsxs)("div",{className:"flex items-center justify-between p-4 border-t",children:[o&&p.length>0&&(0,t.jsxs)("div",{className:"text-sm text-gray-600",children:[p.length,"件選択中"]}),(0,t.jsxs)("div",{className:"flex items-center gap-2 ml-auto",children:[(0,t.jsx)("button",{onClick:j,className:"px-4 py-2 text-gray-600 hover:bg-gray-100 rounded",children:"キャンセル"}),(0,t.jsx)("button",{onClick:()=>{p.length>0&&(s(p),b([]),l())},disabled:0===p.length,className:"px-4 py-2 bg-blue-500 text-white rounded hover:bg-blue-600 disabled:bg-gray-300 disabled:cursor-not-allowed",children:"選択"})]})]})]})}):null}let p=i("x",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]]),b=i("download",[["path",{d:"M12 15V3",key:"m9g1x1"}],["path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4",key:"ih7n3h"}],["path",{d:"m7 10 5 5 5-5",key:"brsn70"}]]),y={format:"html",autoExport:!0,fileName:"config-doc"};function j({isOpen:e,onClose:a,onExport:s,currentSettings:l,rootPath:o="."}){let[i,n]=(0,r.useState)(l||y),[d,c]=(0,r.useState)(!1);(0,r.useEffect)(()=>{l&&n(l)},[l]);let h=(0,r.useMemo)(()=>{let e=o.replace(/\//g,"\\"),t=i.fileName||"config-doc",r="markdown"===i.format||"markdown-table"===i.format?"md":"html";return`${e}\\.config_doc\\output\\${t}.${r}`},[i.format,i.fileName,o]);if(!e)return null;let m=async()=>{c(!0);try{await s(i),a()}catch(e){console.error("Export failed:",e)}finally{c(!1)}};return(0,t.jsx)("div",{className:"fixed inset-0 bg-black bg-opacity-50 flex items-center justify-center z-50",children:(0,t.jsxs)("div",{className:"bg-white rounded-lg shadow-xl max-w-md w-full mx-4",children:[(0,t.jsxs)("div",{className:"flex items-center justify-between p-6 border-b",children:[(0,t.jsx)("h2",{className:"text-xl font-semibold text-gray-800",children:"エクスポート設定"}),(0,t.jsx)("button",{onClick:a,className:"text-gray-400 hover:text-gray-600 transition-colors",children:(0,t.jsx)(p,{className:"w-5 h-5"})})]}),(0,t.jsxs)("div",{className:"p-6 space-y-6",children:[(0,t.jsxs)("div",{children:[(0,t.jsx)("label",{className:"block text-sm font-medium text-gray-700 mb-2",children:"出力先パス"}),(0,t.jsx)("div",{className:"px-3 py-2 bg-gray-50 border border-gray-300 rounded-md text-sm text-gray-700 font-mono break-all",children:h}),(0,t.jsx)("p",{className:"mt-1 text-xs text-gray-500",children:"html"===i.format?"HTMLファイルの出力先":"markdown-table"===i.format?"Markdownテーブル形式ファイルの出力先":"Markdownファイルの出力先"})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("label",{className:"block text-sm font-medium text-gray-700 mb-2",children:"ファイル名"}),(0,t.jsx)("input",{type:"text",value:i.fileName||"config-doc",onChange:e=>n({...i,fileName:e.target.value}),className:"w-full px-3 py-2 border border-gray-300 rounded-md focus:outline-none focus:ring-2 focus:ring-blue-500",placeholder:"config-doc"}),(0,t.jsx)("p",{className:"mt-1 text-xs text-gray-500",children:"拡張子なしのファイル名を指定します(チーム共有設定)"})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("label",{className:"block text-sm font-medium text-gray-700 mb-2",children:"出力形式"}),(0,t.jsxs)("select",{value:i.format,onChange:e=>n({...i,format:e.target.value}),className:"w-full px-3 py-2 border border-gray-300 rounded-md focus:outline-none focus:ring-2 focus:ring-blue-500",children:[(0,t.jsx)("option",{value:"html",children:"HTML"}),(0,t.jsx)("option",{value:"markdown",children:"Markdown"}),(0,t.jsx)("option",{value:"markdown-table",children:"Markdown (テーブル形式)"})]}),(0,t.jsx)("p",{className:"mt-1 text-xs text-gray-500",children:"html"===i.format?"スタイル付きのHTMLファイルとして出力します":"markdown-table"===i.format?"Markdownテーブル形式で出力します(プロパティ名、説明、値、備考)":"テキストベースのMarkdownファイルとして出力します"})]}),(0,t.jsxs)("div",{className:"flex items-start",children:[(0,t.jsx)("div",{className:"flex items-center h-5",children:(0,t.jsx)("input",{id:"auto-export",type:"checkbox",checked:i.autoExport,onChange:e=>n({...i,autoExport:e.target.checked}),className:"w-4 h-4 text-blue-600 border-gray-300 rounded focus:ring-blue-500"})}),(0,t.jsxs)("div",{className:"ml-3",children:[(0,t.jsx)("label",{htmlFor:"auto-export",className:"text-sm font-medium text-gray-700 cursor-pointer",children:"保存時に自動エクスポート"}),(0,t.jsx)("p",{className:"text-xs text-gray-500 mt-1",children:"ドキュメントを保存したときに自動的にHTMLファイルを更新します"})]})]}),i.lastExportedAt&&(0,t.jsx)("div",{className:"pt-4 border-t",children:(0,t.jsxs)("p",{className:"text-xs text-gray-500",children:["最終エクスポート: ",new Date(i.lastExportedAt).toLocaleString("ja-JP")]})})]}),(0,t.jsxs)("div",{className:"flex items-center justify-end gap-3 p-6 border-t bg-gray-50 rounded-b-lg",children:[(0,t.jsx)("button",{onClick:a,className:"px-4 py-2 text-sm font-medium text-gray-700 bg-white border border-gray-300 rounded-md hover:bg-gray-50 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-blue-500",children:"キャンセル"}),(0,t.jsxs)("button",{onClick:m,disabled:d,className:"flex items-center gap-2 px-4 py-2 text-sm font-medium text-white bg-blue-600 border border-transparent rounded-md hover:bg-blue-700 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-blue-500 disabled:opacity-50 disabled:cursor-not-allowed",children:[(0,t.jsx)(b,{className:"w-4 h-4"}),d?"エクスポート中...":"エクスポート"]})]})]})})}let w=i("circle-check-big",[["path",{d:"M21.801 10A10 10 0 1 1 17 3.335",key:"yps3ct"}],["path",{d:"m9 11 3 3L22 4",key:"1pflzl"}]]),N=i("circle-x",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m15 9-6 6",key:"1uzhvr"}],["path",{d:"m9 9 6 6",key:"z0biqf"}]]),v=i("circle-alert",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["line",{x1:"12",x2:"12",y1:"8",y2:"12",key:"1pkeuh"}],["line",{x1:"12",x2:"12.01",y1:"16",y2:"16",key:"4dfq90"}]]);function k({message:e,type:a,duration:s=3e3,onClose:l}){let[o,i]=(0,r.useState)(!1);(0,r.useEffect)(()=>{setTimeout(()=>i(!0),10);let e=setTimeout(()=>{i(!1),setTimeout(l,300)},s);return()=>clearTimeout(e)},[s,l]);let n={success:(0,t.jsx)(w,{className:"w-5 h-5 text-green-500"}),error:(0,t.jsx)(N,{className:"w-5 h-5 text-red-500"}),warning:(0,t.jsx)(v,{className:"w-5 h-5 text-yellow-500"})};return(0,t.jsx)("div",{className:`fixed bottom-4 left-4 z-50 transition-all duration-300 ${o?"opacity-100 translate-y-0":"opacity-0 translate-y-2"}`,children:(0,t.jsxs)("div",{className:`flex items-center gap-3 px-4 py-3 rounded-lg shadow-lg border ${{success:"bg-green-50 border-green-200",error:"bg-red-50 border-red-200",warning:"bg-yellow-50 border-yellow-200"}[a]} min-w-[300px] max-w-[500px]`,children:[n[a],(0,t.jsx)("span",{className:"flex-1 text-sm text-gray-800",children:e}),(0,t.jsx)("button",{onClick:()=>{i(!1),setTimeout(l,300)},className:"text-gray-400 hover:text-gray-600 transition-colors",children:(0,t.jsx)(p,{className:"w-4 h-4"})})]})})}function S({toasts:e,onRemove:r}){return(0,t.jsx)(t.Fragment,{children:e.map((e,a)=>(0,t.jsx)("div",{style:{bottom:`${16+80*a}px`},className:"fixed left-4 z-50",children:(0,t.jsx)(k,{message:e.message,type:e.type,onClose:()=>r(e.id)})},e.id))})}let C=i("folder-open",[["path",{d:"m6 14 1.5-2.9A2 2 0 0 1 9.24 10H20a2 2 0 0 1 1.94 2.5l-1.54 6a2 2 0 0 1-1.95 1.5H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h3.9a2 2 0 0 1 1.69.9l.81 1.2a2 2 0 0 0 1.67.9H18a2 2 0 0 1 2 2v2",key:"usdka0"}]]),P=i("save",[["path",{d:"M15.2 3a2 2 0 0 1 1.4.6l3.8 3.8a2 2 0 0 1 .6 1.4V19a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2z",key:"1c8476"}],["path",{d:"M17 21v-7a1 1 0 0 0-1-1H8a1 1 0 0 0-1 1v7",key:"1ydtos"}],["path",{d:"M7 3v4a1 1 0 0 0 1 1h7",key:"t51u73"}]]);function T(){let[e,a]=(0,r.useState)([]),[s,l]=(0,r.useState)(0),[o,i]=(0,r.useState)(""),[n,d]=(0,r.useState)(!1),[h,x]=(0,r.useState)(!1),[u,g]=(0,r.useState)(!1),[y,w]=(0,r.useState)("."),[N,v]=(0,r.useState)(null),[k,T]=(0,r.useState)(null),[O,A]=(0,r.useState)(!1),[M,$]=(0,r.useState)(),[E,D]=(0,r.useState)([]),z=(e,t="success")=>{let r=Date.now().toString();D(a=>[...a,{id:r,message:e,type:t}])},F=(e,t)=>!!e&&!!t&&(e.description!==t.description||e.notes!==t.notes),H=e[s];(0,r.useEffect)(()=>{(async()=>{try{let e=await fetch("/api/project"),t=await e.json();if(t.success&&(w(t.data.rootPath),t.data.hasConfigDoc)){let e=await fetch("/api/config/metadata"),t=await e.json();if(t.success&&t.data?.configFiles)for(let e of t.data.configFiles)await J(e.filePath)}let r=await fetch("/api/export/settings"),a=await r.json();a.success&&$(a.data)}catch(e){console.error("Failed to load saved configs:",e)}finally{g(!0)}})()},[]);let J=async e=>{try{let t=await fetch("/api/config/load",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({filePath:e})}),r=await t.json();r.success&&a(t=>t.some(t=>t.filePath===e)?t:[...t,{filePath:e,configData:r.data.configData,docs:r.data.docs}])}catch(e){console.error("Failed to load config file:",e)}},L=async e=>{try{let t=await fetch("/api/config/metadata",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({configFilePaths:e})}),r=await t.json();r.deletedDocsFiles&&r.deletedDocsFiles.length>0&&z(`${r.deletedDocsFiles.length}件のドキュメントファイルを削除しました`,"warning")}catch(e){console.error("Failed to update metadata:",e)}},V=(e,t)=>{let r=e.replace(/\\/g,"/"),a=t.replace(/\\/g,"/");if(!r.match(/^[a-zA-Z]:\//)&&!r.startsWith("/"))return e;if(r.startsWith(a)){let e=r.substring(a.length);return e.startsWith("/")?e.substring(1):e}return e},W=async t=>{let r=[];for(let a of t){let t=V(a,y);if(!e.some(e=>e.filePath===t))try{let e=await fetch("/api/config/load",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({filePath:a})}),s=await e.json();s.success?r.push({filePath:t,configData:s.data.configData,docs:s.data.docs}):z(`設定ファイルの読み込みに失敗しました (${a}): ${s.error}`,"error")}catch(e){console.error("Failed to load config:",e),z(`設定ファイルの読み込み中にエラーが発生しました: ${a}`,"error")}}r.length>0&&a(e=>{let t=[...e,...r];return L(t.map(e=>e.filePath)),t})},I=async t=>{let r=e[t];(!r.docs||!(Object.keys(r.docs.properties).length>0)||confirm("既に説明文が設定されていますが、削除してよろしいですか?"))&&(a(e=>{let r=e.filter((e,r)=>r!==t);return L(r.map(e=>e.filePath)),r}),s>=t&&s>0&&l(s-1),i(""),v(null),A(!1))},R=e=>{if(O&&!confirm("保存されていない変更があります。破棄しますか?"))return;i(e);let t=H.docs.properties[e];if(t){let e={...t};v(e),T(e)}else{let t={path:e,description:"",notes:"",modifiedAt:new Date().toISOString()};v(t),T(t)}A(!1)},q=async()=>{if(N&&H)try{let e={...N,modifiedAt:new Date().toISOString()},t=await fetch("/api/config/save",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({configFilePath:H.filePath,propertyPath:o,propertyDoc:e})}),r=await t.json();r.success?(a(t=>t.map((t,r)=>r===s?{...t,docs:{...t.docs,properties:{...t.docs.properties,[o]:e}}}:t)),v(e),T(e),A(!1),z("保存しました"),M?.autoExport&&await U()):z("保存に失敗しました: "+r.error,"error")}catch(e){console.error("Failed to save:",e),z("保存中にエラーが発生しました","error")}},U=async()=>{if(M)try{if((await fetch("/api/export",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({format:M.format,fileName:M.fileName})})).ok){let e={...M,lastExportedAt:new Date().toISOString()};$(e),await fetch("/api/export/settings",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({settings:e})})}}catch(e){console.error("Auto export failed:",e)}},Z=async e=>{try{let t=await fetch("/api/export",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({format:e.format,fileName:e.fileName})}),r=await t.json();if(r.success){let t={...e,lastExportedAt:new Date().toISOString()};$(t),await fetch("/api/export/settings",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({settings:t})}),z(`エクスポートしました: ${r.outputPath}`)}else z("エクスポートに失敗しました: "+r.error,"error")}catch(e){console.error("Export failed:",e),z("エクスポート中にエラーが発生しました","error")}};return(0,t.jsxs)("div",{className:"min-h-screen bg-gradient-to-br from-blue-50 via-indigo-50 to-purple-50",children:[(0,t.jsx)("header",{className:"bg-white/80 backdrop-blur-md border-b border-gray-200 shadow-sm sticky top-0 z-50",children:(0,t.jsxs)("div",{className:"container mx-auto px-6 py-4 flex items-center justify-between",children:[(0,t.jsxs)("div",{className:"flex items-center gap-3",children:[(0,t.jsx)("div",{className:"w-10 h-10 bg-gradient-to-br from-blue-600 to-purple-600 rounded-lg flex items-center justify-center shadow-lg",children:(0,t.jsx)(c,{className:"w-6 h-6 text-white"})}),(0,t.jsxs)("div",{children:[(0,t.jsx)("h1",{className:"text-2xl font-bold bg-gradient-to-r from-blue-600 to-purple-600 bg-clip-text text-transparent",children:"ConfigDoc"}),(0,t.jsx)("p",{className:"text-xs text-gray-500",children:"Configuration Documentation Tool"})]})]}),(0,t.jsxs)("button",{onClick:()=>x(!0),className:"flex items-center gap-2 px-5 py-2.5 bg-gradient-to-r from-green-500 to-emerald-600 text-white rounded-lg hover:from-green-600 hover:to-emerald-700 shadow-md hover:shadow-lg transition-all duration-200 transform hover:scale-105",title:"エクスポート",children:[(0,t.jsx)(b,{className:"w-5 h-5"}),(0,t.jsx)("span",{className:"font-medium",children:"エクスポート"})]})]})}),(0,t.jsxs)("main",{className:"container mx-auto px-6 py-8",children:[(0,t.jsxs)("div",{className:"bg-white/90 backdrop-blur-sm rounded-2xl shadow-xl border border-gray-100 p-6 mb-8 hover:shadow-2xl transition-shadow duration-300",children:[(0,t.jsxs)("div",{className:"flex items-center justify-between mb-4",children:[(0,t.jsxs)("div",{className:"flex items-center gap-2",children:[(0,t.jsx)("div",{className:"w-8 h-8 bg-gradient-to-br from-blue-500 to-blue-600 rounded-lg flex items-center justify-center",children:(0,t.jsx)(C,{className:"w-5 h-5 text-white"})}),(0,t.jsx)("h2",{className:"text-xl font-bold text-gray-800",children:"設定ファイル"})]}),(0,t.jsxs)("button",{onClick:()=>d(!0),className:"flex items-center gap-2 px-4 py-2 bg-gradient-to-r from-blue-500 to-blue-600 text-white rounded-lg hover:from-blue-600 hover:to-blue-700 shadow-md hover:shadow-lg transition-all duration-200 transform hover:scale-105",children:[(0,t.jsx)(C,{className:"w-5 h-5"}),(0,t.jsx)("span",{className:"font-medium",children:"ファイルを追加"})]})]}),e.length>0?(0,t.jsx)("div",{className:"flex flex-wrap gap-3",children:e.map((e,r)=>(0,t.jsxs)("div",{onClick:()=>{l(r),i(""),v(null),A(!1)},className:`group flex items-center gap-2 px-4 py-2.5 rounded-xl border-2 cursor-pointer transition-all duration-200 ${s===r?"bg-gradient-to-r from-blue-50 to-indigo-50 border-blue-400 shadow-md":"bg-white border-gray-200 hover:border-blue-300 hover:shadow-md"}`,children:[(0,t.jsx)("span",{className:`text-sm font-medium ${s===r?"text-blue-700":"text-gray-700"}`,children:e.filePath.split(/[/\\]/).pop()}),(0,t.jsx)("button",{onClick:e=>{e.stopPropagation(),I(r)},className:"text-gray-400 hover:text-red-500 transition-colors opacity-0 group-hover:opacity-100",children:(0,t.jsx)(p,{className:"w-4 h-4"})})]},e.filePath))}):(0,t.jsxs)("div",{className:"text-center py-12 bg-gradient-to-br from-gray-50 to-gray-100 rounded-xl border-2 border-dashed border-gray-300",children:[(0,t.jsx)(C,{className:"w-16 h-16 text-gray-400 mx-auto mb-3"}),(0,t.jsx)("p",{className:"text-sm text-gray-600 font-medium",children:"設定ファイルを選択してください"}),(0,t.jsx)("p",{className:"text-xs text-gray-500 mt-1",children:"「ファイルを追加」ボタンから開始"})]})]}),H&&(0,t.jsxs)("div",{className:"grid grid-cols-1 lg:grid-cols-2 gap-6",children:[(0,t.jsxs)("div",{className:"bg-white/90 backdrop-blur-sm rounded-2xl shadow-xl border border-gray-100 p-6 flex flex-col max-h-[calc(100vh-350px)] hover:shadow-2xl transition-shadow duration-300",children:[(0,t.jsxs)("div",{className:"flex items-center gap-2 mb-4",children:[(0,t.jsx)("div",{className:"w-8 h-8 bg-gradient-to-br from-purple-500 to-purple-600 rounded-lg flex items-center justify-center",children:(0,t.jsx)(c,{className:"w-5 h-5 text-white"})}),(0,t.jsx)("h2",{className:"text-xl font-bold text-gray-800",children:"JSON構造"})]}),(0,t.jsx)("div",{className:"overflow-y-auto flex-1",children:(0,t.jsx)(m,{config:H.configData,docs:H.docs,onSelectProperty:R,onEditProperty:R,selectedPath:o})})]}),(0,t.jsxs)("div",{className:"bg-white/90 backdrop-blur-sm rounded-2xl shadow-xl border border-gray-100 p-6 flex flex-col max-h-[calc(100vh-250px)] hover:shadow-2xl transition-shadow duration-300",children:[(0,t.jsxs)("div",{className:"flex items-center justify-between mb-4",children:[(0,t.jsxs)("div",{className:"flex items-center gap-2",children:[(0,t.jsx)("div",{className:"w-8 h-8 bg-gradient-to-br from-indigo-500 to-indigo-600 rounded-lg flex items-center justify-center",children:(0,t.jsx)(P,{className:"w-5 h-5 text-white"})}),(0,t.jsx)("h2",{className:"text-xl font-bold text-gray-800",children:"プロパティ詳細"})]}),O&&(0,t.jsxs)("button",{onClick:q,className:"flex items-center gap-2 px-4 py-2 bg-gradient-to-r from-green-500 to-emerald-600 text-white rounded-lg hover:from-green-600 hover:to-emerald-700 shadow-md hover:shadow-lg transition-all duration-200 transform hover:scale-105",children:[(0,t.jsx)(P,{className:"w-4 h-4"}),(0,t.jsx)("span",{className:"font-medium",children:"保存"})]})]}),(0,t.jsx)("div",{className:"overflow-y-auto flex-1",children:o&&N?(0,t.jsxs)("div",{className:"space-y-6",children:[(0,t.jsxs)("div",{children:[(0,t.jsx)("label",{className:"block text-sm font-semibold text-gray-700 mb-2",children:"パス"}),(0,t.jsx)("div",{className:"text-sm text-gray-700 bg-gradient-to-r from-blue-50 to-indigo-50 p-3 rounded-lg font-mono border border-blue-200 shadow-sm",children:o})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("label",{className:"block text-sm font-semibold text-gray-700 mb-2",children:"説明"}),(0,t.jsx)("textarea",{value:N.description,onChange:e=>{let t={...N,description:e.target.value};v(t),A(F(t,k))},className:"w-full border-2 border-gray-200 rounded-lg p-3 min-h-[120px] text-sm focus:border-blue-400 focus:ring-2 focus:ring-blue-200 transition-all duration-200 shadow-sm hover:shadow-md",placeholder:"このプロパティの説明を入力してください"})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("label",{className:"block text-sm font-semibold text-gray-700 mb-2",children:"備考"}),(0,t.jsx)("textarea",{value:N.notes,onChange:e=>{let t={...N,notes:e.target.value};v(t),A(F(t,k))},className:"w-full border-2 border-gray-200 rounded-lg p-3 min-h-[100px] text-sm focus:border-blue-400 focus:ring-2 focus:ring-blue-200 transition-all duration-200 shadow-sm hover:shadow-md",placeholder:"追加のメモや注意事項"})]})]}):(0,t.jsxs)("div",{className:"flex flex-col items-center justify-center py-20",children:[(0,t.jsx)("div",{className:"w-20 h-20 bg-gradient-to-br from-gray-100 to-gray-200 rounded-full flex items-center justify-center mb-4",children:(0,t.jsx)(c,{className:"w-10 h-10 text-gray-400"})}),(0,t.jsx)("p",{className:"text-sm text-gray-600 font-medium",children:"プロパティを選択してください"}),(0,t.jsx)("p",{className:"text-xs text-gray-500 mt-1",children:"左側のツリーから項目を選択"})]})})]})]})]}),(0,t.jsx)(f,{isOpen:n,currentPath:y,multiSelect:!0,filterJsonOnly:!0,onSelect:e=>{W(e),d(!1)},onClose:()=>d(!1)}),(0,t.jsx)(j,{isOpen:h,onClose:()=>x(!1),onExport:Z,currentSettings:M,rootPath:y}),(0,t.jsx)(S,{toasts:E,onRemove:e=>{D(t=>t.filter(t=>t.id!==e))}})]})}e.s(["default",()=>T],52211)}]);
@@ -1 +0,0 @@
1
- (globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,52211,e=>{"use strict";var t=e.i(52420),r=e.i(20063);let a=e=>{let t=e.replace(/^([A-Z])|[\s-_]+(\w)/g,(e,t,r)=>r?r.toUpperCase():t.toLowerCase());return t.charAt(0).toUpperCase()+t.slice(1)},s=(...e)=>e.filter((e,t,r)=>!!e&&""!==e.trim()&&r.indexOf(e)===t).join(" ").trim();var l={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};let o=(0,r.forwardRef)(({color:e="currentColor",size:t=24,strokeWidth:a=2,absoluteStrokeWidth:o,className:i="",children:n,iconNode:d,...c},h)=>(0,r.createElement)("svg",{ref:h,...l,width:t,height:t,stroke:e,strokeWidth:o?24*Number(a)/Number(t):a,className:s("lucide",i),...!n&&!(e=>{for(let t in e)if(t.startsWith("aria-")||"role"===t||"title"===t)return!0})(c)&&{"aria-hidden":"true"},...c},[...d.map(([e,t])=>(0,r.createElement)(e,t)),...Array.isArray(n)?n:[n]])),i=(e,t)=>{let l=(0,r.forwardRef)(({className:l,...i},n)=>(0,r.createElement)(o,{ref:n,iconNode:t,className:s(`lucide-${a(e).replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase()}`,`lucide-${e}`,l),...i}));return l.displayName=a(e),l},n=i("chevron-right",[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]]),d=i("chevron-down",[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]]),c=i("file-text",[["path",{d:"M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z",key:"1oefj6"}],["path",{d:"M14 2v5a1 1 0 0 0 1 1h5",key:"wfsgrz"}],["path",{d:"M10 9H8",key:"b1mrlr"}],["path",{d:"M16 13H8",key:"t4e002"}],["path",{d:"M16 17H8",key:"z1uh3a"}]]);class h{static flattenConfig(e,t=""){let r={};for(let a in e){let s=t?`${t}:${a}`:a;e[a]&&"object"==typeof e[a]&&!Array.isArray(e[a])?Object.assign(r,this.flattenConfig(e[a],s)):r[s]=e[a]}return r}static buildTree(e,t=""){let r=[];for(let a in e){let s=t?`${t}:${a}`:a,l=e[a];l&&"object"==typeof l&&!Array.isArray(l)?r.push({key:a,fullPath:s,value:l,children:this.buildTree(l,s),hasDocumentation:!1,type:"object"}):r.push({key:a,fullPath:s,value:l,hasDocumentation:!1,type:Array.isArray(l)?"array":typeof l})}return r}}function m({config:e,docs:a,onSelectProperty:s,onEditProperty:l,selectedPath:o}){let[i,m]=(0,r.useState)(new Set),x=(e,r=0)=>{let h=void 0!==a.properties[e.fullPath],u=i.has(e.fullPath),g=o===e.fullPath;return(0,t.jsxs)("div",{children:[(0,t.jsxs)("div",{style:{paddingLeft:`${20*r}px`},className:`group flex items-center gap-2 py-2 px-3 cursor-pointer rounded-lg transition-all duration-150 ${g?"bg-gradient-to-r from-blue-100 to-indigo-100 border-l-4 border-blue-500 shadow-sm":"hover:bg-gradient-to-r hover:from-gray-50 hover:to-gray-100"}`,children:[e.children&&e.children.length>0?(0,t.jsx)("button",{onClick:()=>{var t;let r;return t=e.fullPath,void((r=new Set(i)).has(t)?r.delete(t):r.add(t),m(r))},className:"p-1 hover:bg-blue-100 rounded-md transition-colors",children:u?(0,t.jsx)(d,{className:"w-4 h-4 text-blue-600"}):(0,t.jsx)(n,{className:"w-4 h-4 text-gray-600"})}):(0,t.jsx)("div",{className:"w-6"}),(0,t.jsxs)("div",{onClick:()=>s(e.fullPath),className:"flex-1 flex items-center gap-2",children:[(0,t.jsx)("span",{className:`${e.children?"font-bold text-gray-800":"font-medium text-gray-700"}`,children:e.key}),!e.children&&(0,t.jsxs)("span",{className:"text-sm text-gray-500 truncate max-w-[200px]",children:[": ",JSON.stringify(e.value)]}),h&&(0,t.jsxs)("div",{className:"flex items-center gap-1 px-2 py-0.5 bg-green-100 border border-green-300 rounded-full",children:[(0,t.jsx)(c,{className:"w-3 h-3 text-green-600"}),(0,t.jsx)("span",{className:"text-xs text-green-700 font-medium",children:"Doc"})]})]}),!e.children&&(0,t.jsx)("button",{onClick:t=>{t.stopPropagation(),l(e.fullPath)},className:"p-1 hover:bg-gray-200 rounded",title:"編集"})]}),e.children&&u&&(0,t.jsx)("div",{children:e.children.map(e=>x(e,r+1))})]},e.fullPath)},u=h.buildTree(e);return(0,t.jsxs)("div",{className:"h-full flex flex-col border-2 border-gray-100 rounded-xl bg-white shadow-sm",children:[(0,t.jsxs)("div",{className:"flex items-center gap-2 p-3 border-b-2 border-gray-100 bg-gradient-to-r from-gray-50 to-gray-100",children:[(0,t.jsx)("button",{onClick:()=>{var t;let r,a;m(new Set((t=h.buildTree(e),r=[],a=e=>{e.children&&e.children.length>0&&(r.push(e.fullPath),e.children.forEach(a))},t.forEach(a),r)))},className:"px-4 py-1.5 text-sm font-medium bg-white border-2 border-blue-200 text-blue-600 rounded-lg hover:bg-blue-50 hover:border-blue-300 transition-all duration-200 shadow-sm hover:shadow-md",children:"すべて展開"}),(0,t.jsx)("button",{onClick:()=>{m(new Set)},className:"px-4 py-1.5 text-sm font-medium bg-white border-2 border-gray-200 text-gray-600 rounded-lg hover:bg-gray-50 hover:border-gray-300 transition-all duration-200 shadow-sm hover:shadow-md",children:"すべて閉じる"})]}),(0,t.jsx)("div",{className:"flex-1 overflow-y-auto p-3",children:u.map(e=>x(e))})]})}let x=i("folder",[["path",{d:"M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z",key:"1kt360"}]]),u=i("file",[["path",{d:"M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z",key:"1oefj6"}],["path",{d:"M14 2v5a1 1 0 0 0 1 1h5",key:"wfsgrz"}]]),g=i("chevron-up",[["path",{d:"m18 15-6-6-6 6",key:"153udz"}]]);function f({isOpen:e,currentPath:a,onSelect:s,onClose:l,multiSelect:o=!1,filterJsonOnly:i=!1}){let[n,d]=(0,r.useState)(a),[c,h]=(0,r.useState)([]),[m,f]=(0,r.useState)(!1),[p,b]=(0,r.useState)([]);(0,r.useEffect)(()=>{e&&(d(a),b([]))},[e,a]),(0,r.useEffect)(()=>{e&&y(n)},[e,n]);let y=async e=>{f(!0);try{let t=await fetch("/api/files/browse",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({directory:e})}),r=await t.json();if(r.success){let e=i?r.data.items.filter(e=>"directory"===e.type||".json"===e.extension):r.data.items;h(e)}else console.error("API returned error:",r.error)}catch(e){console.error("Failed to load directory:",e)}finally{f(!1)}},j=()=>{b([]),l()};return e?(0,t.jsx)("div",{className:"fixed inset-0 bg-black bg-opacity-50 flex items-center justify-center z-50",children:(0,t.jsxs)("div",{className:"bg-white rounded-lg shadow-xl w-full max-w-2xl max-h-[80vh] flex flex-col",children:[(0,t.jsxs)("div",{className:"flex items-center justify-between p-4 border-b",children:[(0,t.jsx)("h2",{className:"text-lg font-semibold",children:"ファイルを選択"}),(0,t.jsx)("button",{onClick:j,className:"text-gray-500 hover:text-gray-700",children:"✕"})]}),(0,t.jsxs)("div",{className:"flex items-center gap-2 p-4 border-b bg-gray-50",children:[(0,t.jsx)("button",{onClick:()=>{let e=n.replace(/\//g,"\\").split("\\").filter(e=>e);if(e.length>1){let t=e.slice(0,-1);d(1===t.length&&t[0].includes(":")?t[0]+"\\":t[0].includes(":")?t[0]+"\\"+t.slice(1).join("\\"):t.join("\\"))}else 1!==e.length||e[0].includes(":")||d(".")},className:"p-2 hover:bg-gray-200 rounded flex-shrink-0",title:"上のディレクトリへ",children:(0,t.jsx)(g,{className:"w-5 h-5"})}),(0,t.jsxs)("span",{className:"text-sm text-gray-600 flex-1 truncate",children:["パス: ",n]})]}),(0,t.jsx)("div",{className:"flex-1 overflow-y-auto p-4",children:m?(0,t.jsx)("div",{className:"text-center text-gray-500",children:"読み込み中..."}):(0,t.jsx)("div",{className:"space-y-1",children:c.map(e=>{let r=p.includes(e.path);return(0,t.jsxs)("div",{onClick:()=>{"directory"===e.type?d(e.path):o?b(t=>t.includes(e.path)?t.filter(t=>t!==e.path):[...t,e.path]):b([e.path])},className:`flex items-center gap-2 p-2 rounded cursor-pointer hover:bg-gray-100 ${r?"bg-blue-100":""}`,children:["directory"===e.type?(0,t.jsx)(x,{className:"w-5 h-5 text-blue-500"}):(0,t.jsx)(u,{className:"w-5 h-5 text-green-500"}),(0,t.jsx)("span",{className:"text-sm",children:e.name}),r&&o&&(0,t.jsx)("span",{className:"ml-auto text-blue-500",children:"✓"})]},e.path)})})}),(0,t.jsxs)("div",{className:"flex items-center justify-between p-4 border-t",children:[o&&p.length>0&&(0,t.jsxs)("div",{className:"text-sm text-gray-600",children:[p.length,"件選択中"]}),(0,t.jsxs)("div",{className:"flex items-center gap-2 ml-auto",children:[(0,t.jsx)("button",{onClick:j,className:"px-4 py-2 text-gray-600 hover:bg-gray-100 rounded",children:"キャンセル"}),(0,t.jsx)("button",{onClick:()=>{p.length>0&&(s(p),b([]),l())},disabled:0===p.length,className:"px-4 py-2 bg-blue-500 text-white rounded hover:bg-blue-600 disabled:bg-gray-300 disabled:cursor-not-allowed",children:"選択"})]})]})]})}):null}let p=i("x",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]]),b=i("download",[["path",{d:"M12 15V3",key:"m9g1x1"}],["path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4",key:"ih7n3h"}],["path",{d:"m7 10 5 5 5-5",key:"brsn70"}]]),y={format:"html",autoExport:!0,fileName:"config-doc"};function j({isOpen:e,onClose:a,onExport:s,currentSettings:l,rootPath:o="."}){let[i,n]=(0,r.useState)(l||y),[d,c]=(0,r.useState)(!1);(0,r.useEffect)(()=>{l&&n(l)},[l]);let h=(0,r.useMemo)(()=>{let e=o.replace(/\//g,"\\"),t=i.fileName||"config-doc",r="markdown"===i.format||"markdown-table"===i.format?"md":"html";return`${e}\\.config_doc\\output\\${t}.${r}`},[i.format,i.fileName,o]);if(!e)return null;let m=async()=>{c(!0);try{await s(i),a()}catch(e){console.error("Export failed:",e)}finally{c(!1)}};return(0,t.jsx)("div",{className:"fixed inset-0 bg-black bg-opacity-50 flex items-center justify-center z-50",children:(0,t.jsxs)("div",{className:"bg-white rounded-lg shadow-xl max-w-md w-full mx-4",children:[(0,t.jsxs)("div",{className:"flex items-center justify-between p-6 border-b",children:[(0,t.jsx)("h2",{className:"text-xl font-semibold text-gray-800",children:"エクスポート設定"}),(0,t.jsx)("button",{onClick:a,className:"text-gray-400 hover:text-gray-600 transition-colors",children:(0,t.jsx)(p,{className:"w-5 h-5"})})]}),(0,t.jsxs)("div",{className:"p-6 space-y-6",children:[(0,t.jsxs)("div",{children:[(0,t.jsx)("label",{className:"block text-sm font-medium text-gray-700 mb-2",children:"出力先パス"}),(0,t.jsx)("div",{className:"px-3 py-2 bg-gray-50 border border-gray-300 rounded-md text-sm text-gray-700 font-mono break-all",children:h}),(0,t.jsx)("p",{className:"mt-1 text-xs text-gray-500",children:"html"===i.format?"HTMLファイルの出力先":"markdown-table"===i.format?"Markdownテーブル形式ファイルの出力先":"Markdownファイルの出力先"})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("label",{className:"block text-sm font-medium text-gray-700 mb-2",children:"ファイル名"}),(0,t.jsx)("input",{type:"text",value:i.fileName||"config-doc",onChange:e=>n({...i,fileName:e.target.value}),className:"w-full px-3 py-2 border border-gray-300 rounded-md focus:outline-none focus:ring-2 focus:ring-blue-500",placeholder:"config-doc"}),(0,t.jsx)("p",{className:"mt-1 text-xs text-gray-500",children:"拡張子なしのファイル名を指定します(チーム共有設定)"})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("label",{className:"block text-sm font-medium text-gray-700 mb-2",children:"出力形式"}),(0,t.jsxs)("select",{value:i.format,onChange:e=>n({...i,format:e.target.value}),className:"w-full px-3 py-2 border border-gray-300 rounded-md focus:outline-none focus:ring-2 focus:ring-blue-500",children:[(0,t.jsx)("option",{value:"html",children:"HTML"}),(0,t.jsx)("option",{value:"markdown",children:"Markdown"}),(0,t.jsx)("option",{value:"markdown-table",children:"Markdown (テーブル形式)"})]}),(0,t.jsx)("p",{className:"mt-1 text-xs text-gray-500",children:"html"===i.format?"スタイル付きのHTMLファイルとして出力します":"markdown-table"===i.format?"Markdownテーブル形式で出力します(プロパティ名、説明、値、備考)":"テキストベースのMarkdownファイルとして出力します"})]}),(0,t.jsxs)("div",{className:"flex items-start",children:[(0,t.jsx)("div",{className:"flex items-center h-5",children:(0,t.jsx)("input",{id:"auto-export",type:"checkbox",checked:i.autoExport,onChange:e=>n({...i,autoExport:e.target.checked}),className:"w-4 h-4 text-blue-600 border-gray-300 rounded focus:ring-blue-500"})}),(0,t.jsxs)("div",{className:"ml-3",children:[(0,t.jsx)("label",{htmlFor:"auto-export",className:"text-sm font-medium text-gray-700 cursor-pointer",children:"保存時に自動エクスポート"}),(0,t.jsx)("p",{className:"text-xs text-gray-500 mt-1",children:"ドキュメントを保存したときに自動的にHTMLファイルを更新します"})]})]}),i.lastExportedAt&&(0,t.jsx)("div",{className:"pt-4 border-t",children:(0,t.jsxs)("p",{className:"text-xs text-gray-500",children:["最終エクスポート: ",new Date(i.lastExportedAt).toLocaleString("ja-JP")]})})]}),(0,t.jsxs)("div",{className:"flex items-center justify-end gap-3 p-6 border-t bg-gray-50 rounded-b-lg",children:[(0,t.jsx)("button",{onClick:a,className:"px-4 py-2 text-sm font-medium text-gray-700 bg-white border border-gray-300 rounded-md hover:bg-gray-50 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-blue-500",children:"キャンセル"}),(0,t.jsxs)("button",{onClick:m,disabled:d,className:"flex items-center gap-2 px-4 py-2 text-sm font-medium text-white bg-blue-600 border border-transparent rounded-md hover:bg-blue-700 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-blue-500 disabled:opacity-50 disabled:cursor-not-allowed",children:[(0,t.jsx)(b,{className:"w-4 h-4"}),d?"エクスポート中...":"エクスポート"]})]})]})})}let w=i("circle-check-big",[["path",{d:"M21.801 10A10 10 0 1 1 17 3.335",key:"yps3ct"}],["path",{d:"m9 11 3 3L22 4",key:"1pflzl"}]]),N=i("circle-x",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m15 9-6 6",key:"1uzhvr"}],["path",{d:"m9 9 6 6",key:"z0biqf"}]]),v=i("circle-alert",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["line",{x1:"12",x2:"12",y1:"8",y2:"12",key:"1pkeuh"}],["line",{x1:"12",x2:"12.01",y1:"16",y2:"16",key:"4dfq90"}]]);function k({message:e,type:a,duration:s=3e3,onClose:l}){let[o,i]=(0,r.useState)(!1);(0,r.useEffect)(()=>{setTimeout(()=>i(!0),10);let e=setTimeout(()=>{i(!1),setTimeout(l,300)},s);return()=>clearTimeout(e)},[s,l]);let n={success:(0,t.jsx)(w,{className:"w-5 h-5 text-green-500"}),error:(0,t.jsx)(N,{className:"w-5 h-5 text-red-500"}),warning:(0,t.jsx)(v,{className:"w-5 h-5 text-yellow-500"})};return(0,t.jsx)("div",{className:`fixed bottom-4 left-4 z-50 transition-all duration-300 ${o?"opacity-100 translate-y-0":"opacity-0 translate-y-2"}`,children:(0,t.jsxs)("div",{className:`flex items-center gap-3 px-4 py-3 rounded-lg shadow-lg border ${{success:"bg-green-50 border-green-200",error:"bg-red-50 border-red-200",warning:"bg-yellow-50 border-yellow-200"}[a]} min-w-[300px] max-w-[500px]`,children:[n[a],(0,t.jsx)("span",{className:"flex-1 text-sm text-gray-800",children:e}),(0,t.jsx)("button",{onClick:()=>{i(!1),setTimeout(l,300)},className:"text-gray-400 hover:text-gray-600 transition-colors",children:(0,t.jsx)(p,{className:"w-4 h-4"})})]})})}function S({toasts:e,onRemove:r}){return(0,t.jsx)(t.Fragment,{children:e.map((e,a)=>(0,t.jsx)("div",{style:{bottom:`${16+80*a}px`},className:"fixed left-4 z-50",children:(0,t.jsx)(k,{message:e.message,type:e.type,onClose:()=>r(e.id)})},e.id))})}let C=i("folder-open",[["path",{d:"m6 14 1.5-2.9A2 2 0 0 1 9.24 10H20a2 2 0 0 1 1.94 2.5l-1.54 6a2 2 0 0 1-1.95 1.5H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h3.9a2 2 0 0 1 1.69.9l.81 1.2a2 2 0 0 0 1.67.9H18a2 2 0 0 1 2 2v2",key:"usdka0"}]]),P=i("save",[["path",{d:"M15.2 3a2 2 0 0 1 1.4.6l3.8 3.8a2 2 0 0 1 .6 1.4V19a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2z",key:"1c8476"}],["path",{d:"M17 21v-7a1 1 0 0 0-1-1H8a1 1 0 0 0-1 1v7",key:"1ydtos"}],["path",{d:"M7 3v4a1 1 0 0 0 1 1h7",key:"t51u73"}]]);function T(){let[e,a]=(0,r.useState)([]),[s,l]=(0,r.useState)(0),[o,i]=(0,r.useState)(""),[n,d]=(0,r.useState)(!1),[h,x]=(0,r.useState)(!1),[u,g]=(0,r.useState)(!1),[y,w]=(0,r.useState)("."),[N,v]=(0,r.useState)(null),[k,T]=(0,r.useState)(null),[O,A]=(0,r.useState)(!1),[M,$]=(0,r.useState)(),[E,D]=(0,r.useState)([]),z=(e,t="success")=>{let r=Date.now().toString();D(a=>[...a,{id:r,message:e,type:t}])},F=(e,t)=>!!e&&!!t&&(e.description!==t.description||e.notes!==t.notes),H=e[s];(0,r.useEffect)(()=>{(async()=>{try{let e=await fetch("/api/project"),t=await e.json();if(t.success&&(w(t.data.rootPath),t.data.hasConfigDoc)){let e=await fetch("/api/config/metadata"),t=await e.json();if(t.success&&t.data?.configFiles)for(let e of t.data.configFiles)await J(e.filePath)}let r=await fetch("/api/export/settings"),a=await r.json();a.success&&$(a.data)}catch(e){console.error("Failed to load saved configs:",e)}finally{g(!0)}})()},[]);let J=async e=>{try{let t=await fetch("/api/config/load",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({filePath:e})}),r=await t.json();r.success&&a(t=>t.some(t=>t.filePath===e)?t:[...t,{filePath:e,configData:r.data.configData,docs:r.data.docs}])}catch(e){console.error("Failed to load config file:",e)}},L=async e=>{try{let t=await fetch("/api/config/metadata",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({configFilePaths:e})}),r=await t.json();r.deletedDocsFiles&&r.deletedDocsFiles.length>0&&z(`${r.deletedDocsFiles.length}件のドキュメントファイルを削除しました`,"warning")}catch(e){console.error("Failed to update metadata:",e)}},V=(e,t)=>{let r=e.replace(/\\/g,"/"),a=t.replace(/\\/g,"/");if(!r.match(/^[a-zA-Z]:\//)&&!r.startsWith("/"))return e;if(r.startsWith(a)){let e=r.substring(a.length);return e.startsWith("/")?e.substring(1):e}return e},W=async t=>{let r=[];for(let a of t){let t=V(a,y);if(!e.some(e=>e.filePath===t))try{let e=await fetch("/api/config/load",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({filePath:a})}),s=await e.json();s.success?r.push({filePath:t,configData:s.data.configData,docs:s.data.docs}):z(`設定ファイルの読み込みに失敗しました (${a}): ${s.error}`,"error")}catch(e){console.error("Failed to load config:",e),z(`設定ファイルの読み込み中にエラーが発生しました: ${a}`,"error")}}r.length>0&&a(e=>{let t=[...e,...r];return L(t.map(e=>e.filePath)),t})},I=async t=>{let r=e[t];(!r.docs||!(Object.keys(r.docs.properties).length>0)||confirm("既に説明文が設定されていますが、削除してよろしいですか?"))&&(a(e=>{let r=e.filter((e,r)=>r!==t);return L(r.map(e=>e.filePath)),r}),s>=t&&s>0&&l(s-1),i(""),v(null),A(!1))},R=e=>{if(O&&!confirm("保存されていない変更があります。破棄しますか?"))return;i(e);let t=H.docs.properties[e];if(t){let e={...t};v(e),T(e)}else{let t={path:e,description:"",notes:"",modifiedAt:new Date().toISOString()};v(t),T(t)}A(!1)},q=async()=>{if(N&&H)try{let e={...N,modifiedAt:new Date().toISOString()},t=await fetch("/api/config/save",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({configFilePath:H.filePath,propertyPath:o,propertyDoc:e})}),r=await t.json();r.success?(a(t=>t.map((t,r)=>r===s?{...t,docs:{...t.docs,properties:{...t.docs.properties,[o]:e}}}:t)),v(e),T(e),A(!1),z("保存しました"),M?.autoExport&&await U()):z("保存に失敗しました: "+r.error,"error")}catch(e){console.error("Failed to save:",e),z("保存中にエラーが発生しました","error")}},U=async()=>{if(M)try{if((await fetch("/api/export",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({format:M.format,fileName:M.fileName})})).ok){let e={...M,lastExportedAt:new Date().toISOString()};$(e),await fetch("/api/export/settings",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({settings:e})})}}catch(e){console.error("Auto export failed:",e)}},Z=async e=>{try{let t=await fetch("/api/export",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({format:e.format,fileName:e.fileName})}),r=await t.json();if(r.success){let t={...e,lastExportedAt:new Date().toISOString()};$(t),await fetch("/api/export/settings",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({settings:t})}),z(`エクスポートしました: ${r.outputPath}`)}else z("エクスポートに失敗しました: "+r.error,"error")}catch(e){console.error("Export failed:",e),z("エクスポート中にエラーが発生しました","error")}};return(0,t.jsxs)("div",{className:"min-h-screen bg-gradient-to-br from-blue-50 via-indigo-50 to-purple-50",children:[(0,t.jsx)("header",{className:"bg-white/80 backdrop-blur-md border-b border-gray-200 shadow-sm sticky top-0 z-50",children:(0,t.jsxs)("div",{className:"container mx-auto px-6 py-4 flex items-center justify-between",children:[(0,t.jsxs)("div",{className:"flex items-center gap-3",children:[(0,t.jsx)("div",{className:"w-10 h-10 bg-gradient-to-br from-blue-600 to-purple-600 rounded-lg flex items-center justify-center shadow-lg",children:(0,t.jsx)(c,{className:"w-6 h-6 text-white"})}),(0,t.jsxs)("div",{children:[(0,t.jsx)("h1",{className:"text-2xl font-bold bg-gradient-to-r from-blue-600 to-purple-600 bg-clip-text text-transparent",children:"ConfigDoc"}),(0,t.jsx)("p",{className:"text-xs text-gray-500",children:"Configuration Documentation Tool"})]})]}),(0,t.jsxs)("button",{onClick:()=>x(!0),className:"flex items-center gap-2 px-5 py-2.5 bg-gradient-to-r from-green-500 to-emerald-600 text-white rounded-lg hover:from-green-600 hover:to-emerald-700 shadow-md hover:shadow-lg transition-all duration-200 transform hover:scale-105",title:"エクスポート",children:[(0,t.jsx)(b,{className:"w-5 h-5"}),(0,t.jsx)("span",{className:"font-medium",children:"エクスポート"})]})]})}),(0,t.jsxs)("main",{className:"container mx-auto px-6 py-8",children:[(0,t.jsxs)("div",{className:"bg-white/90 backdrop-blur-sm rounded-2xl shadow-xl border border-gray-100 p-6 mb-8 hover:shadow-2xl transition-shadow duration-300",children:[(0,t.jsxs)("div",{className:"flex items-center justify-between mb-4",children:[(0,t.jsxs)("div",{className:"flex items-center gap-2",children:[(0,t.jsx)("div",{className:"w-8 h-8 bg-gradient-to-br from-blue-500 to-blue-600 rounded-lg flex items-center justify-center",children:(0,t.jsx)(C,{className:"w-5 h-5 text-white"})}),(0,t.jsx)("h2",{className:"text-xl font-bold text-gray-800",children:"設定ファイル"})]}),(0,t.jsxs)("button",{onClick:()=>d(!0),className:"flex items-center gap-2 px-4 py-2 bg-gradient-to-r from-blue-500 to-blue-600 text-white rounded-lg hover:from-blue-600 hover:to-blue-700 shadow-md hover:shadow-lg transition-all duration-200 transform hover:scale-105",children:[(0,t.jsx)(C,{className:"w-5 h-5"}),(0,t.jsx)("span",{className:"font-medium",children:"ファイルを追加"})]})]}),e.length>0?(0,t.jsx)("div",{className:"flex flex-wrap gap-3",children:e.map((e,r)=>(0,t.jsxs)("div",{onClick:()=>{l(r),i(""),v(null),A(!1)},className:`group flex items-center gap-2 px-4 py-2.5 rounded-xl border-2 cursor-pointer transition-all duration-200 ${s===r?"bg-gradient-to-r from-blue-50 to-indigo-50 border-blue-400 shadow-md":"bg-white border-gray-200 hover:border-blue-300 hover:shadow-md"}`,children:[(0,t.jsx)("span",{className:`text-sm font-medium ${s===r?"text-blue-700":"text-gray-700"}`,children:e.filePath.split(/[/\\]/).pop()}),(0,t.jsx)("button",{onClick:e=>{e.stopPropagation(),I(r)},className:"text-gray-400 hover:text-red-500 transition-colors opacity-0 group-hover:opacity-100",children:(0,t.jsx)(p,{className:"w-4 h-4"})})]},e.filePath))}):(0,t.jsxs)("div",{className:"text-center py-12 bg-gradient-to-br from-gray-50 to-gray-100 rounded-xl border-2 border-dashed border-gray-300",children:[(0,t.jsx)(C,{className:"w-16 h-16 text-gray-400 mx-auto mb-3"}),(0,t.jsx)("p",{className:"text-sm text-gray-600 font-medium",children:"設定ファイルを選択してください"}),(0,t.jsx)("p",{className:"text-xs text-gray-500 mt-1",children:"「ファイルを追加」ボタンから開始"})]})]}),H&&(0,t.jsxs)("div",{className:"grid grid-cols-1 lg:grid-cols-2 gap-6",children:[(0,t.jsxs)("div",{className:"bg-white/90 backdrop-blur-sm rounded-2xl shadow-xl border border-gray-100 p-6 flex flex-col max-h-[calc(100vh-350px)] hover:shadow-2xl transition-shadow duration-300",children:[(0,t.jsxs)("div",{className:"flex items-center gap-2 mb-4",children:[(0,t.jsx)("div",{className:"w-8 h-8 bg-gradient-to-br from-purple-500 to-purple-600 rounded-lg flex items-center justify-center",children:(0,t.jsx)(c,{className:"w-5 h-5 text-white"})}),(0,t.jsx)("h2",{className:"text-xl font-bold text-gray-800",children:"JSON構造"})]}),(0,t.jsx)("div",{className:"overflow-y-auto flex-1",children:(0,t.jsx)(m,{config:H.configData,docs:H.docs,onSelectProperty:R,onEditProperty:R,selectedPath:o})})]}),(0,t.jsxs)("div",{className:"bg-white/90 backdrop-blur-sm rounded-2xl shadow-xl border border-gray-100 p-6 flex flex-col max-h-[calc(100vh-250px)] hover:shadow-2xl transition-shadow duration-300",children:[(0,t.jsxs)("div",{className:"flex items-center justify-between mb-4",children:[(0,t.jsxs)("div",{className:"flex items-center gap-2",children:[(0,t.jsx)("div",{className:"w-8 h-8 bg-gradient-to-br from-indigo-500 to-indigo-600 rounded-lg flex items-center justify-center",children:(0,t.jsx)(P,{className:"w-5 h-5 text-white"})}),(0,t.jsx)("h2",{className:"text-xl font-bold text-gray-800",children:"プロパティ詳細"})]}),O&&(0,t.jsxs)("button",{onClick:q,className:"flex items-center gap-2 px-4 py-2 bg-gradient-to-r from-green-500 to-emerald-600 text-white rounded-lg hover:from-green-600 hover:to-emerald-700 shadow-md hover:shadow-lg transition-all duration-200 transform hover:scale-105",children:[(0,t.jsx)(P,{className:"w-4 h-4"}),(0,t.jsx)("span",{className:"font-medium",children:"保存"})]})]}),(0,t.jsx)("div",{className:"overflow-y-auto flex-1",children:o&&N?(0,t.jsxs)("div",{className:"space-y-6",children:[(0,t.jsxs)("div",{children:[(0,t.jsx)("label",{className:"block text-sm font-semibold text-gray-700 mb-2",children:"パス"}),(0,t.jsx)("div",{className:"text-sm text-gray-700 bg-gradient-to-r from-blue-50 to-indigo-50 p-3 rounded-lg font-mono border border-blue-200 shadow-sm",children:o})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("label",{className:"block text-sm font-semibold text-gray-700 mb-2",children:"説明"}),(0,t.jsx)("textarea",{value:N.description,onChange:e=>{let t={...N,description:e.target.value};v(t),A(F(t,k))},className:"w-full border-2 border-gray-200 rounded-lg p-3 min-h-[120px] text-sm focus:border-blue-400 focus:ring-2 focus:ring-blue-200 transition-all duration-200 shadow-sm hover:shadow-md",placeholder:"このプロパティの説明を入力してください"})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("label",{className:"block text-sm font-semibold text-gray-700 mb-2",children:"備考"}),(0,t.jsx)("textarea",{value:N.notes,onChange:e=>{let t={...N,notes:e.target.value};v(t),A(F(t,k))},className:"w-full border-2 border-gray-200 rounded-lg p-3 min-h-[100px] text-sm focus:border-blue-400 focus:ring-2 focus:ring-blue-200 transition-all duration-200 shadow-sm hover:shadow-md",placeholder:"追加のメモや注意事項"})]})]}):(0,t.jsxs)("div",{className:"flex flex-col items-center justify-center py-20",children:[(0,t.jsx)("div",{className:"w-20 h-20 bg-gradient-to-br from-gray-100 to-gray-200 rounded-full flex items-center justify-center mb-4",children:(0,t.jsx)(c,{className:"w-10 h-10 text-gray-400"})}),(0,t.jsx)("p",{className:"text-sm text-gray-600 font-medium",children:"プロパティを選択してください"}),(0,t.jsx)("p",{className:"text-xs text-gray-500 mt-1",children:"左側のツリーから項目を選択"})]})})]})]})]}),(0,t.jsx)(f,{isOpen:n,currentPath:y,multiSelect:!0,filterJsonOnly:!0,onSelect:e=>{W(e),d(!1)},onClose:()=>d(!1)}),(0,t.jsx)(j,{isOpen:h,onClose:()=>x(!1),onExport:Z,currentSettings:M,rootPath:y}),(0,t.jsx)(S,{toasts:E,onRemove:e=>{D(t=>t.filter(t=>t.id!==e))}})]})}e.s(["default",()=>T],52211)}]);