mirror of
https://github.com/m1k1o/neko.git
synced 2025-06-13 16:23:52 +02:00
add browsers customization.
This commit is contained in:
parent
a9b8ef94a2
commit
7d323f7a63
4 changed files with 339 additions and 2 deletions
55
webpage/docs/customization/browsers.tsx
Normal file
55
webpage/docs/customization/browsers.tsx
Normal file
|
@ -0,0 +1,55 @@
|
|||
import React from 'react';
|
||||
import browsers from './browsers.json';
|
||||
import Link from '@docusaurus/Link';
|
||||
|
||||
export function ProfileDirectoryPaths({flavors, ...props}: { flavors: string[] }) {
|
||||
if (!flavors) {
|
||||
flavors = [];
|
||||
}
|
||||
return (
|
||||
<table {...props}>
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Browser</th>
|
||||
<th>Profile Directory Path</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
{browsers.filter(({ flavor }) => flavors.length == 0 || flavors.includes(flavor)).map(({ tag, profileDir }) => (
|
||||
<tr key={tag}>
|
||||
<td><Link to={`/docs/v3/installation/docker-images#${tag}`} ><strong>{tag}</strong></Link></td>
|
||||
<td>
|
||||
{profileDir ? <code>{profileDir}</code> : <i>Does not support profiles.</i>}
|
||||
</td>
|
||||
</tr>
|
||||
))}
|
||||
</tbody>
|
||||
</table>
|
||||
);
|
||||
}
|
||||
|
||||
export function PolicyFilePaths({flavors, ...props}: { flavors: string[] }) {
|
||||
if (!flavors) {
|
||||
flavors = [];
|
||||
}
|
||||
return (
|
||||
<table {...props}>
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Browser</th>
|
||||
<th>Policy File Path</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
{browsers.filter(({ flavor }) => flavors.length == 0 || flavors.includes(flavor)).map(({ tag, policiesFile }) => (
|
||||
<tr key={tag}>
|
||||
<td><Link to={`/docs/v3/installation/docker-images#${tag}`} ><strong>{tag}</strong></Link></td>
|
||||
<td>
|
||||
{policiesFile ? <code>{policiesFile}</code> : <i>Does not support policies.</i>}
|
||||
</td>
|
||||
</tr>
|
||||
))}
|
||||
</tbody>
|
||||
</table>
|
||||
);
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue