diff --git a/src/FilterLists.Services/FilterList/Models/SyntaxSupportedSoftwareDto.cs b/src/FilterLists.Services/FilterList/Models/SyntaxSupportedSoftwareDto.cs index 400e6288d..0c6cc4438 100644 --- a/src/FilterLists.Services/FilterList/Models/SyntaxSupportedSoftwareDto.cs +++ b/src/FilterLists.Services/FilterList/Models/SyntaxSupportedSoftwareDto.cs @@ -5,6 +5,7 @@ namespace FilterLists.Services.FilterList.Models [UsedImplicitly] public class SyntaxSupportedSoftwareDto { + public uint Id { get; set; } public string HomeUrl { get; set; } public string Name { get; set; } } diff --git a/src/FilterLists.Web/ClientApp/modules/home/components/detailsExpander/IFilterListDetailsDto.ts b/src/FilterLists.Web/ClientApp/modules/home/components/detailsExpander/IFilterListDetailsDto.ts index e3afa5d43..1f41ce79b 100644 --- a/src/FilterLists.Web/ClientApp/modules/home/components/detailsExpander/IFilterListDetailsDto.ts +++ b/src/FilterLists.Web/ClientApp/modules/home/components/detailsExpander/IFilterListDetailsDto.ts @@ -57,5 +57,6 @@ export interface IMaintainerAdditionalListDto { export interface ISyntaxSupportedSoftwareDto { homeUrl: string; + id: number; name: string; } \ No newline at end of file diff --git a/src/FilterLists.Web/ClientApp/modules/home/components/detailsExpander/infoCard/InfoCard.tsx b/src/FilterLists.Web/ClientApp/modules/home/components/detailsExpander/infoCard/InfoCard.tsx index 045b5a662..41259e77d 100644 --- a/src/FilterLists.Web/ClientApp/modules/home/components/detailsExpander/infoCard/InfoCard.tsx +++ b/src/FilterLists.Web/ClientApp/modules/home/components/detailsExpander/infoCard/InfoCard.tsx @@ -6,6 +6,7 @@ import { Languages } from "./Languages"; import { License } from "./License"; import { PublishedDate } from "./PublishedDate"; import { RuleCount } from "./RuleCount"; +import { SoftwareIcons } from "../../SoftwareIcons"; import { Syntax } from "./Syntax"; import { Tags } from "./Tags"; import { UpdatedDate } from "./UpdatedDate"; @@ -26,6 +27,7 @@ interface IProps { export const InfoCard = (props: IProps) => { return
+
    diff --git a/src/FilterLists.Web/ClientApp/modules/home/components/listsTable/ListsTable.tsx b/src/FilterLists.Web/ClientApp/modules/home/components/listsTable/ListsTable.tsx index 7546bd6a0..a5abf538e 100644 --- a/src/FilterLists.Web/ClientApp/modules/home/components/listsTable/ListsTable.tsx +++ b/src/FilterLists.Web/ClientApp/modules/home/components/listsTable/ListsTable.tsx @@ -6,7 +6,7 @@ import ReactTable from "react-table" import "react-table/react-table.css" import "./listsTable.css"; import * as moment from "moment"; -import { SoftwareIcon } from "./SoftwareIcon"; +import { SoftwareIcons } from "../SoftwareIcons"; import { getContrast } from "../../../../utils/GetContrast"; import { DetailsExpander } from "../../components"; @@ -54,7 +54,7 @@ export const ListsTable = (props: IProps) => { {props.software.map((s: any, i) => )} , sortable: false, - Cell: (c: any) => c.value.map((s: number, i: any) => ), + Cell: (c: any) => , width: 155, headerClassName: "d-none d-md-block", className: "d-none d-md-block", diff --git a/src/FilterLists.Web/ClientApp/modules/home/components/listsTable/SoftwareIcon.tsx b/src/FilterLists.Web/ClientApp/modules/home/components/softwareIcons/SoftwareIcon.tsx similarity index 100% rename from src/FilterLists.Web/ClientApp/modules/home/components/listsTable/SoftwareIcon.tsx rename to src/FilterLists.Web/ClientApp/modules/home/components/softwareIcons/SoftwareIcon.tsx diff --git a/src/FilterLists.Web/ClientApp/modules/home/components/softwareIcons/SoftwareIcons.tsx b/src/FilterLists.Web/ClientApp/modules/home/components/softwareIcons/SoftwareIcons.tsx new file mode 100644 index 000000000..79580c041 --- /dev/null +++ b/src/FilterLists.Web/ClientApp/modules/home/components/softwareIcons/SoftwareIcons.tsx @@ -0,0 +1,17 @@ +import * as React from "react"; +import { ISyntaxSupportedSoftwareDto } from "../detailsExpander/IFilterListDetailsDto"; +import { SoftwareIcon } from "./SoftwareIcon" + +interface IProps { + software: ISyntaxSupportedSoftwareDto[]; + mdNone: boolean; +} + +export const SoftwareIcons = (props: IProps) => { + return props.software + ?
    + {props.software.map( + (s: ISyntaxSupportedSoftwareDto, i: any) => )} +
    + : null; +}; \ No newline at end of file diff --git a/src/FilterLists.Web/ClientApp/modules/home/components/softwareIcons/index.ts b/src/FilterLists.Web/ClientApp/modules/home/components/softwareIcons/index.ts new file mode 100644 index 000000000..9c8d9db62 --- /dev/null +++ b/src/FilterLists.Web/ClientApp/modules/home/components/softwareIcons/index.ts @@ -0,0 +1,5 @@ +import { SoftwareIcons } from "./SoftwareIcons"; + +export { + SoftwareIcons + }; \ No newline at end of file