Skip to content

Commit

Permalink
Fix ui pkg update and unused code (#6608)
Browse files Browse the repository at this point in the history
  • Loading branch information
nopcoder authored Sep 18, 2023
1 parent c83ef83 commit d74138e
Show file tree
Hide file tree
Showing 4 changed files with 90 additions and 147 deletions.
197 changes: 86 additions & 111 deletions webui/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 1 addition & 4 deletions webui/src/lib/components/repository/ObjectsDiff.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -65,12 +65,9 @@ function readableObject(path) {

const NoContentDiff = ({left, right, diffType}) => {
const supportedFileExtensions = supportedReadableFormats.map((fileType) => `.${fileType}`);
// use the list formatter in place of manual formatting
// ref: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Intl/ListFormat
const formatter = new Intl.ListFormat('en', { style: "long", type: "conjunction" });
return <div>
<span><StatDiff left={left} right={right} diffType={diffType}/></span>
<span><Alert variant="light"><InfoIcon/> {`lakeFS supports content diff for ${formatter.format(supportedFileExtensions)} file formats only`}</Alert></span>
<span><Alert variant="light"><InfoIcon/> {`lakeFS supports content diff for ${supportedFileExtensions.join(',')} file formats only`}</Alert></span>
</div>;
}

Expand Down
Loading

0 comments on commit d74138e

Please sign in to comment.