{"version":3,"file":"JSONArrayNode.cjs","sources":["../../../../../.yarn/__virtual__/react-json-tree-virtual-6a28170cd8/4/.yarn/berry/cache/react-json-tree-npm-0.19.0-c65c86bc20-10c0.zip/node_modules/react-json-tree/lib/JSONArrayNode.js"],"sourcesContent":["import React from 'react';\nimport JSONNestedNode from './JSONNestedNode.js';\n// Returns the \"n Items\" string for this node,\n// generating and caching it if it hasn't been created yet.\nfunction createItemString(data) {\n    return `${data.length} ${data.length !== 1 ? 'items' : 'item'}`;\n}\n// Configures <JSONNestedNode> to render an Array\nexport default function JSONArrayNode({ data, ...props }) {\n    return (React.createElement(JSONNestedNode, { ...props, data: data, nodeType: \"Array\", nodeTypeIndicator: \"[]\", createItemString: createItemString, expandable: data.length > 0 }));\n}\n"],"names":["React"],"mappings":";;;;;AAIA,SAAS,iBAAiB,MAAM;AAC5B,SAAO,GAAG,KAAK,MAAM,IAAI,KAAK,WAAW,IAAI,UAAU,MAAM;AACjE;AAEe,SAAS,cAAc,EAAE,MAAM,GAAG,SAAS;AACtD,SAAQA,eAAAA,QAAM,cAAc,gBAAgB,EAAE,GAAG,OAAO,MAAY,UAAU,SAAS,mBAAmB,MAAM,kBAAoC,YAAY,KAAK,SAAS,GAAG;AACrL;;","x_google_ignoreList":[0]}