{"version":3,"file":"ComponentShow-0O2I3MVy.js","sources":["../../../app/javascript/components/Website/src/pages/ComponentShow.tsx"],"sourcesContent":["import React from \"react\"\n\nimport Sandbox from \"../components/Sandbox\"\nimport { SandpackProvider } from \"@codesandbox/sandpack-react\"\nimport { useLoaderData } from \"react-router-dom\"\nimport sandpackIndexFile from \"./sandpackIndexFile\"\n\nexport default function ComponentShow() {\n const { examples } = useLoaderData()\n\n const source = examples[0].source\n\n const code = source\n .replace(\n /import (\\w+) from ('|\")\\.\\.\\/_(\\w+)('|\")/g,\n 'import { $1 } from \"playbook-ui\"'\n )\n .replace(\n /import \\{ (.*) \\} from ('|\")\\.\\.\\/(.*)('|\")/g,\n 'import { $1 } from \"playbook-ui\"'\n )\n\n return (\n <>\n \n \n \n \n )\n}\n"],"names":["ComponentShow","examples","useLoaderData","code","jsx","Fragment","SandpackProvider","sandpackIndexFile","Sandbox"],"mappings":"kaAOA,SAAwBA,GAAgB,CAChC,KAAA,CAAE,SAAAC,GAAaC,IAIfC,EAFSF,EAAS,CAAC,EAAE,OAGxB,QACC,4CACA,kCAAA,EAED,QACC,+CACA,kCAAA,EAGJ,OAEIG,MAAAC,EAAAA,SAAA,CAAA,SAAAD,EAAA,IAACE,EAAA,CACC,MAAO,CACL,UAAW,CACT,KAAAH,CACF,EACA,YAAa,CACX,KAAMI,EACN,OAAQ,EACV,CACF,EACA,SAAS,QACT,YAAa,CACX,MAAO,gBACP,aAAc,CACZ,cAAe,QACjB,CACF,EACA,QAAS,CACP,kBAAmB,CAAC,2CAA2C,EAC/D,QAAS,CACP,qBAAsB,yBACtB,oBAAqB,wBACvB,CACF,EAEA,eAACC,EAAQ,EAAA,CAAA,CAEb,CAAA,CAAA,CAEJ"}