@llamaindex/pdf-viewer
Advanced tools
Comparing version 1.1.3 to 1.1.4
@@ -29,5 +29,5 @@ "use strict"; | ||
}; | ||
return ((0, jsx_runtime_1.jsxs)("div", { className: "optionBar", children: [(0, jsx_runtime_1.jsxs)("div", { className: "title", children: ["File ID: ", file.id] }), (0, jsx_runtime_1.jsxs)("div", { className: "control", children: [(0, jsx_runtime_1.jsxs)("div", { className: "pageControl", children: [(0, jsx_runtime_1.jsx)("button", { className: "pageUp", onClick: prevPage, disabled: scrolledIndex === 0, children: (0, jsx_runtime_1.jsx)(icon_js_1.CaretUpIcon, {}) }), (0, jsx_runtime_1.jsx)("input", { className: "pageInput", value: inputValue, onChange: handleChange, onKeyDown: handleKeyDown }), (0, jsx_runtime_1.jsx)("button", { className: "pageDown", onClick: nextPage, disabled: scrolledIndex === numPages - 1, children: (0, jsx_runtime_1.jsx)(icon_js_1.CaretDownIcon, {}) })] }), (0, jsx_runtime_1.jsxs)("div", { className: "zoomControl", children: [(0, jsx_runtime_1.jsx)("button", { className: "zoomOut", onClick: handleZoomOut, disabled: !zoomOutEnabled, children: (0, jsx_runtime_1.jsx)(icon_js_1.ZoomOutIcon, {}) }), (0, jsx_runtime_1.jsx)("select", { className: "zoomSelect", value: scaleText, onChange: (e) => handleZoomSelection(e.target.value), children: usePdfViewer_js_1.zoomLevels.map((zoom, index) => ((0, jsx_runtime_1.jsx)("option", { value: zoom, children: zoom }, index))) }), (0, jsx_runtime_1.jsx)("button", { className: "zoomIn", onClick: handleZoomIn, disabled: !zoomInEnabled, children: (0, jsx_runtime_1.jsx)(icon_js_1.ZoomInIcon, {}) })] })] })] })); | ||
return ((0, jsx_runtime_1.jsxs)("div", { className: "optionBar", children: [(0, jsx_runtime_1.jsxs)("div", { className: "title truncate", children: ["File ID: ", file.id] }), (0, jsx_runtime_1.jsxs)("div", { className: "control", children: [(0, jsx_runtime_1.jsxs)("div", { className: "pageControl", children: [(0, jsx_runtime_1.jsx)("button", { className: "pageUp", onClick: prevPage, disabled: scrolledIndex === 0, children: (0, jsx_runtime_1.jsx)(icon_js_1.CaretUpIcon, {}) }), (0, jsx_runtime_1.jsx)("input", { className: "pageInput", value: inputValue, onChange: handleChange, onKeyDown: handleKeyDown }), (0, jsx_runtime_1.jsx)("button", { className: "pageDown", onClick: nextPage, disabled: scrolledIndex === numPages - 1, children: (0, jsx_runtime_1.jsx)(icon_js_1.CaretDownIcon, {}) })] }), (0, jsx_runtime_1.jsxs)("div", { className: "zoomControl", children: [(0, jsx_runtime_1.jsx)("button", { className: "zoomOut", onClick: handleZoomOut, disabled: !zoomOutEnabled, children: (0, jsx_runtime_1.jsx)(icon_js_1.ZoomOutIcon, {}) }), (0, jsx_runtime_1.jsx)("select", { className: "zoomSelect", value: scaleText, onChange: (e) => handleZoomSelection(e.target.value), children: usePdfViewer_js_1.zoomLevels.map((zoom, index) => ((0, jsx_runtime_1.jsx)("option", { value: zoom, children: zoom }, index))) }), (0, jsx_runtime_1.jsx)("button", { className: "zoomIn", onClick: handleZoomIn, disabled: !zoomInEnabled, children: (0, jsx_runtime_1.jsx)(icon_js_1.ZoomInIcon, {}) })] })] })] })); | ||
}; | ||
PDFOptionsBar.displayName = 'PDFOptionsBar'; | ||
exports.default = PDFOptionsBar; |
@@ -27,5 +27,5 @@ import { jsxs as _jsxs, jsx as _jsx } from "react/jsx-runtime"; | ||
}; | ||
return (_jsxs("div", { className: "optionBar", children: [_jsxs("div", { className: "title", children: ["File ID: ", file.id] }), _jsxs("div", { className: "control", children: [_jsxs("div", { className: "pageControl", children: [_jsx("button", { className: "pageUp", onClick: prevPage, disabled: scrolledIndex === 0, children: _jsx(CaretUpIcon, {}) }), _jsx("input", { className: "pageInput", value: inputValue, onChange: handleChange, onKeyDown: handleKeyDown }), _jsx("button", { className: "pageDown", onClick: nextPage, disabled: scrolledIndex === numPages - 1, children: _jsx(CaretDownIcon, {}) })] }), _jsxs("div", { className: "zoomControl", children: [_jsx("button", { className: "zoomOut", onClick: handleZoomOut, disabled: !zoomOutEnabled, children: _jsx(ZoomOutIcon, {}) }), _jsx("select", { className: "zoomSelect", value: scaleText, onChange: (e) => handleZoomSelection(e.target.value), children: zoomLevels.map((zoom, index) => (_jsx("option", { value: zoom, children: zoom }, index))) }), _jsx("button", { className: "zoomIn", onClick: handleZoomIn, disabled: !zoomInEnabled, children: _jsx(ZoomInIcon, {}) })] })] })] })); | ||
return (_jsxs("div", { className: "optionBar", children: [_jsxs("div", { className: "title truncate", children: ["File ID: ", file.id] }), _jsxs("div", { className: "control", children: [_jsxs("div", { className: "pageControl", children: [_jsx("button", { className: "pageUp", onClick: prevPage, disabled: scrolledIndex === 0, children: _jsx(CaretUpIcon, {}) }), _jsx("input", { className: "pageInput", value: inputValue, onChange: handleChange, onKeyDown: handleKeyDown }), _jsx("button", { className: "pageDown", onClick: nextPage, disabled: scrolledIndex === numPages - 1, children: _jsx(CaretDownIcon, {}) })] }), _jsxs("div", { className: "zoomControl", children: [_jsx("button", { className: "zoomOut", onClick: handleZoomOut, disabled: !zoomOutEnabled, children: _jsx(ZoomOutIcon, {}) }), _jsx("select", { className: "zoomSelect", value: scaleText, onChange: (e) => handleZoomSelection(e.target.value), children: zoomLevels.map((zoom, index) => (_jsx("option", { value: zoom, children: zoom }, index))) }), _jsx("button", { className: "zoomIn", onClick: handleZoomIn, disabled: !zoomInEnabled, children: _jsx(ZoomInIcon, {}) })] })] })] })); | ||
}; | ||
PDFOptionsBar.displayName = 'PDFOptionsBar'; | ||
export default PDFOptionsBar; |
{ | ||
"name": "@llamaindex/pdf-viewer", | ||
"version": "1.1.3", | ||
"version": "1.1.4", | ||
"description": "React PDF viewer for LLM applications", | ||
@@ -34,3 +34,7 @@ "type": "module", | ||
"tsc": "tsc", | ||
"watch": "yarn build-js-esm --watch & yarn build-js-cjs --watch & nodemon --watch src --ext css --exec \"yarn copy-styles\"" | ||
"watch": "yarn build-js-esm --watch & yarn build-js-cjs --watch & nodemon --watch src --ext css --exec \"yarn copy-styles\"", | ||
"new-snapshot": "yarn build && changeset version --snapshot", | ||
"new-version": "yarn build && changeset version", | ||
"release": "yarn build && changeset publish", | ||
"release-snapshot": "yarn build && changeset publish --tag snapshot" | ||
}, | ||
@@ -48,2 +52,3 @@ "dependencies": { | ||
"devDependencies": { | ||
"@changesets/cli": "^2.27.1", | ||
"@types/lodash": "^4.14.195", | ||
@@ -50,0 +55,0 @@ "@types/lodash.debounce": "^4.0.7", |
@@ -90,2 +90,21 @@ # PDF viewer for RAG applications | ||
## Contributing | ||
When making changes to this project, please follow these steps: | ||
1. Make your code changes | ||
2. Create a changeset to document your changes: | ||
```bash | ||
yarn changeset | ||
``` | ||
3. Commit your changes and the changeset | ||
4. When ready to release a new version: | ||
```bash | ||
yarn new-version | ||
``` | ||
5. To publish the new version: | ||
```bash | ||
yarn release | ||
``` | ||
## 🙏 Thanks | ||
@@ -92,0 +111,0 @@ |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
110838
119
19
2592