{"_id":"@atlassianlabs/jql-ast","_rev":"10-6a60b39703b3198cc2578ffeeb0b5f7d","name":"@atlassianlabs/jql-ast","dist-tags":{"latest":"2.1.0"},"versions":{"0.0.1":{"name":"@atlassianlabs/jql-ast","version":"0.0.1","keywords":["jql","antlr4","grammar","jira"],"author":{"name":"Atlassian"},"license":"Apache-2.0","_id":"@atlassianlabs/jql-ast@0.0.1","maintainers":[{"name":"doklovic","email":"doklovic@atlassian.com"},{"name":"prkb","email":"pramodkb@outlook.com"},{"name":"crumley","email":"crumley@gmail.com"},{"name":"nrundquist","email":"nrundquist@atlassian.com"},{"name":"dkolbly-atlassian","email":"dkolbly@atlassian.com"},{"name":"kpainter-atl","email":"kpainter@atlassian.com"},{"name":"soneymathew","email":"soney.mathew@gmail.com"}],"homepage":"https://bitbucket.org/atlassian/jql-grammar#readme","dist":{"shasum":"22116f4b58a69117a74c5e382bb97305bd9b3afb","tarball":"https://registry.npmjs.org/@atlassianlabs/jql-ast/-/jql-ast-0.0.1.tgz","fileCount":218,"integrity":"sha512-MTU/ibDIqdKNQKN1QeEXI26RIaPydlCeb4RBLRehaFiqny8ToPwIFIcmn60asUS/dRdPzum07oPIufjEFh/40g==","signatures":[{"sig":"MEUCIQDJeMh3ALQ2PHG+z4odOqWcu2RorjEHn5a/WNCr+BJTFgIgL5Zi41chhwN/yA3r/Tk18BggsLu1gtqnIq2eNW2zT9Q=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":340195,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJhsqgjCRA9TVsSAnZWagAAxYoQAJ2YczyMDsTwZjbvYNd2\nfMDo2A8vSt8H6Nh9iShGWTXTkozp7mGLOl6+4e7f+lLV/4kEx4jXrF++3ERQ\nQUrcTJ1X1iWC/7ccjEJDA7jOmbagEKlqJ/HLHUWwAhySSd0NVKOsslPwCzVz\nt0kJacBZgHUNUG0qAMULYXgJ3VNSurET1EQRNnYQHz1r0sj34p9BKMdAxuaM\nhIJ6K3aKs+ouMPY4luY3t4bh7h5XUL3hIMJPIR7HKC6zQTYIYEKptXpoIPfA\nD1/KMPpY7OaCEUrwz2I/yWhGmwP9dC/l9DqxdCeiKzIuT4inedJSyGpD3ZDJ\nmqLWS7z/w4N6ZEgaiIWIqa3KiPT3hGUpgAIKp9/5+I4iS5SUQM3qtpVXkvo7\nkJEL3L+VcyZZL31cr3NwAEyFvoo3gAWH5g86bOAUoMo17VMLbVtrWC0NrkjL\njtYxO8WP4j0Zkbyh3gnB0OlDvqaU29BqTnB5343/BMOXIp5Pxu+zyBsJxNbB\nRh4ZEdGWJM4ZY3YCGfxtZA8flJZy4Ay+N29X/R6olgFgowYata2XnmKdfJ6b\nOw/xUBeGCY6baIOz2S4IvxNFzfcyTuH2He0JaK4PDfddc/q2yTzAh8Tk3zFz\neqn+7Di3q2/yLIpOZ0e50sMZhmx7m9wrgRW49F2lZmHxOH9xy7CWwRsE2CbT\nrMPt\r\n=mc5b\r\n-----END PGP SIGNATURE-----\r\n"},"main":"dist/cjs/index.js","module":"dist/esm/index.js","engines":{"node":">=6.0.0"},"typings":"dist/types/index.d.ts","_npmUser":{"name":"kpainter-atl","email":"kpainter@atlassian.com"},"repository":{"url":"git+https://bitbucket.org/atlassian/jql-grammar.git","type":"git"},"_npmVersion":"6.14.15","description":"JQL ast","directories":{},"sideEffects":false,"_nodeVersion":"14.18.0","dependencies":{"antlr4ts":"^0.5.0-alpha.3","memoize-one":"^5.1.1","@babel/runtime":"^7.15.4","@atlassianlabs/jql-parser":"^0.0.1"},"module:es2019":"dist/es2019/index.js","_hasShrinkwrap":false,"_npmOperationalInternal":{"tmp":"tmp/jql-ast_0.0.1_1639098402863_0.8186692895806336","host":"s3://npm-registry-packages"}},"1.0.0":{"name":"@atlassianlabs/jql-ast","version":"1.0.0","keywords":["jql","antlr4","grammar","jira"],"author":{"name":"Atlassian"},"license":"Apache-2.0","_id":"@atlassianlabs/jql-ast@1.0.0","maintainers":[{"name":"doklovic","email":"doklovic@atlassian.com"},{"name":"prkb","email":"pramodkb@outlook.com"},{"name":"crumley","email":"crumley@gmail.com"},{"name":"nrundquist","email":"nrundquist@atlassian.com"},{"name":"dkolbly-atlassian","email":"dkolbly@atlassian.com"},{"name":"kpainter-atl","email":"kpainter@atlassian.com"},{"name":"soneymathew","email":"soney.mathew@gmail.com"}],"homepage":"https://bitbucket.org/atlassian/jql-grammar#readme","dist":{"shasum":"95974f543e34840410fca13bd61fc85ce4215442","tarball":"https://registry.npmjs.org/@atlassianlabs/jql-ast/-/jql-ast-1.0.0.tgz","fileCount":218,"integrity":"sha512-jXJ7fdH2A2YZPFhjMoi/A1Mvccdwtl7jBkP7XarU/amuVuLNzJSqzy1WzL9L99asIa+ff4w+nDNNIJJYzfvigw==","signatures":[{"sig":"MEYCIQCPPRXe7yf1ouUDPovCcgZuft52mW4z+ve8qOOpl1bP1QIhAOZW+iH0HLr/uLoJrDRoMpemWa/FrrDa++iO9z8DxxXM","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":340209,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJiEvLEACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmqUKhAApMFQFSRSc42lXjxc1dE0Y04IRV7ZtaogWSKve/ZDq99pyASs\r\nzdKt69YPhjUhBbCEb+OV4OicysOfeQQmJeSqjPwvfjvHzyfL495VaNGbrThP\r\n5VX1PfksLqOCBCeLmfXFj9L0NkDxFuAVh+yZVtRRP/WYuuBEL8DDP2bkjP77\r\nDJ4g2VWZ8zFN8hYfMoW7MnrX6BmVMyKlgffYIOSoECU0IzJKI/Za90EY0Uoj\r\nOSsCww9LyKRA2WvCRd1m5juHA7tnx9+5OwV4kGJ12QhWSAHvjdbM7s2C2yLC\r\n1mo+nkMD1YOhmZfa47kXDOhaFGoU740qDFJ9eyXt8S++DkJlW86brGoPjxG7\r\ncp2JfSkV9oISHvvMgsPkYi3dMANoZYHU8Euz5j8CnW7uRFC3+7vdOaa24g8e\r\nDzUzIdffkYQPA91WhodRYT3437CtjW+B0gvD64SX7XFHG9fSH3IYJBe9HNfQ\r\nZHwaiKszXtRtuPNoALuZSb000iBt2Ozgpb7X6U+OmP7SE9zBc1ZkdqUsq8iT\r\n1Wssmx2cqEk98tpJ4E8jDWv1x6KRLRfUXv330Zmop2DnOWC2i5Q5xBtHnxGR\r\nAwc4MgB/iKlTTU6gaxV3yc3uMkeDd5LG8PcYDLNwVwSevYFNLV169pmd9v1e\r\n1FZco0XfM05vbJpwreDcas3V/nkoFpNWmWY=\r\n=VVwc\r\n-----END PGP SIGNATURE-----\r\n"},"main":"dist/cjs/index.js","module":"dist/esm/index.js","engines":{"node":">=6.0.0"},"typings":"dist/types/index.d.ts","_npmUser":{"name":"kpainter-atl","email":"kpainter@atlassian.com"},"repository":{"url":"git+https://bitbucket.org/atlassian/jql-grammar.git","type":"git"},"_npmVersion":"6.14.12","description":"JQL ast","directories":{},"sideEffects":false,"_nodeVersion":"12.22.1","dependencies":{"antlr4ts":"^0.5.0-alpha.3","memoize-one":"^5.1.1","@babel/runtime":"^7.15.4","@atlassianlabs/jql-parser":"^1.0.0"},"module:es2019":"dist/es2019/index.js","_hasShrinkwrap":false,"_npmOperationalInternal":{"tmp":"tmp/jql-ast_1.0.0_1645408964035_0.9455858454837236","host":"s3://npm-registry-packages"}},"2.0.0":{"name":"@atlassianlabs/jql-ast","version":"2.0.0","author":{"name":"Atlassian Pty Ltd"},"_id":"@atlassianlabs/jql-ast@2.0.0","maintainers":[{"name":"doklovic","email":"doklovic@atlassian.com"},{"name":"prkb","email":"pramodkb@outlook.com"},{"name":"crumley","email":"crumley@gmail.com"},{"name":"nrundquist","email":"nrundquist@atlassian.com"},{"name":"dkolbly-atlassian","email":"dkolbly@atlassian.com"},{"name":"kpainter-atl","email":"kpainter@atlassian.com"},{"name":"soneymathew","email":"soney.mathew@gmail.com"}],"homepage":"https://bitbucket.org/atlassian/atlassian-frontend#readme","bugs":{"url":"https://bitbucket.org/atlassian/atlassian-frontend/issues"},"dist":{"shasum":"87509ac3908667f5162555b7e9169f18bc501cad","tarball":"https://registry.npmjs.org/@atlassianlabs/jql-ast/-/jql-ast-2.0.0.tgz","fileCount":394,"integrity":"sha512-G+PtPeh1kdnrTd8Oy0H8IWgd+M5T/IPk5rMowwSGHmX6pfoAdchRDQx7BY/8NUIuEMFImJ9gjsdRM0XNN+MRfw==","signatures":[{"sig":"MEUCICDk6IIkhCvx1UhrhICC5vkO/xwU2zEapeP3kaUnMiosAiEA0XwOv5jrv+1iYba1or/ELhotkb7oveJJeb0TjclDuaE=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":752379},"main":"dist/cjs/index.js","types":"dist/types/index.d.ts","module":"dist/esm/index.js","gitHead":"1950fd47b1d1170072a3210328249c06e8897f0f","_npmUser":{"name":"kpainter-atl","email":"kpainter@atlassian.com"},"prettier":"@atlassian/atlassian-frontend-prettier-config-1.0.0","atlassian":{"team":"Jira Platform: Search Experience / Empanada","releaseModel":"continuous","inPublicMirror":false},"techstack":{"@repo/internal":{"styling":["static","emotion"],"theming":["react-context","tokens"],"analytics":["analytics-next"],"dom-events":"use-bind-event-listener","deprecation":["no-deprecated-imports"],"ui-components":["lite-mode"]},"@atlassian/frontend":{"import-structure":["atlassian-conventions"],"circular-dependencies":["file-and-folder-level"]}},"af:exports":{".":"./src/index.ts"},"repository":{"url":"git+https://bitbucket.org/atlassian/atlassian-frontend.git","type":"git"},"_npmVersion":"8.5.5","description":"JQL Abstract Syntax Tree","directories":{},"sideEffects":false,"_nodeVersion":"16.15.0","atlaskit:src":"src/index.ts","dependencies":{"lodash":"^4.17.21","antlr4ts":"^0.5.0-alpha.3","memoize-one":"^6.0.0","@babel/runtime":"^7.0.0","@atlassianlabs/jql-parser":"^1.0.0"},"module:es2019":"dist/es2019/index.js","publishConfig":{"registry":"https://registry.npmjs.org/"},"typesVersions":{">=4.5 <4.9":{"*":["dist/types-ts4.5/*","dist/types-ts4.5/index.d.ts"]}},"_hasShrinkwrap":false,"devDependencies":{"fast-csv":"^4.3.1","typescript":"~4.9.5","@atlaskit/ssr":"*","@atlaskit/docs":"*","wait-for-expect":"^1.2.0","@atlaskit/webdriver-runner":"*","@atlaskit/visual-regression":"*","@atlassian/atlassian-frontend-prettier-config-1.0.0":"npm:@atlassian/atlassian-frontend-prettier-config@1.0.0"},"_npmOperationalInternal":{"tmp":"tmp/jql-ast_2.0.0_1685687593666_0.8710505819655889","host":"s3://npm-registry-packages"}},"2.1.0":{"name":"@atlassianlabs/jql-ast","version":"2.1.0","author":{"name":"Atlassian Pty Ltd"},"_id":"@atlassianlabs/jql-ast@2.1.0","maintainers":[{"name":"doklovic","email":"doklovic@atlassian.com"},{"name":"prkb","email":"pramodkb@outlook.com"},{"name":"crumley","email":"crumley@gmail.com"},{"name":"nrundquist","email":"nrundquist@atlassian.com"},{"name":"dkolbly-atlassian","email":"dkolbly@atlassian.com"},{"name":"kpainter-atl","email":"kpainter@atlassian.com"},{"name":"soneymathew","email":"soney.mathew@gmail.com"}],"homepage":"https://bitbucket.org/atlassian/atlassian-frontend#readme","bugs":{"url":"https://bitbucket.org/atlassian/atlassian-frontend/issues"},"dist":{"shasum":"4b871aba318c734a80ff85061182b4f730826692","tarball":"https://registry.npmjs.org/@atlassianlabs/jql-ast/-/jql-ast-2.1.0.tgz","fileCount":485,"integrity":"sha512-6anCBAlMj7qzg5yQ3GMDEjC95X7QcWAnBD2gMvvkFidNZJKtoqJtRjeMl8a7aOlRI4uprcBVSuptYPyKFcDooA==","signatures":[{"sig":"MEUCIQDy1/ycZw2HidhpU/PS1pewiSiEgDbPp9atzafTKb0FTwIgby4SfoFwIEhaHnnMqkRm6Atlqs73kDGWFWkTjYFVy8w=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":846291},"main":"dist/cjs/index.js","types":"dist/types/index.d.ts","module":"dist/esm/index.js","gitHead":"f9d1e23bb972181f6ca3c229f4deb4bec6170515","_npmUser":{"name":"kpainter-atl","email":"kpainter@atlassian.com"},"prettier":"@atlassian/atlassian-frontend-prettier-config-1.0.0","atlassian":{"team":"Jira Platform: Search Experience / Empanada","releaseModel":"continuous","inPublicMirror":false},"techstack":{"@repo/internal":{"styling":["static","emotion"],"theming":["react-context","tokens"],"analytics":["analytics-next"],"dom-events":"use-bind-event-listener","deprecation":["no-deprecated-imports"],"ui-components":["lite-mode"]},"@atlassian/frontend":{"import-structure":["atlassian-conventions"],"circular-dependencies":["file-and-folder-level"]}},"af:exports":{".":"./src/index.ts"},"repository":{"url":"git+https://bitbucket.org/atlassian/atlassian-frontend.git","type":"git"},"_npmVersion":"8.5.5","description":"JQL Abstract Syntax Tree","directories":{},"sideEffects":false,"_nodeVersion":"16.15.0","atlaskit:src":"src/index.ts","dependencies":{"lodash":"^4.17.21","antlr4ts":"0.5.0-alpha.4","memoize-one":"^6.0.0","@babel/runtime":"^7.0.0","@atlassianlabs/jql-parser":"^1.0.0"},"module:es2019":"dist/es2019/index.js","typesVersions":{">=4.5 <4.9":{"*":["dist/types-ts4.5/*","dist/types-ts4.5/index.d.ts"]}},"_hasShrinkwrap":false,"devDependencies":{"fast-csv":"^4.3.1","typescript":"~4.9.5","wait-for-expect":"^1.2.0","@atlassian/atlassian-frontend-prettier-config-1.0.0":"npm:@atlassian/atlassian-frontend-prettier-config@1.0.0"},"_npmOperationalInternal":{"tmp":"tmp/jql-ast_2.1.0_1689135699342_0.4391585129986906","host":"s3://npm-registry-packages"}}},"time":{"created":"2021-12-10T01:06:42.811Z","modified":"2026-06-24T07:25:57.157Z","0.0.1":"2021-12-10T01:06:43.039Z","1.0.0":"2022-02-21T02:02:44.456Z","2.0.0":"2023-06-02T06:33:13.886Z","2.1.0":"2023-07-12T04:21:39.679Z"},"bugs":{"url":"https://bitbucket.org/atlassian/atlassian-frontend/issues"},"author":{"name":"Atlassian Pty Ltd"},"homepage":"https://bitbucket.org/atlassian/atlassian-frontend#readme","repository":{"url":"git+https://bitbucket.org/atlassian/atlassian-frontend.git","type":"git"},"description":"JQL Abstract Syntax Tree","maintainers":[{"email":"eng-development-tooling-artifacts@atlassian.com","name":"atlassianartifactteam"}],"readme":"# JQL AST\n\n[![Atlassian license](https://img.shields.io/badge/license-Apache%202.0-blue.svg?style=flat-square)](LICENSE)\n\nJQL Abstract Syntax Tree (JAST) is a json schema used to represent parsed JQL.\n\n### Goals\n- A Jast from one platform should be re-usable as a Jast from another (Java ↔︎ JS ↔︎ iOS)\n- Contain enough information to render a rich JQL editing experience (e.g. Syntax highlighting)\n- Represent invalid and partially formed JQL (and contain detailed information on syntax errors)\n\n### What Jast is not\n- Does not represent every detail appearing in the real syntax, but rather just the structural or content-related details (e.g. Parentheses are implicit in the tree structure so they are not included as nodes)\n- Does not contain any data specific to a individual Jira instance (besides the string of the original JQL query itself). Eg: no knowledge of available fields/users/values/operators\n- Syntax validation should not be performed on the Jast (this is done using the CST)\n- Autocomplete suggestions should not be populated using the Jast (this is done using the CST)\n\n### Use cases\n- Syntax highlighting\n- Rendering errors\n\n## Basic usage\n\nTo generate an AST you need the JQL string you want to parse and a `JastBuilder`.\n\n```typescript\nimport { JastBuilder, Jast } from \"@atlassianlabs/jql-ast\";\n\nconst someJqlQuery = 'issuetype = bug';\nconst myJast: Jast = new JastBuilder().build(someJqlQuery);\n```\n\n## Installation\n\n```sh\nyarn add @atlassianlabs/jql-ast\n```\n\n## Documentation\n\nRefer to [docs](docs/README.md) for more details.\n\n## FAQ\n\n#### Why do we need an Abstact Syntaxt Tree (over the free CST)?\n\nANTLR4 auto-generated parsers already generate a Concrete Syntax Tree from a JQL string. This tree is more detailed than\nthe AST but otherwise VERY similar, why not just use that?\n\nThe main reason is that the CST doesn’t immediately fulfill all of the listed goals above. But there are some other\ndifferences to mention:\n\n- The produced CST is not directly under our control, so updates to ANTLR4 syntax implementation only need to cause\n  updates to the AST generator, no UI component updates necessary.\n- CST is not inherently serializable, but we can send a pre-parsed AST to be rendered early / in SSR without loading the\n  whole parser and ANTLR4 runtime immediately.\n- Since we control creation of the AST, we can make logically consistent transformations to it without going through the\n  parser again.\n- We can make sensible simplifications to the tree, e.g. combining ORDER BY into one terminal node instead of three,\n  collapsing inactive notCompoundOperators, etc.\n\n## Support\n\nFor developers outside of Atlassian looking for help, or to report issues, [please make a post on the community forum](https://community.developer.atlassian.com/c/atlassian-ecosystem-design).\nWe will monitor the forums and redirect topics to the appropriate maintainers.\n\n## License\nCopyright (c) 2021 - 2022 Atlassian and others. Apache 2.0 licensed, see [LICENSE](LICENSE) file.\n","readmeFilename":"README.md"}