mirror of
https://github.com/collinbarrett/FilterLists.git
synced 2026-03-11 09:04:27 +00:00
parent
349bd97b6d
commit
6def1034bb
10 changed files with 11 additions and 10 deletions
|
|
@ -2,7 +2,7 @@ import * as React from "react";
|
|||
import { Column, RowRenderProps } from "react-table";
|
||||
|
||||
export const DetailsButton = {
|
||||
Header: "Details",
|
||||
Header: <span title="Learn more about the FilterList.">Details</span>,
|
||||
accessor: "id",
|
||||
sortable: false,
|
||||
expander: true,
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@ import { IColumnVisibility, ILanguage } from "../../../interfaces";
|
|||
export const Languages = (columnVisibility: IColumnVisibility[], languages: ILanguage[]) => {
|
||||
const languagesSorted = languages.sort((a, b) => a.name.localeCompare(b.name));
|
||||
return ({
|
||||
Header: "Languages",
|
||||
Header: <span title="Written forms of communication used by sites targeted by the FilterList.">Languages</span>,
|
||||
accessor: "languageIds",
|
||||
filterable: true,
|
||||
filterMethod: (f: Filter, r: any[]) => filterMethod(f, r),
|
||||
|
|
|
|||
|
|
@ -4,7 +4,7 @@ import { IColumnVisibility, ILicense } from "../../../interfaces";
|
|||
|
||||
export const License = (columnVisibility: IColumnVisibility[], licenses: ILicense[]) =>
|
||||
({
|
||||
Header: "License",
|
||||
Header: <span title="A legal document governing the use or redistribution of a FilterList.">License</span>,
|
||||
accessor: "licenseId",
|
||||
filterable: true,
|
||||
filterMethod: (f: Filter, r: any[]) => filterMethod(f, r, licenses),
|
||||
|
|
|
|||
|
|
@ -4,7 +4,7 @@ import { IColumnVisibility, IMaintainer } from "../../../interfaces";
|
|||
|
||||
export const Maintainers = (columnVisibility: IColumnVisibility[], maintainers: IMaintainer[]) =>
|
||||
({
|
||||
Header: "Maintainers",
|
||||
Header: <span title="Individuals, groups, or organizations who maintain the FilterList.">Maintainers</span>,
|
||||
accessor: "maintainerIds",
|
||||
filterable: true,
|
||||
filterMethod: (f: Filter, r: any[]) => filterMethod(f, r, maintainers),
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@ import * as React from "react";
|
|||
import { Column, Filter } from "react-table";
|
||||
|
||||
export const Name = {
|
||||
Header: "Name",
|
||||
Header: <span title="The name/title of the FilterList in title case.">Name</span>,
|
||||
accessor: "name",
|
||||
filterable: true,
|
||||
filterMethod: (f: Filter, r: any[]) => filterMethod(f, r),
|
||||
|
|
|
|||
|
|
@ -4,7 +4,7 @@ import { IColumnVisibility } from "../../../interfaces";
|
|||
|
||||
export const RuleCount = (columnVisibility: IColumnVisibility[]) =>
|
||||
({
|
||||
Header: "Rules",
|
||||
Header: <span title="The number of rules in the FilterList.">Rules</span>,
|
||||
accessor: "ruleCount",
|
||||
sortMethod: (a: string, b: string) => sortMethod(a, b),
|
||||
Cell: (c: any) => Cell(c.value),
|
||||
|
|
|
|||
|
|
@ -6,7 +6,8 @@ import { SoftwareIcon } from "../../softwareIcon";
|
|||
export const Software = (columnVisibility: IColumnVisibility[], software: ISoftware[]) => {
|
||||
const softwareSorted = software.sort((a, b) => a.name.localeCompare(b.name));
|
||||
return ({
|
||||
Header: "Software",
|
||||
Header:
|
||||
<span title="Applications, browser extensions, or other utilities that consume the FilterList.">Software</span>,
|
||||
accessor: "syntaxId",
|
||||
filterable: true,
|
||||
filterMethod: (f: Filter, r: any[]) => filterMethod(f, r, softwareSorted),
|
||||
|
|
|
|||
|
|
@ -4,7 +4,7 @@ import { IColumnVisibility, ISyntax } from "../../../interfaces";
|
|||
|
||||
//TODO: https://github.com/collinbarrett/FilterLists/issues/488
|
||||
export const Syntax = (columnVisibility: IColumnVisibility[], syntaxes: ISyntax[]) => ({
|
||||
Header: "Syntax",
|
||||
Header: <span title="A named set of rules that govern the format of the FilterList.">Syntax</span>,
|
||||
accessor: "syntaxId",
|
||||
filterable: true,
|
||||
filterMethod: (f: Filter, r: any[]) => filterMethod(f, r, syntaxes),
|
||||
|
|
|
|||
|
|
@ -6,7 +6,7 @@ import { IColumnVisibility, ITag } from "../../../interfaces";
|
|||
export const Tags = (columnVisibility: IColumnVisibility[], tags: ITag[]) => {
|
||||
const tagsSorted = tags.sort((a: ITag, b: ITag) => a.name.localeCompare(b.name));
|
||||
return ({
|
||||
Header: "Tags",
|
||||
Header: <span title="Generic taxonomies applied to the FilterList to provide information about its contents and/or purpose.">Tags</span>,
|
||||
accessor: "tagIds",
|
||||
filterable: true,
|
||||
filterMethod: (f: Filter, r: any[]) => filterMethod(f, r),
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@ import { IColumnVisibility } from "../../../interfaces";
|
|||
|
||||
export const UpdatedDate = (columnVisibility: IColumnVisibility[]) =>
|
||||
({
|
||||
Header: "Updated",
|
||||
Header: <span title="The estimated date that the FilterList was last updated by the maintainer.">Updated</span>,
|
||||
accessor: "updatedDate",
|
||||
sortMethod: (a: string, b: string) => sortMethod(a, b),
|
||||
Cell: (c: any) => Cell(c.value),
|
||||
|
|
|
|||
Loading…
Reference in a new issue