@osdk/react-components 0.67.0-main-a0c6e14df406e2519cff5b4f2e9160376b2f3837 → 0.67.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (95) hide show
  1. package/CHANGELOG.md +2 -8
  2. package/build/browser/util/UserAgent.js +1 -1
  3. package/build/browser/util/UserAgent.js.map +1 -1
  4. package/build/cjs/chunk-25KCCJN5.cjs +11 -0
  5. package/build/cjs/{chunk-4S6ET33F.cjs.map → chunk-25KCCJN5.cjs.map} +1 -1
  6. package/build/cjs/{chunk-VSKFPLBO.cjs → chunk-3J2Z75WV.cjs} +4 -4
  7. package/build/cjs/{chunk-VSKFPLBO.cjs.map → chunk-3J2Z75WV.cjs.map} +1 -1
  8. package/build/cjs/{chunk-XTFRQHIY.cjs → chunk-563DKG4Y.cjs} +4 -4
  9. package/build/cjs/{chunk-XTFRQHIY.cjs.map → chunk-563DKG4Y.cjs.map} +1 -1
  10. package/build/cjs/{chunk-XTS5SKJR.cjs → chunk-5MO4EEKT.cjs} +4 -4
  11. package/build/cjs/{chunk-XTS5SKJR.cjs.map → chunk-5MO4EEKT.cjs.map} +1 -1
  12. package/build/cjs/{chunk-YCZHVGJZ.cjs → chunk-C7MVNJCL.cjs} +4 -4
  13. package/build/cjs/{chunk-YCZHVGJZ.cjs.map → chunk-C7MVNJCL.cjs.map} +1 -1
  14. package/build/cjs/chunk-DFULAPAD.cjs +48 -0
  15. package/build/cjs/{chunk-K5WARY3T.cjs.map → chunk-DFULAPAD.cjs.map} +1 -1
  16. package/build/cjs/chunk-GIUBOBJW.cjs +11 -0
  17. package/build/cjs/{chunk-6KS7GKSR.cjs.map → chunk-GIUBOBJW.cjs.map} +1 -1
  18. package/build/cjs/{chunk-SBCF4J6J.cjs → chunk-HWBP3XW3.cjs} +4 -4
  19. package/build/cjs/{chunk-SBCF4J6J.cjs.map → chunk-HWBP3XW3.cjs.map} +1 -1
  20. package/build/cjs/chunk-IMPQOR35.cjs +12 -0
  21. package/build/cjs/{chunk-UESMRV3Y.cjs.map → chunk-IMPQOR35.cjs.map} +1 -1
  22. package/build/cjs/{chunk-DNIGZSD5.cjs → chunk-KPRLMFE4.cjs} +4 -4
  23. package/build/cjs/{chunk-DNIGZSD5.cjs.map → chunk-KPRLMFE4.cjs.map} +1 -1
  24. package/build/cjs/{chunk-KGFEH2NS.cjs → chunk-LICMASXX.cjs} +4 -4
  25. package/build/cjs/{chunk-KGFEH2NS.cjs.map → chunk-LICMASXX.cjs.map} +1 -1
  26. package/build/cjs/{chunk-37OAMQ2X.cjs → chunk-LZTR5GS5.cjs} +3 -3
  27. package/build/cjs/chunk-LZTR5GS5.cjs.map +1 -0
  28. package/build/cjs/{chunk-SCN5X22B.cjs → chunk-N7PDSA27.cjs} +4 -4
  29. package/build/cjs/{chunk-SCN5X22B.cjs.map → chunk-N7PDSA27.cjs.map} +1 -1
  30. package/build/cjs/{chunk-YRB2QDPF.cjs → chunk-NZGG24BM.cjs} +4 -4
  31. package/build/cjs/{chunk-YRB2QDPF.cjs.map → chunk-NZGG24BM.cjs.map} +1 -1
  32. package/build/cjs/{chunk-BTXIYCMQ.cjs → chunk-OQKUMCWG.cjs} +4 -4
  33. package/build/cjs/{chunk-BTXIYCMQ.cjs.map → chunk-OQKUMCWG.cjs.map} +1 -1
  34. package/build/cjs/chunk-PH4KSD6G.cjs +11 -0
  35. package/build/cjs/{chunk-26AQAAVA.cjs.map → chunk-PH4KSD6G.cjs.map} +1 -1
  36. package/build/cjs/{chunk-QZH55426.cjs → chunk-QK76XGOF.cjs} +8 -8
  37. package/build/cjs/{chunk-QZH55426.cjs.map → chunk-QK76XGOF.cjs.map} +1 -1
  38. package/build/cjs/{chunk-WRYUNKQR.cjs → chunk-QZXF2R7Y.cjs} +4 -4
  39. package/build/cjs/{chunk-WRYUNKQR.cjs.map → chunk-QZXF2R7Y.cjs.map} +1 -1
  40. package/build/cjs/chunk-R7OMZVSD.cjs +11 -0
  41. package/build/cjs/{chunk-BZVDF2YT.cjs.map → chunk-R7OMZVSD.cjs.map} +1 -1
  42. package/build/cjs/{chunk-OJV43TFR.cjs → chunk-ROTAE5KE.cjs} +5 -5
  43. package/build/cjs/{chunk-OJV43TFR.cjs.map → chunk-ROTAE5KE.cjs.map} +1 -1
  44. package/build/cjs/{chunk-WIEDO6QO.cjs → chunk-TON5EEYH.cjs} +5 -5
  45. package/build/cjs/{chunk-WIEDO6QO.cjs.map → chunk-TON5EEYH.cjs.map} +1 -1
  46. package/build/cjs/chunk-UNB5WSKF.cjs +11 -0
  47. package/build/cjs/{chunk-W7GFTIH7.cjs.map → chunk-UNB5WSKF.cjs.map} +1 -1
  48. package/build/cjs/chunk-VV2UVLFE.cjs +34 -0
  49. package/build/cjs/{chunk-AQZNXIMO.cjs.map → chunk-VV2UVLFE.cjs.map} +1 -1
  50. package/build/cjs/chunk-VX53UNI5.cjs +11 -0
  51. package/build/cjs/{chunk-XZIBZYBX.cjs.map → chunk-VX53UNI5.cjs.map} +1 -1
  52. package/build/cjs/chunk-XBIDMNU3.cjs +12 -0
  53. package/build/cjs/{chunk-IUYNVDKR.cjs.map → chunk-XBIDMNU3.cjs.map} +1 -1
  54. package/build/cjs/{chunk-7V2X5LKA.cjs → chunk-ZK4Z6LBE.cjs} +4 -4
  55. package/build/cjs/{chunk-7V2X5LKA.cjs.map → chunk-ZK4Z6LBE.cjs.map} +1 -1
  56. package/build/cjs/public/action-form.cjs +4 -4
  57. package/build/cjs/public/document-viewer.cjs +4 -4
  58. package/build/cjs/public/email-viewer.cjs +3 -3
  59. package/build/cjs/public/experimental/action-form.cjs +5 -5
  60. package/build/cjs/public/experimental/cbac-picker.cjs +11 -11
  61. package/build/cjs/public/experimental/document-viewer.cjs +5 -5
  62. package/build/cjs/public/experimental/email-viewer.cjs +5 -5
  63. package/build/cjs/public/experimental/filter-list.cjs +16 -16
  64. package/build/cjs/public/experimental/image-viewer.cjs +5 -5
  65. package/build/cjs/public/experimental/markdown-renderer.cjs +7 -7
  66. package/build/cjs/public/experimental/object-table.cjs +23 -23
  67. package/build/cjs/public/experimental/pdf-viewer.cjs +25 -25
  68. package/build/cjs/public/experimental/spreadsheet-viewer.cjs +5 -5
  69. package/build/cjs/public/experimental/tiff-renderer.cjs +7 -7
  70. package/build/cjs/public/experimental/video-viewer.cjs +5 -5
  71. package/build/cjs/public/experimental/xml-viewer.cjs +5 -5
  72. package/build/cjs/public/experimental.cjs +112 -112
  73. package/build/cjs/public/filter-list.cjs +15 -15
  74. package/build/cjs/public/image-viewer.cjs +3 -3
  75. package/build/cjs/public/markdown-viewer.cjs +3 -3
  76. package/build/cjs/public/object-table.cjs +22 -22
  77. package/build/cjs/public/pdf-viewer.cjs +7 -7
  78. package/build/cjs/public/spreadsheet-viewer.cjs +3 -3
  79. package/build/cjs/public/tiff-viewer.cjs +3 -3
  80. package/build/cjs/public/video-viewer.cjs +3 -3
  81. package/build/cjs/public/xml-viewer.cjs +3 -3
  82. package/build/esm/util/UserAgent.js +1 -1
  83. package/build/esm/util/UserAgent.js.map +1 -1
  84. package/package.json +8 -8
  85. package/build/cjs/chunk-26AQAAVA.cjs +0 -11
  86. package/build/cjs/chunk-37OAMQ2X.cjs.map +0 -1
  87. package/build/cjs/chunk-4S6ET33F.cjs +0 -11
  88. package/build/cjs/chunk-6KS7GKSR.cjs +0 -11
  89. package/build/cjs/chunk-AQZNXIMO.cjs +0 -34
  90. package/build/cjs/chunk-BZVDF2YT.cjs +0 -11
  91. package/build/cjs/chunk-IUYNVDKR.cjs +0 -12
  92. package/build/cjs/chunk-K5WARY3T.cjs +0 -48
  93. package/build/cjs/chunk-UESMRV3Y.cjs +0 -12
  94. package/build/cjs/chunk-W7GFTIH7.cjs +0 -11
  95. package/build/cjs/chunk-XZIBZYBX.cjs +0 -11
package/CHANGELOG.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # @osdk/react-components
2
2
 
3
- ## 0.67.0-main-a0c6e14df406e2519cff5b4f2e9160376b2f3837
3
+ ## 0.67.0
4
4
 
5
5
  ### Minor Changes
6
6
 
@@ -8,13 +8,7 @@
8
8
 
9
9
  ### Patch Changes
10
10
 
11
- - Updated dependencies [396ffce]
12
- - Updated dependencies [a0c6e14]
13
- - Updated dependencies [d0f3019]
14
- - @osdk/client@2.85.0-main-a0c6e14df406e2519cff5b4f2e9160376b2f3837
15
- - @osdk/api@2.85.0-main-a0c6e14df406e2519cff5b4f2e9160376b2f3837
16
- - @osdk/react@2.85.0-main-a0c6e14df406e2519cff5b4f2e9160376b2f3837
17
- - @osdk/aip-core@0.13.0
11
+ - @osdk/aip-core@0.13.0
18
12
 
19
13
  ## 0.66.0
20
14
 
@@ -14,7 +14,7 @@
14
14
  * limitations under the License.
15
15
  */
16
16
 
17
- const PACKAGE_USER_AGENT = `osdk-react-components/${"0.67.0-main-a0c6e14df406e2519cff5b4f2e9160376b2f3837"}`;
17
+ const PACKAGE_USER_AGENT = `osdk-react-components/${"0.67.0"}`;
18
18
  export function componentUserAgent(componentName) {
19
19
  return `${PACKAGE_USER_AGENT}/${componentName}`;
20
20
  }
