{"_id":"@arthsrn/sanity-v4-plugin-lucide-icons","name":"@arthsrn/sanity-v4-plugin-lucide-icons","dist-tags":{"latest":"1.0.3"},"versions":{"1.0.3":{"name":"@arthsrn/sanity-v4-plugin-lucide-icons","version":"1.0.3","description":"Sanity plugin to select and preview Lucide icons in the Sanity Studio","keywords":["sanity","sanity-plugin","lucide","icons","sanity-studio","lucide-icons","sanity-lucide","sanity-icons"],"repository":{"type":"git","url":"git+https://github.com/contentwrap/sanity-plugin-lucide-icon-picker.git"},"homepage":"https://github.com/contentwrap/sanity-plugin-lucide-icon-picker#readme","bugs":{"url":"https://github.com/contentwrap/sanity-plugin-lucide-icon-picker/issues"},"license":"MIT","author":{"name":"ContentWrap","email":"tamba@contentwrap.io"},"sideEffects":false,"type":"module","exports":{".":{"source":"./src/index.ts","import":"./dist/index.js","default":"./dist/index.js"},"./package.json":"./package.json"},"main":"./dist/index.js","types":"./dist/index.d.ts","sanityPlugin":{"verifyPackage":{"eslintImports":false,"sanityV2Json":false}},"scripts":{"build":"plugin-kit verify-package --silent && pkg-utils build --strict --check --clean","format":"prettier --write --cache --ignore-unknown .","link-watch":"plugin-kit link-watch","lint":"eslint .","prepublishOnly":"npm run build","watch":"pkg-utils watch --strict"},"dependencies":{"lucide-react":"^0.532.0"},"devDependencies":{"@sanity/browserslist-config":"^1.0.5","@sanity/incompatible-plugin":"^1.0.5","@sanity/pkg-utils":"^7.8.10","@sanity/plugin-kit":"^4.0.19","@trivago/prettier-plugin-sort-imports":"^5.2.2","@types/react":"^19.1.8","@typescript-eslint/eslint-plugin":"^8.35.0","@typescript-eslint/parser":"^8.35.0","eslint":"^8.57.1","eslint-config-prettier":"^10.1.5","eslint-config-sanity":"^7.1.4","eslint-plugin-prettier":"^5.5.1","eslint-plugin-react":"^7.37.5","eslint-plugin-react-hooks":"^5.2.0","prettier":"^3.6.2","prettier-plugin-packagejson":"^2.5.17","typescript":"^5.8.3"},"peerDependencies":{"@sanity/icons":"^3.7.0","@sanity/ui":"^2 || ^3","react":"^18 || ^19","sanity":"^4.11.0"},"browserslist":"extends @sanity/browserslist-config","engines":{"node":">=18"},"packageManager":"pnpm@9.15.1+sha512.1acb565e6193efbebda772702950469150cf12bcc764262e7587e71d19dc98a423dff9536e57ea44c49bdf790ff694e83c27be5faa23d67e0c033b583be4bfcf","gitHead":"a15e82149312708d4e058db96895eff1d490724d","_id":"@arthsrn/sanity-v4-plugin-lucide-icons@1.0.3","_nodeVersion":"22.20.0","_npmVersion":"11.6.2","dist":{"integrity":"sha512-sI8kDogodNnkZ4asfWjJbitmfg/dVNBpEGnboXXkaULZqQtf9R8Es0psazcbhSRYoe7oQgzlh3uDOWrncec3mw==","shasum":"22ba004cddac547dfb63747a5acb4478ede38078","tarball":"https://registry.npmjs.org/@arthsrn/sanity-v4-plugin-lucide-icons/-/sanity-v4-plugin-lucide-icons-1.0.3.tgz","fileCount":12,"unpackedSize":28154,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEUCIQCunIMWb9rG1aK3kG4G9rFAsRyk2F8f1aVRe+crn35YbAIgcckiDbwfSC6KlhO4XbxqrS9COvUTggMObpGfEfgo/w8="}]},"_npmUser":{"name":"arthsrn","email":"arthsrnn@gmail.com"},"directories":{},"maintainers":[{"name":"arthsrn","email":"arthsrnn@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/sanity-v4-plugin-lucide-icons_1.0.3_1761608392074_0.709802640978807"},"_hasShrinkwrap":false}},"time":{"created":"2025-10-27T23:39:51.955Z","1.0.3":"2025-10-27T23:39:52.272Z","modified":"2025-10-27T23:39:52.611Z"},"maintainers":[{"name":"arthsrn","email":"arthsrnn@gmail.com"}],"description":"Sanity plugin to select and preview Lucide icons in the Sanity Studio","homepage":"https://github.com/contentwrap/sanity-plugin-lucide-icon-picker#readme","keywords":["sanity","sanity-plugin","lucide","icons","sanity-studio","lucide-icons","sanity-lucide","sanity-icons"],"repository":{"type":"git","url":"git+https://github.com/contentwrap/sanity-plugin-lucide-icon-picker.git"},"author":{"name":"ContentWrap","email":"tamba@contentwrap.io"},"bugs":{"url":"https://github.com/contentwrap/sanity-plugin-lucide-icon-picker/issues"},"license":"MIT","readme":"<div align=\"center\">\r\n  <h1>Sanity Lucide Icon Picker</h1>\r\n  <h3>A beautiful icon picker plugin for Sanity Studio with 1,600+ Lucide icons.</h3>\r\n  <p><em>Developed and maintained by <a href=\"https://contentwrap.io\" target=\"_blank\">ContentWrap</a></em></p>\r\n\r\n  <img src=\"https://img.shields.io/npm/v/sanity-plugin-lucide-icon-picker\" alt=\"npm version\" />\r\n  <img src=\"https://img.shields.io/badge/TypeScript-007ACC?logo=typescript&logoColor=white\" alt=\"TypeScript\" />\r\n  <img src=\"https://img.shields.io/badge/Sanity-F03E2F?logo=sanity&logoColor=white\" alt=\"Sanity\" />\r\n  <img src=\"https://img.shields.io/npm/l/sanity-plugin-lucide-icon-picker?style&color=5D6D7E\" alt=\"MIT License\" />\r\n\r\n  <br>\r\n  <br>\r\n\r\n  <img src=\"demo.gif\" alt=\"Sanity Lucide Icon Picker Preview\" />\r\n</div>\r\n\r\n---\r\n\r\n## Features\r\n\r\n- **1,600+ icons**: Access to the complete Lucide Icons library\r\n- **Smart search**: Quickly find icons with intelligent search functionality\r\n- **Responsive design**: Works seamlessly on desktop and mobile devices\r\n- **High performance**: Virtualized rendering and lazy loading for smooth experience\r\n- **Configurable**: Flexible options for filtering icons\r\n- **Preview support**: Built-in preview function for Sanity Studio\r\n\r\n---\r\n\r\n## Installation\r\n\r\n```sh\r\npnpm add sanity-plugin-lucide-icon-picker\r\n# or\r\nyarn add sanity-plugin-lucide-icon-picker\r\n# or\r\nnpm install sanity-plugin-lucide-icon-picker\r\n```\r\n\r\n---\r\n\r\n## Usage\r\n\r\n**1. Add the plugin to your Sanity config:**\r\n\r\n```ts\r\n// sanity.config.ts\r\nimport { defineConfig } from 'sanity';\r\nimport { lucideIconPicker } from 'sanity-plugin-lucide-icon-picker';\r\n\r\nexport default defineConfig({\r\n  // ...\r\n  plugins: [lucideIconPicker()],\r\n});\r\n```\r\n\r\n**2. Use the `lucide-icon` type in your schema:**\r\n\r\n```ts\r\n// schemas/myDocument.ts\r\nimport { defineType } from 'sanity';\r\n\r\nexport default defineType({\r\n  name: 'myDocument',\r\n  title: 'My Document',\r\n  type: 'document',\r\n  fields: [\r\n    {\r\n      name: 'icon',\r\n      title: 'Icon',\r\n      type: 'lucide-icon',\r\n    },\r\n    // ... other fields\r\n  ],\r\n});\r\n```\r\n\r\n---\r\n\r\n## Configuration Options\r\n\r\n### Icon Filtering\r\n\r\nLimit available icons to a specific whitelist:\r\n\r\n```ts\r\n{\r\n  name: 'icon',\r\n  title: 'Social Icon',\r\n  type: 'lucide-icon',\r\n  options: {\r\n    allowedIcons: ['facebook', 'twitter', 'instagram', 'linkedin'],\r\n  }\r\n}\r\n```\r\n\r\nThe `allowedIcons` option accepts an array of icon names (in kebab-case format) to show only those specific icons in the picker.\r\n\r\n---\r\n\r\n## Frontend Integration\r\n\r\n### React with DynamicIcon\r\n\r\nIcons are stored as kebab-case strings (e.g., `\"arrow-right\"`, `\"chevron-down\"`). Use Lucide's `DynamicIcon` component to render them:\r\n\r\n```jsx\r\nimport { DynamicIcon } from 'lucide-react/dynamic';\r\n\r\n// Your Sanity data\r\nconst iconName = 'arrow-right'; // from your Sanity document\r\n\r\n// Usage\r\nexport default function MyComponent() {\r\n  return (\r\n    <div>\r\n      <DynamicIcon name={iconName} size={24} />\r\n    </div>\r\n  );\r\n}\r\n```\r\n\r\n---\r\n\r\n## Performance\r\n\r\nThe plugin is optimized for performance with:\r\n\r\n- **Virtualized rendering** - Only visible icons are rendered\r\n- **Lazy loading** - Icons load on-demand\r\n- **Efficient search** - Fast text-based search with debouncing\r\n- **Tree shaking** - Only imported icons are included in your bundle\r\n\r\nFor optimal frontend performance:\r\n\r\n1. Use dynamic imports to load only needed icons\r\n2. Consider using the `allowedIcons` option to limit available icons\r\n\r\n---\r\n\r\n## Requirements\r\n\r\n- Sanity Studio v3 or v4\r\n- React 18 or 19\r\n- TypeScript (recommended)\r\n\r\n---\r\n\r\n## License\r\n\r\nMIT © ContentWrap\r\n\r\n---\r\n\r\n## About the Developer\r\n\r\nThis package is developed and maintained by [ContentWrap](https://contentwrap.io), a digital product agency specializing in Sanity and modern web development.\r\n","readmeFilename":"README.md","_rev":"1-b605d0d0f48f370361bf8f0b69120399"}