Some checks failed
Build & Deploy / 🔍 Prepare (push) Successful in 20s
Build & Deploy / 🧪 QA (push) Failing after 34s
Build & Deploy / 🏗️ Build (push) Has started running
Build & Deploy / 🚀 Deploy (push) Has been cancelled
Build & Deploy / 🧪 Smoke Test (push) Has been cancelled
Build & Deploy / ⚡ Lighthouse (push) Has been cancelled
Build & Deploy / 🔔 Notify (push) Has been cancelled
1 line
1.4 KiB
Plaintext
1 line
1.4 KiB
Plaintext
{"version":3,"file":"index.js","names":["React","CodeCell","cellData","nowrap","textToShow","length","substring","noWrapStyle","whiteSpace","_jsx","className","style"],"sources":["../../../../../../src/elements/Table/DefaultCell/fields/Code/index.tsx"],"sourcesContent":["'use client'\nimport type { ClientCollectionConfig, CodeFieldClient, DefaultCellComponentProps } from 'payload'\n\nimport React from 'react'\n\nimport './index.scss'\n\nexport interface CodeCellProps extends DefaultCellComponentProps<CodeFieldClient> {\n readonly collectionConfig: ClientCollectionConfig\n readonly nowrap?: boolean\n}\n\nexport const CodeCell: React.FC<CodeCellProps> = ({ cellData, nowrap }) => {\n const textToShow = cellData?.length > 100 ? `${cellData.substring(0, 100)}\\u2026` : cellData\n\n const noWrapStyle: React.CSSProperties = nowrap ? { whiteSpace: 'nowrap' } : {}\n\n return (\n <code className=\"code-cell\" style={noWrapStyle}>\n <span>{textToShow}</span>\n </code>\n )\n}\n"],"mappings":"AAAA;;;AAGA,OAAOA,KAAA,MAAW;AAElB,OAAO;AAOP,OAAO,MAAMC,QAAA,GAAoCA,CAAC;EAAEC,QAAQ;EAAEC;AAAM,CAAE;EACpE,MAAMC,UAAA,GAAaF,QAAA,EAAUG,MAAA,GAAS,MAAM,GAAGH,QAAA,CAASI,SAAS,CAAC,GAAG,YAAY,GAAGJ,QAAA;EAEpF,MAAMK,WAAA,GAAmCJ,MAAA,GAAS;IAAEK,UAAA,EAAY;EAAS,IAAI,CAAC;EAE9E,oBACEC,IAAA,CAAC;IAAKC,SAAA,EAAU;IAAYC,KAAA,EAAOJ,WAAA;cACjC,aAAAE,IAAA,CAAC;gBAAML;;;AAGb","ignoreList":[]} |