@@ -1 +1 @@
1
- {"version":3,"file":"UserAgent.js","names":["PACKAGE_USER_AGENT","componentUserAgent","componentName"],"sources":["UserAgent.ts"],"sourcesContent":["/*\n * Copyright 2025 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nconst PACKAGE_USER_AGENT = `osdk-react-components/${process.env.PACKAGE_VERSION}`;\n\nexport function componentUserAgent(componentName: string): string {\n return `${PACKAGE_USER_AGENT}/${componentName}`;\n}\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA,MAAMA,kBAAkB,GAAG,iFAAsD;AAEjF,OAAO,SAASC,kBAAkBA,CAACC,aAAqB,EAAU;EAChE,OAAO,GAAGF,kBAAkB,IAAIE,aAAa,EAAE;AACjD","ignoreList":[]}
1
+ {"version":3,"file":"UserAgent.js","names":["PACKAGE_USER_AGENT","componentUserAgent","componentName"],"sources":["UserAgent.ts"],"sourcesContent":["/*\n * Copyright 2025 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nconst PACKAGE_USER_AGENT = `osdk-react-components/${process.env.PACKAGE_VERSION}`;\n\nexport function componentUserAgent(componentName: string): string {\n return `${PACKAGE_USER_AGENT}/${componentName}`;\n}\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA,MAAMA,kBAAkB,GAAG,mCAAsD;AAEjF,OAAO,SAASC,kBAAkBA,CAACC,aAAqB,EAAU;EAChE,OAAO,GAAGF,kBAAkB,IAAIE,aAAa,EAAE;AACjD","ignoreList":[]}
@@ -0,0 +1,11 @@
1
+ 'use strict';
2
+
3
+ var chunkPA7IYPBX_cjs = require('./chunk-PA7IYPBX.cjs');
4
+ var chunkLZTR5GS5_cjs = require('./chunk-LZTR5GS5.cjs');
5
+
6
+ // src/public/email-viewer.ts
7
+ var EmailViewer2 = chunkLZTR5GS5_cjs.withOsdkMetrics(chunkPA7IYPBX_cjs.EmailViewer, "EmailViewer");
8
+
9
+ exports.EmailViewer = EmailViewer2;
10
+ //# sourceMappingURL=chunk-25KCCJN5.cjs.map
11
+ //# sourceMappingURL=chunk-25KCCJN5.cjs.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/public/email-viewer.ts"],"names":["EmailViewer","withOsdkMetrics"],"mappings":";;;;;;AAqBO,IAAMA,YAAAA,GAAcC,iCAAA,CAAgBD,6BAAA,EAAc,aAAa","file":"chunk-4S6ET33F.cjs","sourcesContent":["/*\n * Copyright 2026 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n// BaseEmailViewer\nexport { BaseEmailViewer } from \"../email-viewer/BaseEmailViewer.js\";\n// EmailViewer (Media wrapper)\nimport { EmailViewer as _EmailViewer } from \"../email-viewer/EmailViewer.js\";\nimport { withOsdkMetrics } from \"../util/withOsdkMetrics.js\";\nexport const EmailViewer = withOsdkMetrics(_EmailViewer, \"EmailViewer\");"]}
1
+ {"version":3,"sources":["../../src/public/email-viewer.ts"],"names":["EmailViewer","withOsdkMetrics"],"mappings":";;;;;;AAqBO,IAAMA,YAAAA,GAAcC,iCAAA,CAAgBD,6BAAA,EAAc,aAAa","file":"chunk-25KCCJN5.cjs","sourcesContent":["/*\n * Copyright 2026 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n// BaseEmailViewer\nexport { BaseEmailViewer } from \"../email-viewer/BaseEmailViewer.js\";\n// EmailViewer (Media wrapper)\nimport { EmailViewer as _EmailViewer } from \"../email-viewer/EmailViewer.js\";\nimport { withOsdkMetrics } from \"../util/withOsdkMetrics.js\";\nexport const EmailViewer = withOsdkMetrics(_EmailViewer, \"EmailViewer\");"]}
@@ -1,13 +1,13 @@
1
1
  'use strict';
2
2
 
3
- var chunkW7GFTIH7_cjs = require('./chunk-W7GFTIH7.cjs');
3
+ var chunkUNB5WSKF_cjs = require('./chunk-UNB5WSKF.cjs');
4
4
  var chunkRVZE7LPI_cjs = require('./chunk-RVZE7LPI.cjs');
5
5
 
6
6
  // src/public/experimental/xml-viewer.ts
7
7
  var BaseXmlViewer2 = chunkRVZE7LPI_cjs.BaseXmlViewer;
8
- var XmlViewer2 = chunkW7GFTIH7_cjs.XmlViewer;
8
+ var XmlViewer2 = chunkUNB5WSKF_cjs.XmlViewer;
9
9
 
10
10
  exports.BaseXmlViewer = BaseXmlViewer2;
11
11
  exports.XmlViewer = XmlViewer2;
12
- //# sourceMappingURL=chunk-VSKFPLBO.cjs.map
13
- //# sourceMappingURL=chunk-VSKFPLBO.cjs.map
12
+ //# sourceMappingURL=chunk-3J2Z75WV.cjs.map
13
+ //# sourceMappingURL=chunk-3J2Z75WV.cjs.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/public/experimental/xml-viewer.ts"],"names":["BaseXmlViewer","XmlViewer"],"mappings":";;;;;;AAmBO,IAAMA,cAAAA,GAAuBA;AAO7B,IAAMC,UAAAA,GAAmBA","file":"chunk-VSKFPLBO.cjs","sourcesContent":["/*\n * Copyright 2026 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport * as Stable from \"../xml-viewer.js\";\n\n/** @deprecated Import from `@osdk/react-components/xml-viewer` instead. */\nexport const BaseXmlViewer = Stable.BaseXmlViewer;\n\n/** @deprecated Import from `@osdk/react-components/xml-viewer` instead. */\n\n/** @deprecated Import from `@osdk/react-components/xml-viewer` instead. */\n\n/** @deprecated Import from `@osdk/react-components/xml-viewer` instead. */\nexport const XmlViewer = Stable.XmlViewer;"]}
1
+ {"version":3,"sources":["../../src/public/experimental/xml-viewer.ts"],"names":["BaseXmlViewer","XmlViewer"],"mappings":";;;;;;AAmBO,IAAMA,cAAAA,GAAuBA;AAO7B,IAAMC,UAAAA,GAAmBA","file":"chunk-3J2Z75WV.cjs","sourcesContent":["/*\n * Copyright 2026 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport * as Stable from \"../xml-viewer.js\";\n\n/** @deprecated Import from `@osdk/react-components/xml-viewer` instead. */\nexport const BaseXmlViewer = Stable.BaseXmlViewer;\n\n/** @deprecated Import from `@osdk/react-components/xml-viewer` instead. */\n\n/** @deprecated Import from `@osdk/react-components/xml-viewer` instead. */\n\n/** @deprecated Import from `@osdk/react-components/xml-viewer` instead. */\nexport const XmlViewer = Stable.XmlViewer;"]}
@@ -9,7 +9,7 @@ var chunkPA7IYPBX_cjs = require('./chunk-PA7IYPBX.cjs');
9
9
  var chunkUCTQICPR_cjs = require('./chunk-UCTQICPR.cjs');
10
10
  var chunkVOROB7KJ_cjs = require('./chunk-VOROB7KJ.cjs');
11
11
  var chunkKFV264XS_cjs = require('./chunk-KFV264XS.cjs');
12
- var chunk37OAMQ2X_cjs = require('./chunk-37OAMQ2X.cjs');
12
+ var chunkLZTR5GS5_cjs = require('./chunk-LZTR5GS5.cjs');
13
13
  var icons = require('@blueprintjs/icons');
14
14
  var classnames = require('classnames');
15
15
  var React2 = require('react');
@@ -307,9 +307,9 @@ function DocumentViewer({
307
307
  }
308
308
 
309
309
  // src/public/document-viewer.ts
310
- var DocumentViewer2 = chunk37OAMQ2X_cjs.withOsdkMetrics(DocumentViewer, "DocumentViewer");
310
+ var DocumentViewer2 = chunkLZTR5GS5_cjs.withOsdkMetrics(DocumentViewer, "DocumentViewer");
311
311
 
312
312
  exports.DocumentViewer = DocumentViewer2;
313
313
  exports.ViewerType = ViewerType;
314
- //# sourceMappingURL=chunk-XTFRQHIY.cjs.map
315
- //# sourceMappingURL=chunk-XTFRQHIY.cjs.map
314
+ //# sourceMappingURL=chunk-563DKG4Y.cjs.map
315
+ //# sourceMappingURL=chunk-563DKG4Y.cjs.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/document-viewer/DocumentViewerApi.ts","../../src/document-viewer/hooks/useTiffToPdf.ts","../../src/document-viewer/DocumentViewer.module.css","../../src/document-viewer/TiffDocumentViewer.tsx","../../src/document-viewer/DocumentViewer.tsx","../../src/public/document-viewer.ts"],"names":["ViewerType","useOsdkClient","useState","useRef","useEffect","UTIF","transformAndWait","React","Spin","BasePdfViewer","TiffViewer","_extends","useMemo","classnames","PdfViewer","ImageViewer","VideoViewer","MarkdownViewer","SpreadsheetViewer","EmailViewer","XmlViewer","DocumentIcon","assertUnreachable","DocumentViewer","withOsdkMetrics"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAgBO,IAAI,UAAA,6BAAoCA,WAAAA,EAAY;AACzD,EAAAA,WAAAA,CAAW,KA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QACjD,KAAA;AAAA,QACA,SAAA,EAAW;AAAA,OACZ,CAAA;AAAA,IACH,KAAK,UAAA,CAAW,WAAA;AACd,MAAA,uBAAoBb,uBAAAA,CAAM,aAAA,CAAc,KAAA,EAAO;AAAA,QAC7C,SAAA,EAAW;AAAA,OACb,kBAAgBA,uBAAAA,CAAM,aAAA,CAAc,KAAA,EAAO;AAAA,QACzC,WAAW,sBAAA,CAAO;AAAA,OACpB,kBAAgBA,uBAAAA,CAAM,aAAA,CAAcc,cAAA,EAAc;AAAA,QAChD,WAAW,sBAAA,CAAO;AAAA,OACnB,CAAA,EAAG,yBAAA,EAA2B,QAAQ,CAAC,CAAA;AAAA,IAC1C;AACE,MAAAC,mCAAA,CAAkB,UAAU,CAAA;AAAA;AAElC;;;ACrIO,IAAMC,eAAAA,GAAiBC,iCAAA,CAAgB,cAAA,EAAiB,gBAAgB","file":"chunk-XTFRQHIY.cjs","sourcesContent":["/*\n * Copyright 2026 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nexport let ViewerType = /*#__PURE__*/function (ViewerType) {\n ViewerType[\"Pdf\"] = \"pdf\";\n ViewerType[\"Tiff\"] = \"tiff\";\n ViewerType[\"Image\"] = \"image\";\n ViewerType[\"Video\"] = \"video\";\n ViewerType[\"Markdown\"] = \"markdown\";\n ViewerType[\"Spreadsheet\"] = \"spreadsheet\";\n ViewerType[\"Email\"] = \"email\";\n ViewerType[\"Xml\"] = \"xml\";\n ViewerType[\"Unsupported\"] = \"unsupported\";\n return ViewerType;\n}({});","/*\n * Copyright 2026 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n/* cspell:words ifds */\n\nimport { transformAndWait } from \"@osdk/api/unstable\";\nimport { useOsdkClient } from \"@osdk/react\";\nimport { useEffect, useRef, useState } from \"react\";\nimport * as UTIF from \"utif\";\nimport { ViewerType } from \"../DocumentViewerApi.js\";\nconst DISABLED_RESULT = {\n viewerType: ViewerType.Tiff,\n pdfData: undefined,\n loading: false,\n error: undefined\n};\n\n/**\n * Detects multi-page TIFFs and converts them to PDF via the MIO transform API.\n * Single-page TIFFs are left for the TiffViewer to handle.\n *\n * @param media - The OSDK Media object (must be a TIFF)\n * @param enabled - Whether to attempt multi-page detection and conversion\n */\nexport function useTiffToPdf(media, enabled) {\n const client = useOsdkClient();\n const [result, setResult] = useState(DISABLED_RESULT);\n const mediaRef = useRef(media);\n mediaRef.current = media;\n useEffect(() => {\n if (!enabled) {\n setResult(DISABLED_RESULT);\n return;\n }\n let cancelled = false;\n setResult({\n viewerType: ViewerType.Tiff,\n pdfData: undefined,\n loading: true,\n error: undefined\n });\n async function detectAndTransform() {\n const currentMedia = mediaRef.current;\n\n // Step 1: Fetch TIFF bytes and count pages\n const response = await currentMedia.fetchContents();\n const buffer = await response.arrayBuffer();\n if (cancelled) return;\n const ifds = UTIF.decode(buffer);\n const pageCount = ifds.length;\n if (pageCount <= 1) {\n // Single-page TIFF — use TiffViewer\n if (!cancelled) {\n setResult({\n viewerType: ViewerType.Tiff,\n pdfData: undefined,\n loading: false,\n error: undefined\n });\n }\n return;\n }\n\n // Step 2: Multi-page TIFF — convert to PDF via MIO transform\n const pdfResponse = await client(transformAndWait).transformAndWait({\n media: currentMedia,\n transformation: {\n $imageToDocument: {\n $operation: {\n $createPdf: {}\n }\n }\n }\n });\n if (cancelled) return;\n const pdfBuffer = await pdfResponse.arrayBuffer();\n if (!cancelled) {\n setResult({\n viewerType: ViewerType.Pdf,\n pdfData: pdfBuffer,\n loading: false,\n error: undefined\n });\n }\n }\n detectAndTransform().catch(err => {\n if (!cancelled) {\n // eslint-disable-next-line no-console\n console.warn(\"TIFF to PDF conversion failed, falling back to TIFF renderer:\", err);\n setResult({\n viewerType: ViewerType.Tiff,\n pdfData: undefined,\n loading: false,\n error: err instanceof Error ? err : new Error(String(err))\n });\n }\n });\n return () => {\n cancelled = true;\n };\n }, [media, enabled, client]);\n return result;\n}",".container {\n display: flex;\n width: 100%;\n height: 100%;\n background-color: var(--osdk-document-viewer-bg);\n border: var(--osdk-document-viewer-border);\n border-radius: var(--osdk-surface-border-radius);\n overflow: hidden;\n}\n\n.unsupportedContainer {\n display: flex;\n align-items: center;\n justify-content: center;\n gap: var(--osdk-surface-spacing);\n width: 100%;\n height: 100%;\n font-family: var(--osdk-typography-family-default);\n font-size: var(--osdk-typography-size-body-medium);\n color: var(--osdk-typography-color-muted);\n}\n\n.unsupportedIcon {\n flex-shrink: 0;\n}\n\n.loadingContainer {\n composes: loadingContainer from \"../shared/LoadingError.module.css\";\n width: 100%;\n}\n\n.spinnerIcon {\n composes: spinnerIcon from \"../shared/LoadingError.module.css\";\n}\n","function _extends() { return _extends = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, _extends.apply(null, arguments); }\n/*\n * Copyright 2026 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { Spin } from \"@blueprintjs/icons\";\nimport React from \"react\";\nimport { TiffViewer } from \"../images/tiff-viewer/TiffViewer.js\";\nimport { BasePdfViewer } from \"../pdf-viewer/BasePdfViewer.js\";\nimport { ViewerType } from \"./DocumentViewerApi.js\";\nimport { useTiffToPdf } from \"./hooks/useTiffToPdf.js\";\nimport styles from \"./DocumentViewer.module.css\";\nexport function TiffDocumentViewer({\n media,\n className,\n enableTiffToPdf,\n tiffViewerProps,\n pdfViewerProps\n}) {\n const {\n viewerType,\n pdfData,\n loading\n } = useTiffToPdf(media, enableTiffToPdf);\n if (loading) {\n return /*#__PURE__*/React.createElement(\"div\", {\n className: className\n }, /*#__PURE__*/React.createElement(\"div\", {\n className: styles.loadingContainer\n }, /*#__PURE__*/React.createElement(Spin, {\n className: styles.spinnerIcon\n }), \"Converting document\\u2026\"));\n }\n if (viewerType === ViewerType.Pdf && pdfData != null) {\n return /*#__PURE__*/React.createElement(BasePdfViewer, _extends({\n src: pdfData,\n className: className\n }, pdfViewerProps));\n }\n return /*#__PURE__*/React.createElement(TiffViewer, _extends({\n media: media,\n className: className\n }, tiffViewerProps));\n}","function _extends() { return _extends = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, _extends.apply(null, arguments); }\n/*\n * Copyright 2026 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n/* cspell:words openxmlformats officedocument wordprocessingml spreadsheetml */\n\nimport { Document as DocumentIcon } from \"@blueprintjs/icons\";\nimport classnames from \"classnames\";\nimport React, { useMemo } from \"react\";\nimport { EmailViewer } from \"../email-viewer/EmailViewer.js\";\nimport { ImageViewer } from \"../images/image-viewer/ImageViewer.js\";\nimport { TiffViewer } from \"../images/tiff-viewer/TiffViewer.js\";\nimport { MarkdownViewer } from \"../markdown-viewer/MarkdownViewer.js\";\nimport { PdfViewer } from \"../pdf-viewer/PdfViewer.js\";\nimport { assertUnreachable } from \"../shared/assertUnreachable.js\";\nimport { SpreadsheetViewer } from \"../spreadsheet-viewer/SpreadsheetViewer.js\";\nimport { VideoViewer } from \"../video-viewer/VideoViewer.js\";\nimport { XmlViewer } from \"../xml-viewer/XmlViewer.js\";\nimport { ViewerType } from \"./DocumentViewerApi.js\";\nimport { TiffDocumentViewer } from \"./TiffDocumentViewer.js\";\nimport styles from \"./DocumentViewer.module.css\";\nconst IMAGE_MIME_TYPES = new Set([\"image/png\", \"image/jpeg\", \"image/gif\", \"image/svg+xml\", \"image/webp\", \"image/bmp\"]);\nconst MARKDOWN_MIME_TYPES = new Set([\"text/markdown\", \"text/x-markdown\"]);\nconst XML_MIME_TYPES = new Set([\"application/xml\", \"text/xml\"]);\nfunction isTiffFile(mimeType, fileName) {\n if (mimeType === \"image/tiff\") {\n return true;\n }\n const lowered = fileName?.toLowerCase();\n return lowered?.endsWith(\".tif\") === true || lowered?.endsWith(\".tiff\") === true;\n}\nfunction getViewerType(mimeType, fileName) {\n if (mimeType === \"application/pdf\") {\n return ViewerType.Pdf;\n }\n if (isTiffFile(mimeType, fileName)) {\n return ViewerType.Tiff;\n }\n if (IMAGE_MIME_TYPES.has(mimeType)) {\n return ViewerType.Image;\n }\n if (mimeType.startsWith(\"video/\")) {\n return ViewerType.Video;\n }\n if (MARKDOWN_MIME_TYPES.has(mimeType)) {\n return ViewerType.Markdown;\n }\n if (mimeType === \"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet\") {\n return ViewerType.Spreadsheet;\n }\n if (mimeType === \"message/rfc822\") {\n return ViewerType.Email;\n }\n if (XML_MIME_TYPES.has(mimeType)) {\n return ViewerType.Xml;\n }\n return ViewerType.Unsupported;\n}\nexport function DocumentViewer({\n media,\n className,\n mimeTypeOverride,\n pdfViewerProps,\n imageViewerProps,\n videoViewerProps,\n tiffViewerProps,\n tiffRendererProps,\n fileName,\n enableTiffToPdf = false\n}) {\n const mimeType = mimeTypeOverride ?? media.getMediaReference().mimeType;\n const viewerType = useMemo(() => getViewerType(mimeType, fileName), [mimeType, fileName]);\n const rootClassName = classnames(styles.container, className);\n\n // `tiffRendererProps` is the deprecated name for `tiffViewerProps`. Coalescing\n // (rather than merging) keeps the alias behaving exactly like its replacement\n // and avoids creating a new object identity on every render.\n const resolvedTiffViewerProps = tiffViewerProps ?? tiffRendererProps;\n switch (viewerType) {\n case ViewerType.Pdf:\n return /*#__PURE__*/React.createElement(PdfViewer, _extends({\n media: media,\n className: rootClassName\n }, pdfViewerProps));\n case ViewerType.Tiff:\n if (enableTiffToPdf) {\n return /*#__PURE__*/React.createElement(TiffDocumentViewer, {\n media: media,\n className: rootClassName,\n enableTiffToPdf: enableTiffToPdf,\n tiffViewerProps: resolvedTiffViewerProps,\n pdfViewerProps: pdfViewerProps\n });\n }\n return /*#__PURE__*/React.createElement(TiffViewer, _extends({\n media: media,\n className: rootClassName\n }, resolvedTiffViewerProps));\n case ViewerType.Image:\n return /*#__PURE__*/React.createElement(ImageViewer, _extends({\n media: media,\n className: rootClassName\n }, imageViewerProps));\n case ViewerType.Video:\n return /*#__PURE__*/React.createElement(VideoViewer, _extends({\n media: media,\n className: rootClassName\n }, videoViewerProps));\n case ViewerType.Markdown:\n return /*#__PURE__*/React.createElement(MarkdownViewer, {\n media: media,\n className: rootClassName\n });\n case ViewerType.Spreadsheet:\n return /*#__PURE__*/React.createElement(SpreadsheetViewer, {\n media: media,\n className: rootClassName\n });\n case ViewerType.Email:\n return /*#__PURE__*/React.createElement(EmailViewer, {\n media: media,\n className: rootClassName\n });\n case ViewerType.Xml:\n return /*#__PURE__*/React.createElement(XmlViewer, {\n media: media,\n className: rootClassName\n });\n case ViewerType.Unsupported:\n return /*#__PURE__*/React.createElement(\"div\", {\n className: rootClassName\n }, /*#__PURE__*/React.createElement(\"div\", {\n className: styles.unsupportedContainer\n }, /*#__PURE__*/React.createElement(DocumentIcon, {\n className: styles.unsupportedIcon\n }), \"Unsupported file type: \", mimeType));\n default:\n assertUnreachable(viewerType);\n }\n}","/*\n * Copyright 2026 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n// DocumentViewer\nimport { DocumentViewer as _DocumentViewer } from \"../document-viewer/DocumentViewer.js\";\nimport { withOsdkMetrics } from \"../util/withOsdkMetrics.js\";\nexport const DocumentViewer = withOsdkMetrics(_DocumentViewer, \"DocumentViewer\");\nexport { ViewerType } from \"../document-viewer/DocumentViewerApi.js\";"]}
1
+ {"version":3,"sources":["../../src/document-viewer/DocumentViewerApi.ts","../../src/document-viewer/hooks/useTiffToPdf.ts","../../src/document-viewer/DocumentViewer.module.css","../../src/document-viewer/TiffDocumentViewer.tsx","../../src/document-viewer/DocumentViewer.tsx","../../src/public/document-viewer.ts"],"names":["ViewerType","useOsdkClient","useState","useRef","useEffect","UTIF","transformAndWait","React","Spin","BasePdfViewer","TiffViewer","_extends","useMemo","classnames","PdfViewer","ImageViewer","VideoViewer","MarkdownViewer","SpreadsheetViewer","EmailViewer","XmlViewer","DocumentIcon","assertUnre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,QACnD,KAAA;AAAA,QACA,SAAA,EAAW;AAAA,OACZ,CAAA;AAAA,IACH,KAAK,UAAA,CAAW,GAAA;AACd,MAAA,uBAAoBZ,uBAAAA,CAAM,aAAA,CAAca,2BAAA,EAAW;AAAA,QACjD,KAAA;AAAA,QACA,SAAA,EAAW;AAAA,OACZ,CAAA;AAAA,IACH,KAAK,UAAA,CAAW,WAAA;AACd,MAAA,uBAAoBb,uBAAAA,CAAM,aAAA,CAAc,KAAA,EAAO;AAAA,QAC7C,SAAA,EAAW;AAAA,OACb,kBAAgBA,uBAAAA,CAAM,aAAA,CAAc,KAAA,EAAO;AAAA,QACzC,WAAW,sBAAA,CAAO;AAAA,OACpB,kBAAgBA,uBAAAA,CAAM,aAAA,CAAcc,cAAA,EAAc;AAAA,QAChD,WAAW,sBAAA,CAAO;AAAA,OACnB,CAAA,EAAG,yBAAA,EAA2B,QAAQ,CAAC,CAAA;AAAA,IAC1C;AACE,MAAAC,mCAAA,CAAkB,UAAU,CAAA;AAAA;AAElC;;;ACrIO,IAAMC,eAAAA,GAAiBC,iCAAA,CAAgB,cAAA,EAAiB,gBAAgB","file":"chunk-563DKG4Y.cjs","sourcesContent":["/*\n * Copyright 2026 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nexport let ViewerType = /*#__PURE__*/function (ViewerType) {\n ViewerType[\"Pdf\"] = \"pdf\";\n ViewerType[\"Tiff\"] = \"tiff\";\n ViewerType[\"Image\"] = \"image\";\n ViewerType[\"Video\"] = \"video\";\n ViewerType[\"Markdown\"] = \"markdown\";\n ViewerType[\"Spreadsheet\"] = \"spreadsheet\";\n ViewerType[\"Email\"] = \"email\";\n ViewerType[\"Xml\"] = \"xml\";\n ViewerType[\"Unsupported\"] = \"unsupported\";\n return ViewerType;\n}({});","/*\n * Copyright 2026 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n/* cspell:words ifds */\n\nimport { transformAndWait } from \"@osdk/api/unstable\";\nimport { useOsdkClient } from \"@osdk/react\";\nimport { useEffect, useRef, useState } from \"react\";\nimport * as UTIF from \"utif\";\nimport { ViewerType } from \"../DocumentViewerApi.js\";\nconst DISABLED_RESULT = {\n viewerType: ViewerType.Tiff,\n pdfData: undefined,\n loading: false,\n error: undefined\n};\n\n/**\n * Detects multi-page TIFFs and converts them to PDF via the MIO transform API.\n * Single-page TIFFs are left for the TiffViewer to handle.\n *\n * @param media - The OSDK Media object (must be a TIFF)\n * @param enabled - Whether to attempt multi-page detection and conversion\n */\nexport function useTiffToPdf(media, enabled) {\n const client = useOsdkClient();\n const [result, setResult] = useState(DISABLED_RESULT);\n const mediaRef = useRef(media);\n mediaRef.current = media;\n useEffect(() => {\n if (!enabled) {\n setResult(DISABLED_RESULT);\n return;\n }\n let cancelled = false;\n setResult({\n viewerType: ViewerType.Tiff,\n pdfData: undefined,\n loading: true,\n error: undefined\n });\n async function detectAndTransform() {\n const currentMedia = mediaRef.current;\n\n // Step 1: Fetch TIFF bytes and count pages\n const response = await currentMedia.fetchContents();\n const buffer = await response.arrayBuffer();\n if (cancelled) return;\n const ifds = UTIF.decode(buffer);\n const pageCount = ifds.length;\n if (pageCount <= 1) {\n // Single-page TIFF — use TiffViewer\n if (!cancelled) {\n setResult({\n viewerType: ViewerType.Tiff,\n pdfData: undefined,\n loading: false,\n error: undefined\n });\n }\n return;\n }\n\n // Step 2: Multi-page TIFF — convert to PDF via MIO transform\n const pdfResponse = await client(transformAndWait).transformAndWait({\n media: currentMedia,\n transformation: {\n $imageToDocument: {\n $operation: {\n $createPdf: {}\n }\n }\n }\n });\n if (cancelled) return;\n const pdfBuffer = await pdfResponse.arrayBuffer();\n if (!cancelled) {\n setResult({\n viewerType: ViewerType.Pdf,\n pdfData: pdfBuffer,\n loading: false,\n error: undefined\n });\n }\n }\n detectAndTransform().catch(err => {\n if (!cancelled) {\n // eslint-disable-next-line no-console\n console.warn(\"TIFF to PDF conversion failed, falling back to TIFF renderer:\", err);\n setResult({\n viewerType: ViewerType.Tiff,\n pdfData: undefined,\n loading: false,\n error: err instanceof Error ? err : new Error(String(err))\n });\n }\n });\n return () => {\n cancelled = true;\n };\n }, [media, enabled, client]);\n return result;\n}",".container {\n display: flex;\n width: 100%;\n height: 100%;\n background-color: var(--osdk-document-viewer-bg);\n border: var(--osdk-document-viewer-border);\n border-radius: var(--osdk-surface-border-radius);\n overflow: hidden;\n}\n\n.unsupportedContainer {\n display: flex;\n align-items: center;\n justify-content: center;\n gap: var(--osdk-surface-spacing);\n width: 100%;\n height: 100%;\n font-family: var(--osdk-typography-family-default);\n font-size: var(--osdk-typography-size-body-medium);\n color: var(--osdk-typography-color-muted);\n}\n\n.unsupportedIcon {\n flex-shrink: 0;\n}\n\n.loadingContainer {\n composes: loadingContainer from \"../shared/LoadingError.module.css\";\n width: 100%;\n}\n\n.spinnerIcon {\n composes: spinnerIcon from \"../shared/LoadingError.module.css\";\n}\n","function _extends() { return _extends = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, _extends.apply(null, arguments); }\n/*\n * Copyright 2026 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { Spin } from \"@blueprintjs/icons\";\nimport React from \"react\";\nimport { TiffViewer } from \"../images/tiff-viewer/TiffViewer.js\";\nimport { BasePdfViewer } from \"../pdf-viewer/BasePdfViewer.js\";\nimport { ViewerType } from \"./DocumentViewerApi.js\";\nimport { useTiffToPdf } from \"./hooks/useTiffToPdf.js\";\nimport styles from \"./DocumentViewer.module.css\";\nexport function TiffDocumentViewer({\n media,\n className,\n enableTiffToPdf,\n tiffViewerProps,\n pdfViewerProps\n}) {\n const {\n viewerType,\n pdfData,\n loading\n } = useTiffToPdf(media, enableTiffToPdf);\n if (loading) {\n return /*#__PURE__*/React.createElement(\"div\", {\n className: className\n }, /*#__PURE__*/React.createElement(\"div\", {\n className: styles.loadingContainer\n }, /*#__PURE__*/React.createElement(Spin, {\n className: styles.spinnerIcon\n }), \"Converting document\\u2026\"));\n }\n if (viewerType === ViewerType.Pdf && pdfData != null) {\n return /*#__PURE__*/React.createElement(BasePdfViewer, _extends({\n src: pdfData,\n className: className\n }, pdfViewerProps));\n }\n return /*#__PURE__*/React.createElement(TiffViewer, _extends({\n media: media,\n className: className\n }, tiffViewerProps));\n}","function _extends() { return _extends = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, _extends.apply(null, arguments); }\n/*\n * Copyright 2026 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n/* cspell:words openxmlformats officedocument wordprocessingml spreadsheetml */\n\nimport { Document as DocumentIcon } from \"@blueprintjs/icons\";\nimport classnames from \"classnames\";\nimport React, { useMemo } from \"react\";\nimport { EmailViewer } from \"../email-viewer/EmailViewer.js\";\nimport { ImageViewer } from \"../images/image-viewer/ImageViewer.js\";\nimport { TiffViewer } from \"../images/tiff-viewer/TiffViewer.js\";\nimport { MarkdownViewer } from \"../markdown-viewer/MarkdownViewer.js\";\nimport { PdfViewer } from \"../pdf-viewer/PdfViewer.js\";\nimport { assertUnreachable } from \"../shared/assertUnreachable.js\";\nimport { SpreadsheetViewer } from \"../spreadsheet-viewer/SpreadsheetViewer.js\";\nimport { VideoViewer } from \"../video-viewer/VideoViewer.js\";\nimport { XmlViewer } from \"../xml-viewer/XmlViewer.js\";\nimport { ViewerType } from \"./DocumentViewerApi.js\";\nimport { TiffDocumentViewer } from \"./TiffDocumentViewer.js\";\nimport styles from \"./DocumentViewer.module.css\";\nconst IMAGE_MIME_TYPES = new Set([\"image/png\", \"image/jpeg\", \"image/gif\", \"image/svg+xml\", \"image/webp\", \"image/bmp\"]);\nconst MARKDOWN_MIME_TYPES = new Set([\"text/markdown\", \"text/x-markdown\"]);\nconst XML_MIME_TYPES = new Set([\"application/xml\", \"text/xml\"]);\nfunction isTiffFile(mimeType, fileName) {\n if (mimeType === \"image/tiff\") {\n return true;\n }\n const lowered = fileName?.toLowerCase();\n return lowered?.endsWith(\".tif\") === true || lowered?.endsWith(\".tiff\") === true;\n}\nfunction getViewerType(mimeType, fileName) {\n if (mimeType === \"application/pdf\") {\n return ViewerType.Pdf;\n }\n if (isTiffFile(mimeType, fileName)) {\n return ViewerType.Tiff;\n }\n if (IMAGE_MIME_TYPES.has(mimeType)) {\n return ViewerType.Image;\n }\n if (mimeType.startsWith(\"video/\")) {\n return ViewerType.Video;\n }\n if (MARKDOWN_MIME_TYPES.has(mimeType)) {\n return ViewerType.Markdown;\n }\n if (mimeType === \"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet\") {\n return ViewerType.Spreadsheet;\n }\n if (mimeType === \"message/rfc822\") {\n return ViewerType.Email;\n }\n if (XML_MIME_TYPES.has(mimeType)) {\n return ViewerType.Xml;\n }\n return ViewerType.Unsupported;\n}\nexport function DocumentViewer({\n media,\n className,\n mimeTypeOverride,\n pdfViewerProps,\n imageViewerProps,\n videoViewerProps,\n tiffViewerProps,\n tiffRendererProps,\n fileName,\n enableTiffToPdf = false\n}) {\n const mimeType = mimeTypeOverride ?? media.getMediaReference().mimeType;\n const viewerType = useMemo(() => getViewerType(mimeType, fileName), [mimeType, fileName]);\n const rootClassName = classnames(styles.container, className);\n\n // `tiffRendererProps` is the deprecated name for `tiffViewerProps`. Coalescing\n // (rather than merging) keeps the alias behaving exactly like its replacement\n // and avoids creating a new object identity on every render.\n const resolvedTiffViewerProps = tiffViewerProps ?? tiffRendererProps;\n switch (viewerType) {\n case ViewerType.Pdf:\n return /*#__PURE__*/React.createElement(PdfViewer, _extends({\n media: media,\n className: rootClassName\n }, pdfViewerProps));\n case ViewerType.Tiff:\n if (enableTiffToPdf) {\n return /*#__PURE__*/React.createElement(TiffDocumentViewer, {\n media: media,\n className: rootClassName,\n enableTiffToPdf: enableTiffToPdf,\n tiffViewerProps: resolvedTiffViewerProps,\n pdfViewerProps: pdfViewerProps\n });\n }\n return /*#__PURE__*/React.createElement(TiffViewer, _extends({\n media: media,\n className: rootClassName\n }, resolvedTiffViewerProps));\n case ViewerType.Image:\n return /*#__PURE__*/React.createElement(ImageViewer, _extends({\n media: media,\n className: rootClassName\n }, imageViewerProps));\n case ViewerType.Video:\n return /*#__PURE__*/React.createElement(VideoViewer, _extends({\n media: media,\n className: rootClassName\n }, videoViewerProps));\n case ViewerType.Markdown:\n return /*#__PURE__*/React.createElement(MarkdownViewer, {\n media: media,\n className: rootClassName\n });\n case ViewerType.Spreadsheet:\n return /*#__PURE__*/React.createElement(SpreadsheetViewer, {\n media: media,\n className: rootClassName\n });\n case ViewerType.Email:\n return /*#__PURE__*/React.createElement(EmailViewer, {\n media: media,\n className: rootClassName\n });\n case ViewerType.Xml:\n return /*#__PURE__*/React.createElement(XmlViewer, {\n media: media,\n className: rootClassName\n });\n case ViewerType.Unsupported:\n return /*#__PURE__*/React.createElement(\"div\", {\n className: rootClassName\n }, /*#__PURE__*/React.createElement(\"div\", {\n className: styles.unsupportedContainer\n }, /*#__PURE__*/React.createElement(DocumentIcon, {\n className: styles.unsupportedIcon\n }), \"Unsupported file type: \", mimeType));\n default:\n assertUnreachable(viewerType);\n }\n}","/*\n * Copyright 2026 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n// DocumentViewer\nimport { DocumentViewer as _DocumentViewer } from \"../document-viewer/DocumentViewer.js\";\nimport { withOsdkMetrics } from \"../util/withOsdkMetrics.js\";\nexport const DocumentViewer = withOsdkMetrics(_DocumentViewer, \"DocumentViewer\");\nexport { ViewerType } from \"../document-viewer/DocumentViewerApi.js\";"]}
@@ -1,13 +1,13 @@
1
1
  'use strict';
2
2
 
3
- var chunkBZVDF2YT_cjs = require('./chunk-BZVDF2YT.cjs');
3
+ var chunkR7OMZVSD_cjs = require('./chunk-R7OMZVSD.cjs');
4
4
  var chunkKHMOMROL_cjs = require('./chunk-KHMOMROL.cjs');
5
5
 
6
6
  // src/public/experimental/video-viewer.ts
7
7
  var BaseVideoViewer2 = chunkKHMOMROL_cjs.BaseVideoViewer;
8
- var VideoViewer2 = chunkBZVDF2YT_cjs.VideoViewer;
8
+ var VideoViewer2 = chunkR7OMZVSD_cjs.VideoViewer;
9
9
 
10
10
  exports.BaseVideoViewer = BaseVideoViewer2;
11
11
  exports.VideoViewer = VideoViewer2;
12
- //# sourceMappingURL=chunk-XTS5SKJR.cjs.map
13
- //# sourceMappingURL=chunk-XTS5SKJR.cjs.map
12
+ //# sourceMappingURL=chunk-5MO4EEKT.cjs.map
13
+ //# sourceMappingURL=chunk-5MO4EEKT.cjs.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/public/experimental/video-viewer.ts"],"names":["BaseVideoViewer","VideoViewer"],"mappings":";;;;;;AAmBO,IAAMA,gBAAAA,GAAyBA;AAO/B,IAAMC,YAAAA,GAAqBA","file":"chunk-XTS5SKJR.cjs","sourcesContent":["/*\n * Copyright 2026 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport * as Stable from \"../video-viewer.js\";\n\n/** @deprecated Import from `@osdk/react-components/video-viewer` instead. */\nexport const BaseVideoViewer = Stable.BaseVideoViewer;\n\n/** @deprecated Import from `@osdk/react-components/video-viewer` instead. */\n\n/** @deprecated Import from `@osdk/react-components/video-viewer` instead. */\n\n/** @deprecated Import from `@osdk/react-components/video-viewer` instead. */\nexport const VideoViewer = Stable.VideoViewer;"]}
1
+ {"version":3,"sources":["../../src/public/experimental/video-viewer.ts"],"names":["BaseVideoViewer","VideoViewer"],"mappings":";;;;;;AAmBO,IAAMA,gBAAAA,GAAyBA;AAO/B,IAAMC,YAAAA,GAAqBA","file":"chunk-5MO4EEKT.cjs","sourcesContent":["/*\n * Copyright 2026 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport * as Stable from \"../video-viewer.js\";\n\n/** @deprecated Import from `@osdk/react-components/video-viewer` instead. */\nexport const BaseVideoViewer = Stable.BaseVideoViewer;\n\n/** @deprecated Import from `@osdk/react-components/video-viewer` instead. */\n\n/** @deprecated Import from `@osdk/react-components/video-viewer` instead. */\n\n/** @deprecated Import from `@osdk/react-components/video-viewer` instead. */\nexport const VideoViewer = Stable.VideoViewer;"]}
@@ -1,13 +1,13 @@
1
1
  'use strict';
2
2
 
3
- var chunkYRB2QDPF_cjs = require('./chunk-YRB2QDPF.cjs');
3
+ var chunkNZGG24BM_cjs = require('./chunk-NZGG24BM.cjs');
4
4
  var chunkVWHXC6MQ_cjs = require('./chunk-VWHXC6MQ.cjs');
5
5
 
6
6
  // src/public/experimental/spreadsheet-viewer.ts
7
7
  var BaseSpreadsheetViewer2 = chunkVWHXC6MQ_cjs.BaseSpreadsheetViewer;
8
- var SpreadsheetViewer2 = chunkYRB2QDPF_cjs.SpreadsheetViewer;
8
+ var SpreadsheetViewer2 = chunkNZGG24BM_cjs.SpreadsheetViewer;
9
9
 
10
10
  exports.BaseSpreadsheetViewer = BaseSpreadsheetViewer2;
11
11
  exports.SpreadsheetViewer = SpreadsheetViewer2;
12
- //# sourceMappingURL=chunk-YCZHVGJZ.cjs.map
13
- //# sourceMappingURL=chunk-YCZHVGJZ.cjs.map
12
+ //# sourceMappingURL=chunk-C7MVNJCL.cjs.map
13
+ //# sourceMappingURL=chunk-C7MVNJCL.cjs.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/public/experimental/spreadsheet-viewer.ts"],"names":["BaseSpreadsheetViewer","SpreadsheetViewer"],"mappings":";;;;;;AAmBO,IAAMA,sBAAAA,GAA+BA;AAWrC,IAAMC,kBAAAA,GAA2BA","file":"chunk-YCZHVGJZ.cjs","sourcesContent":["/*\n * Copyright 2026 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport * as Stable from \"../spreadsheet-viewer.js\";\n\n/** @deprecated Import from `@osdk/react-components/spreadsheet-viewer` instead. */\nexport const BaseSpreadsheetViewer = Stable.BaseSpreadsheetViewer;\n\n/** @deprecated Import from `@osdk/react-components/spreadsheet-viewer` instead. */\n\n/** @deprecated Import from `@osdk/react-components/spreadsheet-viewer` instead. */\n\n/** @deprecated Import from `@osdk/react-components/spreadsheet-viewer` instead. */\n\n/** @deprecated Import from `@osdk/react-components/spreadsheet-viewer` instead. */\n\n/** @deprecated Import from `@osdk/react-components/spreadsheet-viewer` instead. */\nexport const SpreadsheetViewer = Stable.SpreadsheetViewer;"]}
1
+ {"version":3,"sources":["../../src/public/experimental/spreadsheet-viewer.ts"],"names":["BaseSpreadsheetViewer","SpreadsheetViewer"],"mappings":";;;;;;AAmBO,IAAMA,sBAAAA,GAA+BA;AAWrC,IAAMC,kBAAAA,GAA2BA","file":"chunk-C7MVNJCL.cjs","sourcesContent":["/*\n * Copyright 2026 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport * as Stable from \"../spreadsheet-viewer.js\";\n\n/** @deprecated Import from `@osdk/react-components/spreadsheet-viewer` instead. */\nexport const BaseSpreadsheetViewer = Stable.BaseSpreadsheetViewer;\n\n/** @deprecated Import from `@osdk/react-components/spreadsheet-viewer` instead. */\n\n/** @deprecated Import from `@osdk/react-components/spreadsheet-viewer` instead. */\n\n/** @deprecated Import from `@osdk/react-components/spreadsheet-viewer` instead. */\n\n/** @deprecated Import from `@osdk/react-components/spreadsheet-viewer` instead. */\n\n/** @deprecated Import from `@osdk/react-components/spreadsheet-viewer` instead. */\nexport const SpreadsheetViewer = Stable.SpreadsheetViewer;"]}
@@ -0,0 +1,48 @@
1
+ 'use strict';
2
+
3
+ var chunkZK4Z6LBE_cjs = require('./chunk-ZK4Z6LBE.cjs');
4
+
5
+ // src/public/experimental/object-table.ts
6
+ var ObjectTable2 = chunkZK4Z6LBE_cjs.ObjectTable;
7
+ var BaseTable2 = chunkZK4Z6LBE_cjs.BaseTable;
8
+ var ColumnConfigDialog2 = chunkZK4Z6LBE_cjs.ColumnConfigDialog;
9
+ var MultiColumnSortDialog2 = chunkZK4Z6LBE_cjs.MultiColumnSortDialog;
10
+ var LoadingCell2 = chunkZK4Z6LBE_cjs.LoadingCell;
11
+ var LoadingCellContent2 = chunkZK4Z6LBE_cjs.LoadingCellContent;
12
+ var useFunctionColumnsData2 = chunkZK4Z6LBE_cjs.useFunctionColumnsData;
13
+ var useObjectTableData2 = chunkZK4Z6LBE_cjs.useObjectTableData;
14
+ var useColumnDefs2 = chunkZK4Z6LBE_cjs.useColumnDefs;
15
+ var useSelectionColumn2 = chunkZK4Z6LBE_cjs.useSelectionColumn;
16
+ var useColumnPinning2 = chunkZK4Z6LBE_cjs.useColumnPinning;
17
+ var useColumnResize2 = chunkZK4Z6LBE_cjs.useColumnResize;
18
+ var useColumnVisibility2 = chunkZK4Z6LBE_cjs.useColumnVisibility;
19
+ var useFocusedRow2 = chunkZK4Z6LBE_cjs.useFocusedRow;
20
+ var useLoadedObjectsChanged2 = chunkZK4Z6LBE_cjs.useLoadedObjectsChanged;
21
+ var useRowSelection2 = chunkZK4Z6LBE_cjs.useRowSelection;
22
+ var useTableSorting2 = chunkZK4Z6LBE_cjs.useTableSorting;
23
+ var useEditableTable2 = chunkZK4Z6LBE_cjs.useEditableTable;
24
+ var useObjectTableSnapshot2 = chunkZK4Z6LBE_cjs.useObjectTableSnapshot;
25
+ var useCellContextMenu2 = chunkZK4Z6LBE_cjs.useCellContextMenu;
26
+
27
+ exports.BaseTable = BaseTable2;
28
+ exports.ColumnConfigDialog = ColumnConfigDialog2;
29
+ exports.LoadingCell = LoadingCell2;
30
+ exports.LoadingCellContent = LoadingCellContent2;
31
+ exports.MultiColumnSortDialog = MultiColumnSortDialog2;
32
+ exports.ObjectTable = ObjectTable2;
33
+ exports.useCellContextMenu = useCellContextMenu2;
34
+ exports.useColumnDefs = useColumnDefs2;
35
+ exports.useColumnPinning = useColumnPinning2;
36
+ exports.useColumnResize = useColumnResize2;
37
+ exports.useColumnVisibility = useColumnVisibility2;
38
+ exports.useEditableTable = useEditableTable2;
39
+ exports.useFocusedRow = useFocusedRow2;
40
+ exports.useFunctionColumnsData = useFunctionColumnsData2;
41
+ exports.useLoadedObjectsChanged = useLoadedObjectsChanged2;
42
+ exports.useObjectTableData = useObjectTableData2;
43
+ exports.useObjectTableSnapshot = useObjectTableSnapshot2;
44
+ exports.useRowSelection = useRowSelection2;
45
+ exports.useSelectionColumn = useSelectionColumn2;
46
+ exports.useTableSorting = useTableSorting2;
47
+ //# sourceMappingURL=chunk-DFULAPAD.cjs.map
48
+ //# sourceMappingURL=chunk-DFULAPAD.cjs.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/public/experimental/object-table.ts"],"names":["ObjectTable","BaseTable","ColumnConfigDialog","MultiColumnSortDialog","LoadingCell","LoadingCellContent","useFunctionColumnsData","useObjectTableData","useColumnDefs","useSelectionColumn","useColumnPinning","useColumnResize","useColumnVisibility","useFocusedRow","useLoadedObjectsChanged","useRowSelection","useTableSorting","useEditableTable","useObjectTableSnapshot","useCellContextMenu"],"mappings":";;;;;AAmBO,IAAMA,YAAAA,GAAqBA;AAmC3B,IAAMC,UAAAA,GAAmBA;AAGzB,IAAMC,mBAAAA,GAA4BA;AAOlC,IAAMC,sBAAAA,GAA+BA;AAOrC,IAAMC,YAAAA,GAAqBA;AAG3B,IAAMC,mBAAAA,GAA4BA;AAKlC,IAAMC,uBAAAA,GAAgCA;AAKtC,IAAMC,mBAAAA,GAA4BA;AAOlC,IAAMC,cAAAA,GAAuBA;AAK7B,IAAMC,mBAAAA,GAA4BA;AAKlC,IAAMC,iBAAAA,GAA0BA;AAOhC,IAAMC,gBAAAA,GAAyBA;AAO/B,IAAMC,oBAAAA,GAA6BA;AAOnC,IAAMC,cAAAA,GAAuBA;AAO7B,IAAMC,wBAAAA,GAAiCA;AAKvC,IAAMC,gBAAAA,GAAyBA;AAS/B,IAAMC,gBAAAA,GAAyBA;AAO/B,IAAMC,iBAAAA,GAA0BA;AAKhC,IAAMC,uBAAAA,GAAgCA;AAKtC,IAAMC,mBAAAA,GAA4BA","file":"chunk-K5WARY3T.cjs","sourcesContent":["/*\n * Copyright 2026 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport * as Stable from \"../object-table.js\";\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\nexport const ObjectTable = Stable.ObjectTable;\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\nexport const BaseTable = Stable.BaseTable;\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\nexport const ColumnConfigDialog = Stable.ColumnConfigDialog;\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\nexport const MultiColumnSortDialog = Stable.MultiColumnSortDialog;\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\nexport const LoadingCell = Stable.LoadingCell;\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\nexport const LoadingCellContent = Stable.LoadingCellContent;\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\nexport const useFunctionColumnsData = Stable.useFunctionColumnsData;\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\nexport const useObjectTableData = Stable.useObjectTableData;\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\nexport const useColumnDefs = Stable.useColumnDefs;\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\nexport const useSelectionColumn = Stable.useSelectionColumn;\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\nexport const useColumnPinning = Stable.useColumnPinning;\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\nexport const useColumnResize = Stable.useColumnResize;\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\nexport const useColumnVisibility = Stable.useColumnVisibility;\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\nexport const useFocusedRow = Stable.useFocusedRow;\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\nexport const useLoadedObjectsChanged = Stable.useLoadedObjectsChanged;\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\nexport const useRowSelection = Stable.useRowSelection;\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\nexport const useTableSorting = Stable.useTableSorting;\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\nexport const useEditableTable = Stable.useEditableTable;\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\nexport const useObjectTableSnapshot = Stable.useObjectTableSnapshot;\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\nexport const useCellContextMenu = Stable.useCellContextMenu;\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */"]}
1
+ {"version":3,"sources":["../../src/public/experimental/object-table.ts"],"names":["ObjectTable","BaseTable","ColumnConfigDialog","MultiColumnSortDialog","LoadingCell","LoadingCellContent","useFunctionColumnsData","useObjectTableData","useColumnDefs","useSelectionColumn","useColumnPinning","useColumnResize","useColumnVisibility","useFocusedRow","useLoadedObjectsChanged","useRowSelection","useTableSorting","useEditableTable","useObjectTableSnapshot","useCellContextMenu"],"mappings":";;;;;AAmBO,IAAMA,YAAAA,GAAqBA;AAmC3B,IAAMC,UAAAA,GAAmBA;AAGzB,IAAMC,mBAAAA,GAA4BA;AAOlC,IAAMC,sBAAAA,GAA+BA;AAOrC,IAAMC,YAAAA,GAAqBA;AAG3B,IAAMC,mBAAAA,GAA4BA;AAKlC,IAAMC,uBAAAA,GAAgCA;AAKtC,IAAMC,mBAAAA,GAA4BA;AAOlC,IAAMC,cAAAA,GAAuBA;AAK7B,IAAMC,mBAAAA,GAA4BA;AAKlC,IAAMC,iBAAAA,GAA0BA;AAOhC,IAAMC,gBAAAA,GAAyBA;AAO/B,IAAMC,oBAAAA,GAA6BA;AAOnC,IAAMC,cAAAA,GAAuBA;AAO7B,IAAMC,wBAAAA,GAAiCA;AAKvC,IAAMC,gBAAAA,GAAyBA;AAS/B,IAAMC,gBAAAA,GAAyBA;AAO/B,IAAMC,iBAAAA,GAA0BA;AAKhC,IAAMC,uBAAAA,GAAgCA;AAKtC,IAAMC,mBAAAA,GAA4BA","file":"chunk-DFULAPAD.cjs","sourcesContent":["/*\n * Copyright 2026 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport * as Stable from \"../object-table.js\";\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\nexport const ObjectTable = Stable.ObjectTable;\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\nexport const BaseTable = Stable.BaseTable;\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\nexport const ColumnConfigDialog = Stable.ColumnConfigDialog;\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\nexport const MultiColumnSortDialog = Stable.MultiColumnSortDialog;\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\nexport const LoadingCell = Stable.LoadingCell;\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\nexport const LoadingCellContent = Stable.LoadingCellContent;\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\nexport const useFunctionColumnsData = Stable.useFunctionColumnsData;\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\nexport const useObjectTableData = Stable.useObjectTableData;\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\nexport const useColumnDefs = Stable.useColumnDefs;\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\nexport const useSelectionColumn = Stable.useSelectionColumn;\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\nexport const useColumnPinning = Stable.useColumnPinning;\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\nexport const useColumnResize = Stable.useColumnResize;\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\nexport const useColumnVisibility = Stable.useColumnVisibility;\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\nexport const useFocusedRow = Stable.useFocusedRow;\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\nexport const useLoadedObjectsChanged = Stable.useLoadedObjectsChanged;\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\nexport const useRowSelection = Stable.useRowSelection;\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\nexport const useTableSorting = Stable.useTableSorting;\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\nexport const useEditableTable = Stable.useEditableTable;\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\nexport const useObjectTableSnapshot = Stable.useObjectTableSnapshot;\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\nexport const useCellContextMenu = Stable.useCellContextMenu;\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */\n\n/** @deprecated Import from `@osdk/react-components/object-table` instead. */"]}
@@ -0,0 +1,11 @@
1
+ 'use strict';
2
+
3
+ var chunkVOROB7KJ_cjs = require('./chunk-VOROB7KJ.cjs');
4
+ var chunkLZTR5GS5_cjs = require('./chunk-LZTR5GS5.cjs');
5
+
6
+ // src/public/image-viewer.ts
7
+ var ImageViewer2 = chunkLZTR5GS5_cjs.withOsdkMetrics(chunkVOROB7KJ_cjs.ImageViewer, "ImageViewer");
8
+
9
+ exports.ImageViewer = ImageViewer2;
10
+ //# sourceMappingURL=chunk-GIUBOBJW.cjs.map
11
+ //# sourceMappingURL=chunk-GIUBOBJW.cjs.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/public/image-viewer.ts"],"names":["ImageViewer","withOsdkMetrics"],"mappings":";;;;;;AAqBO,IAAMA,YAAAA,GAAcC,iCAAA,CAAgBD,6BAAA,EAAc,aAAa","file":"chunk-6KS7GKSR.cjs","sourcesContent":["/*\n * Copyright 2026 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n// BaseImageViewer\nexport { BaseImageViewer } from \"../images/image-viewer/BaseImageViewer.js\";\n// ImageViewer (Media wrapper)\nimport { ImageViewer as _ImageViewer } from \"../images/image-viewer/ImageViewer.js\";\nimport { withOsdkMetrics } from \"../util/withOsdkMetrics.js\";\nexport const ImageViewer = withOsdkMetrics(_ImageViewer, \"ImageViewer\");"]}
1
+ {"version":3,"sources":["../../src/public/image-viewer.ts"],"names":["ImageViewer","withOsdkMetrics"],"mappings":";;;;;;AAqBO,IAAMA,YAAAA,GAAcC,iCAAA,CAAgBD,6BAAA,EAAc,aAAa","file":"chunk-GIUBOBJW.cjs","sourcesContent":["/*\n * Copyright 2026 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n// BaseImageViewer\nexport { BaseImageViewer } from \"../images/image-viewer/BaseImageViewer.js\";\n// ImageViewer (Media wrapper)\nimport { ImageViewer as _ImageViewer } from \"../images/image-viewer/ImageViewer.js\";\nimport { withOsdkMetrics } from \"../util/withOsdkMetrics.js\";\nexport const ImageViewer = withOsdkMetrics(_ImageViewer, \"ImageViewer\");"]}
@@ -1,7 +1,7 @@
1
1
  'use strict';
2
2
 
3
3
  var chunk4KHF42ZL_cjs = require('./chunk-4KHF42ZL.cjs');
4
- var chunk37OAMQ2X_cjs = require('./chunk-37OAMQ2X.cjs');
4
+ var chunkLZTR5GS5_cjs = require('./chunk-LZTR5GS5.cjs');
5
5
  var icons = require('@blueprintjs/icons');
6
6
  var classnames = require('classnames');
7
7
  require('pdfjs-dist/web/pdf_viewer.css');
@@ -187,12 +187,12 @@ function usePdfViewerInstance(options) {
187
187
  }
188
188
 
189
189
  // src/public/pdf-viewer.ts
190
- var PdfViewer2 = chunk37OAMQ2X_cjs.withOsdkMetrics(chunk4KHF42ZL_cjs.PdfViewer, "PdfViewer");
190
+ var PdfViewer2 = chunkLZTR5GS5_cjs.withOsdkMetrics(chunk4KHF42ZL_cjs.PdfViewer, "PdfViewer");
191
191
 
192
192
  exports.PdfViewer = PdfViewer2;
193
193
  exports.PdfViewerContent = PdfViewerContent;
194
194
  exports.PdfViewerProvider = PdfViewerProvider;
195
195
  exports.usePdfViewerContext = usePdfViewerContext;
196
196
  exports.usePdfViewerInstance = usePdfViewerInstance;
197
- //# sourceMappingURL=chunk-SBCF4J6J.cjs.map
198
- //# sourceMappingURL=chunk-SBCF4J6J.cjs.map
197
+ //# sourceMappingURL=chunk-HWBP3XW3.cjs.map
198
+ //# sourceMappingURL=chunk-HWBP3XW3.cjs.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/pdf-viewer/components/PdfViewerContent.tsx","../../src/pdf-viewer/PdfViewerContext.tsx","../../src/public/pdf-viewer.ts"],"names":["EMPTY_ANNOTATION_ARRAY","usePdfViewerCore","usePdfAnnotationsByPage","usePdfFormFields","useRef","useEffect","classnames","BasePdfViewer_default","React","Spin","ErrorIcon","PdfAnnotationOverlay","useContext","usePdfViewerState","usePdfHighlightMode","useMemo","PdfViewer","withOsdkMetrics"],"mappings":";;;;;;;;;;;;;;AA0BO,SAAS,gBAAA,CAAiB;AAAA,EAC/B,G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AA,IACtB,cAAc,OAAA,CAAQ;AAAA,GACvB,CAAA;AACD,EAAA,MAAM,WAAA,GAAc,QAAQ,WAAA,IAAeH,wCAAA;AAC3C,EAAA,MAAM,iBAAA,GAAoBE,0CAAwB,WAAW,CAAA;AAG7D,EAAA,MAAM,gBAAA,GAAmB,OAAA,CAAQ,eAAA,IAAmB,OAAA,CAAQ,gBAAA,IAAoB,KAAA;AAChF,EAAA,MAAM,cAAA,GAAiB,QAAQ,cAAA,IAAkB,KAAA;AACjD,EAAA,MAAM,cAAA,GAAiB,OAAA,CAAQ,YAAA,IAAgB,IAAA,IAAQ,aAAA;AACvD,EAAA,MAAM;AAAA,IACJ,iBAAA;AAAA,IACA;AAAA,GACF,GAAI,OAAA;AACJ,EAAA,OAAOa,cAAQ,OAAO;AAAA,IACpB,GAAG,MAAA;AAAA,IACH,gBAAA;AAAA,IACA,mBAAA;AAAA,IACA,mBAAA;AAAA,IACA,aAAA;AAAA,IACA,cAAA;AAAA,IACA,WAAA;AAAA,IACA,iBAAA;AAAA,IACA,iBAAA;AAAA,IACA,cAAA;AAAA,IACA,cAAA;AAAA,IACA;AAAA,GACF,CAAA,EAAI,CAAC,MAAA,EAAQ,gBAAA,EAAkB,qBAAqB,mBAAA,EAAqB,aAAA,EAAe,cAAA,EAAgB,WAAA,EAAa,iBAAA,EAAmB,iBAAA,EAAmB,cAAA,EAAgB,cAAA,EAAgB,YAAY,CAAC,CAAA;AAC1M;;;ACjEO,IAAMC,UAAAA,GAAYC,iCAAA,CAAgBD,2BAAA,EAAY,WAAW","file":"chunk-SBCF4J6J.cjs","sourcesContent":["/*\n * Copyright 2025 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { Error as ErrorIcon, Spin } from \"@blueprintjs/icons\";\nimport classnames from \"classnames\";\nimport \"pdfjs-dist/web/pdf_viewer.css\";\nimport React, { useEffect, useRef } from \"react\";\nimport { EMPTY_ANNOTATION_ARRAY } from \"../constants.js\";\nimport { usePdfAnnotationsByPage } from \"../hooks/usePdfAnnotationsByPage.js\";\nimport { usePdfFormFields } from \"../hooks/usePdfFormFields.js\";\nimport { usePdfViewerCore } from \"../hooks/usePdfViewerCore.js\";\nimport { PdfAnnotationOverlay } from \"./PdfAnnotationOverlay.js\";\nimport styles from \"../BasePdfViewer.module.css\";\nexport function PdfViewerContent({\n src,\n annotations = EMPTY_ANNOTATION_ARRAY,\n onAnnotationClick,\n defaultPage,\n initialPage,\n defaultScale,\n initialScale,\n onPageChange: onPageChangeProp,\n onScaleChange: onScaleChangeProp,\n formData,\n onFormChange,\n className\n}) {\n const viewer = usePdfViewerCore({\n src,\n defaultPage,\n initialPage,\n defaultScale,\n initialScale\n });\n const annotationsByPage = usePdfAnnotationsByPage(annotations);\n usePdfFormFields({\n pdfViewerRef: viewer.pdfViewerRef,\n eventBusRef: viewer.eventBusRef,\n document: viewer.document,\n formData,\n onFormChange\n });\n\n // Use refs for callbacks to avoid firing on initial mount\n const onPageChangeRef = useRef(onPageChangeProp);\n onPageChangeRef.current = onPageChangeProp;\n const onScaleChangeRef = useRef(onScaleChangeProp);\n onScaleChangeRef.current = onScaleChangeProp;\n const isInitialMountRef = useRef(true);\n useEffect(function notifyPageChange() {\n if (isInitialMountRef.current) {\n return;\n }\n onPageChangeRef.current?.(viewer.currentPage);\n }, [viewer.currentPage]);\n useEffect(function notifyScaleChange() {\n if (isInitialMountRef.current) {\n return;\n }\n onScaleChangeRef.current?.(viewer.scale);\n }, [viewer.scale]);\n useEffect(function clearInitialMount() {\n isInitialMountRef.current = false;\n }, []);\n const rootClassName = classnames(styles.pdfViewer, className);\n if (viewer.loading) {\n return /*#__PURE__*/React.createElement(\"div\", {\n className: rootClassName\n }, /*#__PURE__*/React.createElement(\"div\", {\n className: styles.loadingContainer\n }, /*#__PURE__*/React.createElement(Spin, {\n className: styles.spinnerIcon\n }), \"Loading\\u2026\"));\n }\n if (viewer.error != null) {\n return /*#__PURE__*/React.createElement(\"div\", {\n className: rootClassName\n }, /*#__PURE__*/React.createElement(\"div\", {\n className: styles.errorContainer\n }, /*#__PURE__*/React.createElement(ErrorIcon, {\n className: styles.errorIcon\n }), \"Failed to load PDF: \", viewer.error.message));\n }\n if (viewer.document == null) {\n return /*#__PURE__*/React.createElement(\"div\", {\n className: rootClassName\n }, /*#__PURE__*/React.createElement(\"div\", {\n className: styles.loadingContainer\n }, \"No document\"));\n }\n return /*#__PURE__*/React.createElement(\"div\", {\n className: rootClassName\n }, /*#__PURE__*/React.createElement(\"div\", {\n className: styles.scrollContainerWrapper\n }, /*#__PURE__*/React.createElement(\"div\", {\n ref: viewer.containerRef,\n className: styles.scrollContainer\n }, /*#__PURE__*/React.createElement(\"div\", {\n ref: viewer.viewerRef,\n className: \"pdfViewer\"\n }), viewer.portalTargets.map(target => {\n const pageAnnotations = annotationsByPage[target.pageNumber] ?? EMPTY_ANNOTATION_ARRAY;\n if (pageAnnotations.length === 0) {\n return null;\n }\n return /*#__PURE__*/React.createElement(PdfAnnotationOverlay, {\n key: target.pageNumber,\n target: target,\n annotations: pageAnnotations,\n onAnnotationClick: onAnnotationClick\n });\n }))));\n}","/*\n * Copyright 2025 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport React, { createContext, useContext, useMemo } from \"react\";\nimport { EMPTY_ANNOTATION_ARRAY } from \"./constants.js\";\nimport { usePdfAnnotationsByPage } from \"./hooks/usePdfAnnotationsByPage.js\";\nimport { usePdfFormFields } from \"./hooks/usePdfFormFields.js\";\nimport { usePdfHighlightMode } from \"./hooks/usePdfHighlightMode.js\";\nimport { usePdfViewerState } from \"./hooks/usePdfViewerState.js\";\n\n/** The shape of the value provided by {@link PdfViewerProvider}. */\n\nconst PdfViewerContext = /*#__PURE__*/createContext(null);\n/** Provides {@link PdfViewerContextValue} to descendant components. */\nexport function PdfViewerProvider({\n value,\n children\n}) {\n return /*#__PURE__*/React.createElement(PdfViewerContext.Provider, {\n value: value\n }, children);\n}\n\n/**\n * Returns the nearest {@link PdfViewerContextValue} from a {@link PdfViewerProvider}.\n * Throws if called outside a provider.\n */\nexport function usePdfViewerContext() {\n const ctx = useContext(PdfViewerContext);\n if (ctx == null) {\n throw new Error(\"usePdfViewerContext must be used within a PdfViewerProvider\");\n }\n return ctx;\n}\n\n/**\n * Consumer-facing setup hook analogous to react-hook-form's `useForm()`.\n * Accepts viewer options and returns a {@link PdfViewerContextValue} suitable\n * for passing to {@link PdfViewerProvider}.\n */\nexport function usePdfViewerInstance(options) {\n const viewer = usePdfViewerState({\n src: options.src,\n defaultPage: options.defaultPage,\n initialPage: options.initialPage,\n defaultScale: options.defaultScale,\n initialScale: options.initialScale,\n defaultAutoSize: options.defaultAutoSize,\n initialAutoSize: options.initialAutoSize,\n defaultSidebarOpen: options.defaultSidebarOpen,\n initialSidebarOpen: options.initialSidebarOpen,\n sidebarMode: options.sidebarMode,\n onDownload: options.onDownload\n });\n const {\n highlightModeActive,\n toggleHighlightMode\n } = usePdfHighlightMode({\n pdfViewerRef: viewer.pdfViewerRef,\n document: viewer.document,\n enabled: options.enableHighlight ?? options.highlightEnabled ?? false,\n onTextHighlight: options.onTextHighlight,\n onHighlightDelete: options.onHighlightDelete\n });\n const {\n hasFormFields,\n submitFormData\n } = usePdfFormFields({\n pdfViewerRef: viewer.pdfViewerRef,\n eventBusRef: viewer.eventBusRef,\n document: viewer.document,\n formData: options.formData,\n onFormSubmit: options.onFormSubmit,\n onFormChange: options.onFormChange\n });\n const annotations = options.annotations ?? EMPTY_ANNOTATION_ARRAY;\n const annotationsByPage = usePdfAnnotationsByPage(annotations);\n\n // `highlightEnabled` is the deprecated spelling of `enableHighlight`.\n const highlightEnabled = options.enableHighlight ?? options.highlightEnabled ?? false;\n const enableDownload = options.enableDownload ?? false;\n const enableFormSave = options.onFormSubmit != null && hasFormFields;\n const {\n onAnnotationClick,\n outlineIcons\n } = options;\n return useMemo(() => ({\n ...viewer,\n highlightEnabled,\n highlightModeActive,\n toggleHighlightMode,\n hasFormFields,\n submitFormData,\n annotations,\n annotationsByPage,\n onAnnotationClick,\n enableDownload,\n enableFormSave,\n outlineIcons\n }), [viewer, highlightEnabled, highlightModeActive, toggleHighlightMode, hasFormFields, submitFormData, annotations, annotationsByPage, onAnnotationClick, enableDownload, enableFormSave, outlineIcons]);\n}","/*\n * Copyright 2025 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n// BasePdfViewer\nexport { BasePdfViewer } from \"../pdf-viewer/BasePdfViewer.js\";\n// PdfViewer building blocks\nexport { PdfViewerAnnotationLayer } from \"../pdf-viewer/components/PdfViewerAnnotationLayer.js\";\nexport { PdfViewerContent } from \"../pdf-viewer/components/PdfViewerContent.js\";\nexport { PdfViewerOutlineSidebar } from \"../pdf-viewer/components/PdfViewerOutlineSidebar.js\";\nexport { PdfViewerSearchBar } from \"../pdf-viewer/components/PdfViewerSearchBar.js\";\nexport { PdfViewerSidebar } from \"../pdf-viewer/components/PdfViewerSidebar.js\";\nexport { PdfViewerToolbar } from \"../pdf-viewer/components/PdfViewerToolbar.js\";\n\n// PdfViewer hooks — primitive\nexport { usePdfAnnotationPortals } from \"../pdf-viewer/hooks/usePdfAnnotationPortals.js\";\nexport { usePdfAnnotationsByPage } from \"../pdf-viewer/hooks/usePdfAnnotationsByPage.js\";\nexport { usePdfDocument } from \"../pdf-viewer/hooks/usePdfDocument.js\";\nexport { usePdfFormFields } from \"../pdf-viewer/hooks/usePdfFormFields.js\";\nexport { usePdfHighlightMode } from \"../pdf-viewer/hooks/usePdfHighlightMode.js\";\nexport { usePdfOutline } from \"../pdf-viewer/hooks/usePdfOutline.js\";\nexport { usePdfViewer } from \"../pdf-viewer/hooks/usePdfViewer.js\";\nexport { usePdfViewerSearch } from \"../pdf-viewer/hooks/usePdfViewerSearch.js\";\nexport { usePdfViewerSync } from \"../pdf-viewer/hooks/usePdfViewerSync.js\";\n\n// PdfViewer context\n\nexport { PdfViewerProvider, usePdfViewerContext, usePdfViewerInstance } from \"../pdf-viewer/PdfViewerContext.js\";\n\n// PdfViewer hooks — composition\nexport { usePdfViewerCore } from \"../pdf-viewer/hooks/usePdfViewerCore.js\";\nexport { usePdfViewerState } from \"../pdf-viewer/hooks/usePdfViewerState.js\";\n\n// PdfViewer (Media wrapper)\nimport { PdfViewer as _PdfViewer } from \"../pdf-viewer/PdfViewer.js\";\nimport { withOsdkMetrics } from \"../util/withOsdkMetrics.js\";\nexport const PdfViewer = withOsdkMetrics(_PdfViewer, \"PdfViewer\");"]}
1
+ {"version":3,"sources":["../../src/pdf-viewer/components/PdfViewerContent.tsx","../../src/pdf-viewer/PdfViewerContext.tsx","../../src/public/pdf-viewer.ts"],"names":["EMPTY_ANNOTATION_ARRAY","usePdfViewerCore","usePdfAnnotationsByPage","usePdfFormFields","useRef","useEffect","classnames","BasePdfViewer_default","React","Spin","Error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ACrB,aAAa,MAAA,CAAO,WAAA;AAAA,IACpB,UAAU,MAAA,CAAO,QAAA;AAAA,IACjB,UAAU,OAAA,CAAQ,QAAA;AAAA,IAClB,cAAc,OAAA,CAAQ,YAAA;AAAA,IACtB,cAAc,OAAA,CAAQ;AAAA,GACvB,CAAA;AACD,EAAA,MAAM,WAAA,GAAc,QAAQ,WAAA,IAAeH,wCAAA;AAC3C,EAAA,MAAM,iBAAA,GAAoBE,0CAAwB,WAAW,CAAA;AAG7D,EAAA,MAAM,gBAAA,GAAmB,OAAA,CAAQ,eAAA,IAAmB,OAAA,CAAQ,gBAAA,IAAoB,KAAA;AAChF,EAAA,MAAM,cAAA,GAAiB,QAAQ,cAAA,IAAkB,KAAA;AACjD,EAAA,MAAM,cAAA,GAAiB,OAAA,CAAQ,YAAA,IAAgB,IAAA,IAAQ,aAAA;AACvD,EAAA,MAAM;AAAA,IACJ,iBAAA;AAAA,IACA;AAAA,GACF,GAAI,OAAA;AACJ,EAAA,OAAOa,cAAQ,OAAO;AAAA,IACpB,GAAG,MAAA;AAAA,IACH,gBAAA;AAAA,IACA,mBAAA;AAAA,IACA,mBAAA;AAAA,IACA,aAAA;AAAA,IACA,cAAA;AAAA,IACA,WAAA;AAAA,IACA,iBAAA;AAAA,IACA,iBAAA;AAAA,IACA,cAAA;AAAA,IACA,cAAA;AAAA,IACA;AAAA,GACF,CAAA,EAAI,CAAC,MAAA,EAAQ,gBAAA,EAAkB,qBAAqB,mBAAA,EAAqB,aAAA,EAAe,cAAA,EAAgB,WAAA,EAAa,iBAAA,EAAmB,iBAAA,EAAmB,cAAA,EAAgB,cAAA,EAAgB,YAAY,CAAC,CAAA;AAC1M;;;ACjEO,IAAMC,UAAAA,GAAYC,iCAAA,CAAgBD,2BAAA,EAAY,WAAW","file":"chunk-HWBP3XW3.cjs","sourcesContent":["/*\n * Copyright 2025 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { Error as ErrorIcon, Spin } from \"@blueprintjs/icons\";\nimport classnames from \"classnames\";\nimport \"pdfjs-dist/web/pdf_viewer.css\";\nimport React, { useEffect, useRef } from \"react\";\nimport { EMPTY_ANNOTATION_ARRAY } from \"../constants.js\";\nimport { usePdfAnnotationsByPage } from \"../hooks/usePdfAnnotationsByPage.js\";\nimport { usePdfFormFields } from \"../hooks/usePdfFormFields.js\";\nimport { usePdfViewerCore } from \"../hooks/usePdfViewerCore.js\";\nimport { PdfAnnotationOverlay } from \"./PdfAnnotationOverlay.js\";\nimport styles from \"../BasePdfViewer.module.css\";\nexport function PdfViewerContent({\n src,\n annotations = EMPTY_ANNOTATION_ARRAY,\n onAnnotationClick,\n defaultPage,\n initialPage,\n defaultScale,\n initialScale,\n onPageChange: onPageChangeProp,\n onScaleChange: onScaleChangeProp,\n formData,\n onFormChange,\n className\n}) {\n const viewer = usePdfViewerCore({\n src,\n defaultPage,\n initialPage,\n defaultScale,\n initialScale\n });\n const annotationsByPage = usePdfAnnotationsByPage(annotations);\n usePdfFormFields({\n pdfViewerRef: viewer.pdfViewerRef,\n eventBusRef: viewer.eventBusRef,\n document: viewer.document,\n formData,\n onFormChange\n });\n\n // Use refs for callbacks to avoid firing on initial mount\n const onPageChangeRef = useRef(onPageChangeProp);\n onPageChangeRef.current = onPageChangeProp;\n const onScaleChangeRef = useRef(onScaleChangeProp);\n onScaleChangeRef.current = onScaleChangeProp;\n const isInitialMountRef = useRef(true);\n useEffect(function notifyPageChange() {\n if (isInitialMountRef.current) {\n return;\n }\n onPageChangeRef.current?.(viewer.currentPage);\n }, [viewer.currentPage]);\n useEffect(function notifyScaleChange() {\n if (isInitialMountRef.current) {\n return;\n }\n onScaleChangeRef.current?.(viewer.scale);\n }, [viewer.scale]);\n useEffect(function clearInitialMount() {\n isInitialMountRef.current = false;\n }, []);\n const rootClassName = classnames(styles.pdfViewer, className);\n if (viewer.loading) {\n return /*#__PURE__*/React.createElement(\"div\", {\n className: rootClassName\n }, /*#__PURE__*/React.createElement(\"div\", {\n className: styles.loadingContainer\n }, /*#__PURE__*/React.createElement(Spin, {\n className: styles.spinnerIcon\n }), \"Loading\\u2026\"));\n }\n if (viewer.error != null) {\n return /*#__PURE__*/React.createElement(\"div\", {\n className: rootClassName\n }, /*#__PURE__*/React.createElement(\"div\", {\n className: styles.errorContainer\n }, /*#__PURE__*/React.createElement(ErrorIcon, {\n className: styles.errorIcon\n }), \"Failed to load PDF: \", viewer.error.message));\n }\n if (viewer.document == null) {\n return /*#__PURE__*/React.createElement(\"div\", {\n className: rootClassName\n }, /*#__PURE__*/React.createElement(\"div\", {\n className: styles.loadingContainer\n }, \"No document\"));\n }\n return /*#__PURE__*/React.createElement(\"div\", {\n className: rootClassName\n }, /*#__PURE__*/React.createElement(\"div\", {\n className: styles.scrollContainerWrapper\n }, /*#__PURE__*/React.createElement(\"div\", {\n ref: viewer.containerRef,\n className: styles.scrollContainer\n }, /*#__PURE__*/React.createElement(\"div\", {\n ref: viewer.viewerRef,\n className: \"pdfViewer\"\n }), viewer.portalTargets.map(target => {\n const pageAnnotations = annotationsByPage[target.pageNumber] ?? EMPTY_ANNOTATION_ARRAY;\n if (pageAnnotations.length === 0) {\n return null;\n }\n return /*#__PURE__*/React.createElement(PdfAnnotationOverlay, {\n key: target.pageNumber,\n target: target,\n annotations: pageAnnotations,\n onAnnotationClick: onAnnotationClick\n });\n }))));\n}","/*\n * Copyright 2025 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport React, { createContext, useContext, useMemo } from \"react\";\nimport { EMPTY_ANNOTATION_ARRAY } from \"./constants.js\";\nimport { usePdfAnnotationsByPage } from \"./hooks/usePdfAnnotationsByPage.js\";\nimport { usePdfFormFields } from \"./hooks/usePdfFormFields.js\";\nimport { usePdfHighlightMode } from \"./hooks/usePdfHighlightMode.js\";\nimport { usePdfViewerState } from \"./hooks/usePdfViewerState.js\";\n\n/** The shape of the value provided by {@link PdfViewerProvider}. */\n\nconst PdfViewerContext = /*#__PURE__*/createContext(null);\n/** Provides {@link PdfViewerContextValue} to descendant components. */\nexport function PdfViewerProvider({\n value,\n children\n}) {\n return /*#__PURE__*/React.createElement(PdfViewerContext.Provider, {\n value: value\n }, children);\n}\n\n/**\n * Returns the nearest {@link PdfViewerContextValue} from a {@link PdfViewerProvider}.\n * Throws if called outside a provider.\n */\nexport function usePdfViewerContext() {\n const ctx = useContext(PdfViewerContext);\n if (ctx == null) {\n throw new Error(\"usePdfViewerContext must be used within a PdfViewerProvider\");\n }\n return ctx;\n}\n\n/**\n * Consumer-facing setup hook analogous to react-hook-form's `useForm()`.\n * Accepts viewer options and returns a {@link PdfViewerContextValue} suitable\n * for passing to {@link PdfViewerProvider}.\n */\nexport function usePdfViewerInstance(options) {\n const viewer = usePdfViewerState({\n src: options.src,\n defaultPage: options.defaultPage,\n initialPage: options.initialPage,\n defaultScale: options.defaultScale,\n initialScale: options.initialScale,\n defaultAutoSize: options.defaultAutoSize,\n initialAutoSize: options.initialAutoSize,\n defaultSidebarOpen: options.defaultSidebarOpen,\n initialSidebarOpen: options.initialSidebarOpen,\n sidebarMode: options.sidebarMode,\n onDownload: options.onDownload\n });\n const {\n highlightModeActive,\n toggleHighlightMode\n } = usePdfHighlightMode({\n pdfViewerRef: viewer.pdfViewerRef,\n document: viewer.document,\n enabled: options.enableHighlight ?? options.highlightEnabled ?? false,\n onTextHighlight: options.onTextHighlight,\n onHighlightDelete: options.onHighlightDelete\n });\n const {\n hasFormFields,\n submitFormData\n } = usePdfFormFields({\n pdfViewerRef: viewer.pdfViewerRef,\n eventBusRef: viewer.eventBusRef,\n document: viewer.document,\n formData: options.formData,\n onFormSubmit: options.onFormSubmit,\n onFormChange: options.onFormChange\n });\n const annotations = options.annotations ?? EMPTY_ANNOTATION_ARRAY;\n const annotationsByPage = usePdfAnnotationsByPage(annotations);\n\n // `highlightEnabled` is the deprecated spelling of `enableHighlight`.\n const highlightEnabled = options.enableHighlight ?? options.highlightEnabled ?? false;\n const enableDownload = options.enableDownload ?? false;\n const enableFormSave = options.onFormSubmit != null && hasFormFields;\n const {\n onAnnotationClick,\n outlineIcons\n } = options;\n return useMemo(() => ({\n ...viewer,\n highlightEnabled,\n highlightModeActive,\n toggleHighlightMode,\n hasFormFields,\n submitFormData,\n annotations,\n annotationsByPage,\n onAnnotationClick,\n enableDownload,\n enableFormSave,\n outlineIcons\n }), [viewer, highlightEnabled, highlightModeActive, toggleHighlightMode, hasFormFields, submitFormData, annotations, annotationsByPage, onAnnotationClick, enableDownload, enableFormSave, outlineIcons]);\n}","/*\n * Copyright 2025 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n// BasePdfViewer\nexport { BasePdfViewer } from \"../pdf-viewer/BasePdfViewer.js\";\n// PdfViewer building blocks\nexport { PdfViewerAnnotationLayer } from \"../pdf-viewer/components/PdfViewerAnnotationLayer.js\";\nexport { PdfViewerContent } from \"../pdf-viewer/components/PdfViewerContent.js\";\nexport { PdfViewerOutlineSidebar } from \"../pdf-viewer/components/PdfViewerOutlineSidebar.js\";\nexport { PdfViewerSearchBar } from \"../pdf-viewer/components/PdfViewerSearchBar.js\";\nexport { PdfViewerSidebar } from \"../pdf-viewer/components/PdfViewerSidebar.js\";\nexport { PdfViewerToolbar } from \"../pdf-viewer/components/PdfViewerToolbar.js\";\n\n// PdfViewer hooks — primitive\nexport { usePdfAnnotationPortals } from \"../pdf-viewer/hooks/usePdfAnnotationPortals.js\";\nexport { usePdfAnnotationsByPage } from \"../pdf-viewer/hooks/usePdfAnnotationsByPage.js\";\nexport { usePdfDocument } from \"../pdf-viewer/hooks/usePdfDocument.js\";\nexport { usePdfFormFields } from \"../pdf-viewer/hooks/usePdfFormFields.js\";\nexport { usePdfHighlightMode } from \"../pdf-viewer/hooks/usePdfHighlightMode.js\";\nexport { usePdfOutline } from \"../pdf-viewer/hooks/usePdfOutline.js\";\nexport { usePdfViewer } from \"../pdf-viewer/hooks/usePdfViewer.js\";\nexport { usePdfViewerSearch } from \"../pdf-viewer/hooks/usePdfViewerSearch.js\";\nexport { usePdfViewerSync } from \"../pdf-viewer/hooks/usePdfViewerSync.js\";\n\n// PdfViewer context\n\nexport { PdfViewerProvider, usePdfViewerContext, usePdfViewerInstance } from \"../pdf-viewer/PdfViewerContext.js\";\n\n// PdfViewer hooks — composition\nexport { usePdfViewerCore } from \"../pdf-viewer/hooks/usePdfViewerCore.js\";\nexport { usePdfViewerState } from \"../pdf-viewer/hooks/usePdfViewerState.js\";\n\n// PdfViewer (Media wrapper)\nimport { PdfViewer as _PdfViewer } from \"../pdf-viewer/PdfViewer.js\";\nimport { withOsdkMetrics } from \"../util/withOsdkMetrics.js\";\nexport const PdfViewer = withOsdkMetrics(_PdfViewer, \"PdfViewer\");"]}
@@ -0,0 +1,12 @@
1
+ 'use strict';
2
+
3
+ var chunk563DKG4Y_cjs = require('./chunk-563DKG4Y.cjs');
4
+
5
+ // src/public/experimental/document-viewer.ts
6
+ var DocumentViewer2 = chunk563DKG4Y_cjs.DocumentViewer;
7
+ var ViewerType2 = chunk563DKG4Y_cjs.ViewerType;
8
+
9
+ exports.DocumentViewer = DocumentViewer2;
10
+ exports.ViewerType = ViewerType2;
11
+ //# sourceMappingURL=chunk-IMPQOR35.cjs.map
12
+ //# sourceMappingURL=chunk-IMPQOR35.cjs.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/public/experimental/document-viewer.ts"],"names":["DocumentViewer","ViewerType"],"mappings":";;;;;AAmBO,IAAMA,eAAAA,GAAwBA;AAK9B,IAAMC,WAAAA,GAAoBA","file":"chunk-UESMRV3Y.cjs","sourcesContent":["/*\n * Copyright 2026 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport * as Stable from \"../document-viewer.js\";\n\n/** @deprecated Import from `@osdk/react-components/document-viewer` instead. */\nexport const DocumentViewer = Stable.DocumentViewer;\n\n/** @deprecated Import from `@osdk/react-components/document-viewer` instead. */\n\n/** @deprecated Import from `@osdk/react-components/document-viewer` instead. */\nexport const ViewerType = Stable.ViewerType;\n\n/** @deprecated Import from `@osdk/react-components/document-viewer` instead. */"]}
1
+ {"version":3,"sources":["../../src/public/experimental/document-viewer.ts"],"names":["DocumentViewer","ViewerType"],"mappings":";;;;;AAmBO,IAAMA,eAAAA,GAAwBA;AAK9B,IAAMC,WAAAA,GAAoBA","file":"chunk-IMPQOR35.cjs","sourcesContent":["/*\n * Copyright 2026 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport * as Stable from \"../document-viewer.js\";\n\n/** @deprecated Import from `@osdk/react-components/document-viewer` instead. */\nexport const DocumentViewer = Stable.DocumentViewer;\n\n/** @deprecated Import from `@osdk/react-components/document-viewer` instead. */\n\n/** @deprecated Import from `@osdk/react-components/document-viewer` instead. */\nexport const ViewerType = Stable.ViewerType;\n\n/** @deprecated Import from `@osdk/react-components/document-viewer` instead. */"]}
@@ -7,7 +7,7 @@ var chunk62TDTOSI_cjs = require('./chunk-62TDTOSI.cjs');
7
7
  var chunk7LXS66DW_cjs = require('./chunk-7LXS66DW.cjs');
8
8
  var chunkQP2LHBCZ_cjs = require('./chunk-QP2LHBCZ.cjs');
9
9
  var chunkUCTQICPR_cjs = require('./chunk-UCTQICPR.cjs');
10
- var chunk37OAMQ2X_cjs = require('./chunk-37OAMQ2X.cjs');
10
+ var chunkLZTR5GS5_cjs = require('./chunk-LZTR5GS5.cjs');
11
11
  var react = require('@osdk/react');
12
12
  var React17 = require('react');
13
13
  var icons = require('@blueprintjs/icons');
@@ -1858,9 +1858,9 @@ var ActionForm = chunk7RKTNJLO_cjs.typedReactMemo(function ActionFormFn({
1858
1858
  ActionForm.displayName = "ActionForm";
1859
1859
 
1860
1860
  // src/public/action-form.ts
1861
- var ActionForm2 = chunk37OAMQ2X_cjs.withOsdkMetrics(ActionForm, "ActionForm");
1861
+ var ActionForm2 = chunkLZTR5GS5_cjs.withOsdkMetrics(ActionForm, "ActionForm");
1862
1862
 
1863
1863
  exports.ActionForm = ActionForm2;
1864
1864
  exports.BaseForm = BaseForm;
1865
- //# sourceMappingURL=chunk-DNIGZSD5.cjs.map
1866
- //# sourceMappingURL=chunk-DNIGZSD5.cjs.map
1865
+ //# sourceMappingURL=chunk-KPRLMFE4.cjs.map
1866
+ //# sourceMappingURL=chunk-KPRLMFE4.cjs.map