1import{P as i,j as e,L as r}from"./main-Bo0oayNO.js";import{u as d}from"./useTranslation-W7WX_0C9.js";function c(){const{t}=d("admin"),{areas:a}=i.useLoaderData();return e.jsxs("div",{className:"space-y-6",children:[e.jsx("div",{className:"flex justify-between items-center",children:e.jsxs("div",{children:[e.jsx("h1",{className:"text-2xl font-bold text-gray-900",children:t("widgets.title")}),e.jsx("p",{className:"text-gray-600",children:"Manage sidebar widgets and their display order"})]})}),e.jsx("div",{className:"space-y-4",children:a.length===0?e.jsxs("div",{className:"card p-8 text-center",children:[e.jsx("svg",{className:"w-16 h-16 mx-auto text-gray-300 mb-4",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:e.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M4 5a1 1 0 011-1h14a1 1 0 011 1v2a1 1 0 01-1 1H5a1 1 0 01-1-1V5zM4 13a1 1 0 011-1h6a1 1 0 011 1v6a1 1 0 01-1 1H5a1 1 0 01-1-1v-6zM16 13a1 1 0 011-1h2a1 1 0 011 1v6a1 1 0 01-1 1h-2a1 1 0 01-1-1v-6z"})}),e.jsx("h3",{className:"text-lg font-medium text-gray-900 mb-2",children:"No widget areas"}),e.jsx("p",{className:"text-gray-600",children:"Widget areas will be created automatically"})]}):a.map(s=>e.jsxs("div",{className:"card p-4 flex items-center justify-between",children:[e.jsxs("div",{children:[e.jsx("h3",{className:"font-medium text-gray-900",children:s.name}),e.jsx("p",{className:"text-sm text-gray-500",children:s.description||`Slug: ${s.slug}`}),e.jsxs("p",{className:"text-sm text-gray-400 mt-1",children:[s.widgetCount," ",s.widgetCount===1?"widget":"widgets"]})]}),e.jsx("div",{className:"flex items-center gap-2",children:e.jsxs(r,{to:"/admin/widgets/$areaId",params:{areaId:s.id},className:"btn-primary",children:[e.jsx("svg",{className:"w-4 h-4 mr-1",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:e.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M11 5H6a2 2 0 00-2 2v11a2 2 0 002 2h11a2 2 0 002-2v-5m-1.414-9.414a2 2 0 112.828 2.828L11.828 15H9v-2.828l8.586-8.586z"})}),t("widgets.editWidgets")]})})]},s.id))}),e.jsx("div",{className:"card p-4 bg-blue-50 border-blue-200",children:e.jsxs("div",{className:"flex gap-3",children:[e.jsx("svg",{className:"w-5 h-5 text-blue-600 flex-shrink-0 mt-0.5",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:e.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M13 16h-1v-4h-1m1-4h.01M21 12a9 9 0 11-18 0 9 9 0 0118 0z"})}),e.jsxs("div",{children:[e.jsx("h4",{className:"font-medium text-blue-900",children:"About Widgets"}),e.jsx("p",{className:"text-sm text-blue-700 mt-1",children:"Widgets are displayed in the blog sidebar. You can add different widget types like search, recent posts, categories, tags, newsletter signup, and custom content. Drag and drop to reorder widgets."})]})]})})]})}export{c as component};
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.