chore(web): add ignore pattern to eslint for the unused-vars rule (#965)

* allow eslint ununsed vars and params if starts with _

* comment rests of unused code on Irc.tsx

* fix some eslint warn about unused code
This commit is contained in:
Fabricio Silva 2023-07-02 13:19:03 +01:00 committed by GitHub
parent 32ffc875b0
commit a5e05284d0
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 57 additions and 44 deletions

View file

@ -31,26 +31,26 @@ const RowItem = ({ label, value, title, emptyText }: RowItemProps) => {
);
};
interface RowItemNumberProps {
label: string;
value?: string | number;
title?: string;
unit?: string;
}
// interface RowItemNumberProps {
// label: string;
// value?: string | number;
// title?: string;
// unit?: string;
// }
const RowItemNumber = ({ label, value, title, unit }: RowItemNumberProps) => {
return (
<div className="py-4 sm:py-5 sm:grid sm:grid-cols-4 sm:gap-4 sm:px-6">
<dt className="font-medium text-gray-500 dark:text-white" title={title}>{label}:</dt>
<dd className="mt-1 text-gray-900 dark:text-white sm:mt-0 sm:col-span-2 break-all">
<span className="px-1 py-0.5 bg-gray-700 rounded shadow">{value}</span>
{unit &&
<span className="ml-1 text-sm text-gray-800 dark:text-gray-400">{unit}</span>
}
</dd>
</div>
);
};
// const RowItemNumber = ({ label, value, title, unit }: RowItemNumberProps) => {
// return (
// <div className="py-4 sm:py-5 sm:grid sm:grid-cols-4 sm:gap-4 sm:px-6">
// <dt className="font-medium text-gray-500 dark:text-white" title={title}>{label}:</dt>
// <dd className="mt-1 text-gray-900 dark:text-white sm:mt-0 sm:col-span-2 break-all">
// <span className="px-1 py-0.5 bg-gray-700 rounded shadow">{value}</span>
// {unit &&
// <span className="ml-1 text-sm text-gray-800 dark:text-gray-400">{unit}</span>
// }
// </dd>
// </div>
// );
// };
const RowItemVersion = ({ label, value, title, newUpdate }: RowItemProps) => {
if (!value) {