Files
klz-cables.com/.pnpm-store/v10/files/6e/06f95c86b83ca244b87e8b5791fa776e54bba55d8bed813d6d446ffd74ae8898934b1d6eb873f8ff4b6224c87416e82735ae2eb135affcd86379c143cd1b21
Marc Mintel 5397309103
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
fix(products): fix breadcrumbs and product filtering (backport from main)
2026-02-24 16:04:21 +01:00

1 line
2.1 KiB
Plaintext

{"version":3,"file":"traverseForLocalizedFields.js","names":["traverseForLocalizedFields","fields","field","localized","type","blocks","block","tabs","tab"],"sources":["../../src/utilities/traverseForLocalizedFields.ts"],"sourcesContent":["import type { ClientField, Field } from 'payload'\n\nexport const traverseForLocalizedFields = (fields: ClientField[] | Field[]): boolean => {\n for (const field of fields) {\n if ('localized' in field && field.localized) {\n return true\n }\n\n switch (field.type) {\n case 'array':\n case 'collapsible':\n case 'group':\n case 'row':\n if (field.fields && traverseForLocalizedFields(field.fields)) {\n return true\n }\n break\n\n case 'blocks':\n if (field.blocks) {\n for (const block of field.blocks) {\n if (block.fields && traverseForLocalizedFields(block.fields)) {\n return true\n }\n }\n }\n break\n\n case 'tabs':\n if (field.tabs) {\n for (const tab of field.tabs) {\n if ('localized' in tab && tab.localized) {\n return true\n }\n if ('fields' in tab && tab.fields && traverseForLocalizedFields(tab.fields)) {\n return true\n }\n }\n }\n break\n }\n }\n\n return false\n}\n"],"mappings":"AAEA,OAAO,MAAMA,0BAAA,GAA8BC,MAAA;EACzC,KAAK,MAAMC,KAAA,IAASD,MAAA,EAAQ;IAC1B,IAAI,eAAeC,KAAA,IAASA,KAAA,CAAMC,SAAS,EAAE;MAC3C,OAAO;IACT;IAEA,QAAQD,KAAA,CAAME,IAAI;MAChB,KAAK;MACL,KAAK;MACL,KAAK;MACL,KAAK;QACH,IAAIF,KAAA,CAAMD,MAAM,IAAID,0BAAA,CAA2BE,KAAA,CAAMD,MAAM,GAAG;UAC5D,OAAO;QACT;QACA;MAEF,KAAK;QACH,IAAIC,KAAA,CAAMG,MAAM,EAAE;UAChB,KAAK,MAAMC,KAAA,IAASJ,KAAA,CAAMG,MAAM,EAAE;YAChC,IAAIC,KAAA,CAAML,MAAM,IAAID,0BAAA,CAA2BM,KAAA,CAAML,MAAM,GAAG;cAC5D,OAAO;YACT;UACF;QACF;QACA;MAEF,KAAK;QACH,IAAIC,KAAA,CAAMK,IAAI,EAAE;UACd,KAAK,MAAMC,GAAA,IAAON,KAAA,CAAMK,IAAI,EAAE;YAC5B,IAAI,eAAeC,GAAA,IAAOA,GAAA,CAAIL,SAAS,EAAE;cACvC,OAAO;YACT;YACA,IAAI,YAAYK,GAAA,IAAOA,GAAA,CAAIP,MAAM,IAAID,0BAAA,CAA2BQ,GAAA,CAAIP,MAAM,GAAG;cAC3E,OAAO;YACT;UACF;QACF;QACA;IACJ;EACF;EAEA,OAAO;AACT","ignoreList":[]}