Working empty version
This commit is contained in:
@@ -52,7 +52,7 @@ function App() {
|
|||||||
);
|
);
|
||||||
|
|
||||||
const overrides = createTheme({
|
const overrides = createTheme({
|
||||||
white: theme?.colorbackground,
|
white: theme?.backgroundColor,
|
||||||
fontFamily: '-apple-system,Jost,BlinkMacSystemFont,Helvetica Neue,Roboto,sans-serif',
|
fontFamily: '-apple-system,Jost,BlinkMacSystemFont,Helvetica Neue,Roboto,sans-serif',
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|||||||
@@ -22,6 +22,7 @@ export function DataTableComponent({
|
|||||||
isFetching,
|
isFetching,
|
||||||
isLoading,
|
isLoading,
|
||||||
endpoint,
|
endpoint,
|
||||||
|
grouping,
|
||||||
}: {
|
}: {
|
||||||
tableName: string;
|
tableName: string;
|
||||||
columns: any;
|
columns: any;
|
||||||
@@ -29,6 +30,7 @@ export function DataTableComponent({
|
|||||||
isFetching: boolean;
|
isFetching: boolean;
|
||||||
isLoading: boolean;
|
isLoading: boolean;
|
||||||
endpoint: string;
|
endpoint: string;
|
||||||
|
grouping?: string;
|
||||||
}) {
|
}) {
|
||||||
const [theme, setTheme] = useAtom(appTheme);
|
const [theme, setTheme] = useAtom(appTheme);
|
||||||
const { mutateAsync: createRow } = useMutationAPI();
|
const { mutateAsync: createRow } = useMutationAPI();
|
||||||
@@ -98,7 +100,7 @@ export function DataTableComponent({
|
|||||||
),
|
),
|
||||||
mantineCreateRowModalProps: {
|
mantineCreateRowModalProps: {
|
||||||
style: {
|
style: {
|
||||||
color: theme.colortextpri,
|
color: theme.primary,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
renderTopToolbarCustomActions: ({ table }) => {
|
renderTopToolbarCustomActions: ({ table }) => {
|
||||||
|
|||||||
@@ -15,10 +15,6 @@ export default function ApplicationColumns() {
|
|||||||
id: 'id',
|
id: 'id',
|
||||||
header: 'ID',
|
header: 'ID',
|
||||||
size: 50,
|
size: 50,
|
||||||
mantineCopyButtonProps: ({ cell, row }) => ({
|
|
||||||
className: 'id',
|
|
||||||
id: `${cell.getValue()}-id`,
|
|
||||||
}),
|
|
||||||
Cell: ({ renderedCellValue, row }) => renderedCellValue,
|
Cell: ({ renderedCellValue, row }) => renderedCellValue,
|
||||||
Header: ({ column }) => column.columnDef.header,
|
Header: ({ column }) => column.columnDef.header,
|
||||||
},
|
},
|
||||||
@@ -31,10 +27,6 @@ export default function ApplicationColumns() {
|
|||||||
},
|
},
|
||||||
id: 'name',
|
id: 'name',
|
||||||
header: 'Name',
|
header: 'Name',
|
||||||
mantineCopyButtonProps: ({ cell, row }) => ({
|
|
||||||
className: 'name',
|
|
||||||
id: `${cell.getValue()}-name`,
|
|
||||||
}),
|
|
||||||
Cell: ({ renderedCellValue, row }) => renderedCellValue,
|
Cell: ({ renderedCellValue, row }) => renderedCellValue,
|
||||||
Header: ({ column }) => column.columnDef.header,
|
Header: ({ column }) => column.columnDef.header,
|
||||||
},
|
},
|
||||||
@@ -47,10 +39,6 @@ export default function ApplicationColumns() {
|
|||||||
},
|
},
|
||||||
id: 'url',
|
id: 'url',
|
||||||
header: 'Url',
|
header: 'Url',
|
||||||
mantineCopyButtonProps: ({ cell, row }) => ({
|
|
||||||
className: 'url',
|
|
||||||
id: `${cell.getValue()}-url`,
|
|
||||||
}),
|
|
||||||
Cell: ({ renderedCellValue, row }) => renderedCellValue,
|
Cell: ({ renderedCellValue, row }) => renderedCellValue,
|
||||||
Header: ({ column }) => column.columnDef.header,
|
Header: ({ column }) => column.columnDef.header,
|
||||||
},
|
},
|
||||||
@@ -63,42 +51,30 @@ export default function ApplicationColumns() {
|
|||||||
},
|
},
|
||||||
id: 'icon',
|
id: 'icon',
|
||||||
header: 'Icon',
|
header: 'Icon',
|
||||||
mantineCopyButtonProps: ({ cell, row }) => ({
|
|
||||||
className: 'icon',
|
|
||||||
id: `${cell.getValue()}-icon`,
|
|
||||||
}),
|
|
||||||
Cell: ({ renderedCellValue, row }) => renderedCellValue,
|
Cell: ({ renderedCellValue, row }) => renderedCellValue,
|
||||||
Header: ({ column }) => column.columnDef.header,
|
Header: ({ column }) => column.columnDef.header,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
accessorFn: (row) => {
|
accessorFn: (row) => {
|
||||||
if (row.urlbase) {
|
if (row.baseUrl) {
|
||||||
return `${row.urlbase}`;
|
return `${row.baseUrl}`;
|
||||||
}
|
}
|
||||||
return '';
|
return '';
|
||||||
},
|
},
|
||||||
id: 'urlbase',
|
id: 'baseUrl',
|
||||||
header: 'Base Url',
|
header: 'Base Url',
|
||||||
mantineCopyButtonProps: ({ cell, row }) => ({
|
|
||||||
className: 'urlbase',
|
|
||||||
id: `${cell.getValue()}-urlbase`,
|
|
||||||
}),
|
|
||||||
Cell: ({ renderedCellValue, row }) => renderedCellValue,
|
Cell: ({ renderedCellValue, row }) => renderedCellValue,
|
||||||
Header: ({ column }) => column.columnDef.header,
|
Header: ({ column }) => column.columnDef.header,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
accessorFn: (row) => {
|
accessorFn: (row) => {
|
||||||
if (row.category) {
|
if (row.filterName) {
|
||||||
return `${row.category}`;
|
return `${row.filterName}`;
|
||||||
}
|
}
|
||||||
return '';
|
return '';
|
||||||
},
|
},
|
||||||
id: 'category',
|
id: 'filterName',
|
||||||
header: 'Category',
|
header: 'Filter Name',
|
||||||
mantineCopyButtonProps: ({ cell, row }) => ({
|
|
||||||
className: 'category',
|
|
||||||
id: `${cell.getValue()}-category`,
|
|
||||||
}),
|
|
||||||
Cell: ({ renderedCellValue, row }) => renderedCellValue,
|
Cell: ({ renderedCellValue, row }) => renderedCellValue,
|
||||||
Header: ({ column }) => column.columnDef.header,
|
Header: ({ column }) => column.columnDef.header,
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
import type { MRT_ColumnDef } from 'mantine-react-table';
|
import type { MRT_ColumnDef } from 'mantine-react-table';
|
||||||
import { useMemo } from 'react';
|
import { useMemo } from 'react';
|
||||||
|
|
||||||
export default function ApplicationColumns(groups: any, groupData: any) {
|
export default function ApplicationColumns(groups: any) {
|
||||||
const columns = useMemo<MRT_ColumnDef<any>[]>(
|
const columns = useMemo<MRT_ColumnDef<any>[]>(
|
||||||
() => [
|
() => [
|
||||||
{
|
{
|
||||||
@@ -15,10 +15,6 @@ export default function ApplicationColumns(groups: any, groupData: any) {
|
|||||||
id: 'id',
|
id: 'id',
|
||||||
header: 'ID',
|
header: 'ID',
|
||||||
size: 50,
|
size: 50,
|
||||||
mantineCopyButtonProps: ({ cell, row }) => ({
|
|
||||||
className: 'id',
|
|
||||||
id: `${cell.getValue()}-id`,
|
|
||||||
}),
|
|
||||||
Cell: ({ renderedCellValue, row }) => renderedCellValue,
|
Cell: ({ renderedCellValue, row }) => renderedCellValue,
|
||||||
Header: ({ column }) => column.columnDef.header,
|
Header: ({ column }) => column.columnDef.header,
|
||||||
},
|
},
|
||||||
@@ -31,10 +27,6 @@ export default function ApplicationColumns(groups: any, groupData: any) {
|
|||||||
},
|
},
|
||||||
id: 'name',
|
id: 'name',
|
||||||
header: 'Name',
|
header: 'Name',
|
||||||
mantineCopyButtonProps: ({ cell, row }) => ({
|
|
||||||
className: 'name',
|
|
||||||
id: `${cell.getValue()}-name`,
|
|
||||||
}),
|
|
||||||
Cell: ({ renderedCellValue, row }) => renderedCellValue,
|
Cell: ({ renderedCellValue, row }) => renderedCellValue,
|
||||||
Header: ({ column }) => column.columnDef.header,
|
Header: ({ column }) => column.columnDef.header,
|
||||||
},
|
},
|
||||||
@@ -47,31 +39,21 @@ export default function ApplicationColumns(groups: any, groupData: any) {
|
|||||||
},
|
},
|
||||||
id: 'url',
|
id: 'url',
|
||||||
header: 'Url',
|
header: 'Url',
|
||||||
mantineCopyButtonProps: ({ cell, row }) => ({
|
|
||||||
className: 'url',
|
|
||||||
id: `${cell.getValue()}-url`,
|
|
||||||
}),
|
|
||||||
Cell: ({ renderedCellValue, row }) => renderedCellValue,
|
Cell: ({ renderedCellValue, row }) => renderedCellValue,
|
||||||
Header: ({ column }) => column.columnDef.header,
|
Header: ({ column }) => column.columnDef.header,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
accessorFn: (row) => {
|
accessorFn: (row) => {
|
||||||
const index: number = row.category;
|
if (row.category) {
|
||||||
if (index !== null && index !== undefined) {
|
return `${row.category}`;
|
||||||
return `${index}`;
|
|
||||||
}
|
}
|
||||||
return 'N/A';
|
return '';
|
||||||
},
|
},
|
||||||
id: 'category',
|
id: 'category',
|
||||||
header: 'Category',
|
header: 'Category',
|
||||||
editVariant: 'select',
|
editVariant: 'select',
|
||||||
mantineEditSelectProps: { data: groups },
|
mantineEditSelectProps: { data: groups },
|
||||||
mantineCopyButtonProps: ({ cell, row }) => ({
|
Cell: ({ renderedCellValue }) => renderedCellValue,
|
||||||
className: 'category',
|
|
||||||
id: `${cell.getValue()}-category`,
|
|
||||||
}),
|
|
||||||
Cell: ({ renderedCellValue, row }) =>
|
|
||||||
groupData[row?.original.category].category_name,
|
|
||||||
Header: ({ column }) => column.columnDef.header,
|
Header: ({ column }) => column.columnDef.header,
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
|
|||||||
@@ -20,12 +20,12 @@ export default function CategoryColumns() {
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
accessorFn: (row) => {
|
accessorFn: (row) => {
|
||||||
if (row.category_name) {
|
if (row.categoryName) {
|
||||||
return `${row.category_name}`;
|
return `${row.categoryName}`;
|
||||||
}
|
}
|
||||||
return '';
|
return '';
|
||||||
},
|
},
|
||||||
id: 'category_name',
|
id: 'categoryName',
|
||||||
header: 'Name',
|
header: 'Name',
|
||||||
size: 50,
|
size: 50,
|
||||||
Cell: ({ renderedCellValue, row }) => renderedCellValue,
|
Cell: ({ renderedCellValue, row }) => renderedCellValue,
|
||||||
@@ -33,13 +33,13 @@ export default function CategoryColumns() {
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
accessorFn: (row) => {
|
accessorFn: (row) => {
|
||||||
if (row.category_index > -1) {
|
if (row.categoryIndex > -1) {
|
||||||
return `${row.category_index}`;
|
return `${row.categoryIndex}`;
|
||||||
}
|
}
|
||||||
return '';
|
return '';
|
||||||
},
|
},
|
||||||
enableEditing: false,
|
enableEditing: false,
|
||||||
id: 'category_index',
|
id: 'categoryIndex',
|
||||||
header: 'Index',
|
header: 'Index',
|
||||||
size: 50,
|
size: 50,
|
||||||
Cell: ({ renderedCellValue, row }) => renderedCellValue,
|
Cell: ({ renderedCellValue, row }) => renderedCellValue,
|
||||||
@@ -47,12 +47,12 @@ export default function CategoryColumns() {
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
accessorFn: (row) => {
|
accessorFn: (row) => {
|
||||||
if (row.column_filter) {
|
if (row.filterName) {
|
||||||
return `${row.column_filter}`;
|
return `${row.filterName}`;
|
||||||
}
|
}
|
||||||
return '';
|
return '';
|
||||||
},
|
},
|
||||||
id: 'column_filter',
|
id: 'filterName',
|
||||||
header: 'Filter Name',
|
header: 'Filter Name',
|
||||||
size: 50,
|
size: 50,
|
||||||
Cell: ({ renderedCellValue, row }) => renderedCellValue,
|
Cell: ({ renderedCellValue, row }) => renderedCellValue,
|
||||||
|
|||||||
@@ -15,10 +15,6 @@ export default function MessagesColumns() {
|
|||||||
id: 'id',
|
id: 'id',
|
||||||
header: 'ID',
|
header: 'ID',
|
||||||
size: 50,
|
size: 50,
|
||||||
mantineCopyButtonProps: ({ cell, row }) => ({
|
|
||||||
className: 'id',
|
|
||||||
id: `${cell.getValue()}-id`,
|
|
||||||
}),
|
|
||||||
Cell: ({ renderedCellValue, row }) => renderedCellValue,
|
Cell: ({ renderedCellValue, row }) => renderedCellValue,
|
||||||
Header: ({ column }) => column.columnDef.header,
|
Header: ({ column }) => column.columnDef.header,
|
||||||
},
|
},
|
||||||
@@ -31,26 +27,6 @@ export default function MessagesColumns() {
|
|||||||
},
|
},
|
||||||
id: 'message',
|
id: 'message',
|
||||||
header: 'Message',
|
header: 'Message',
|
||||||
mantineCopyButtonProps: ({ cell, row }) => ({
|
|
||||||
className: 'message',
|
|
||||||
id: `${cell.getValue()}-message`,
|
|
||||||
}),
|
|
||||||
Cell: ({ renderedCellValue, row }) => renderedCellValue,
|
|
||||||
Header: ({ column }) => column.columnDef.header,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
accessorFn: (row) => {
|
|
||||||
if (row.easteregg) {
|
|
||||||
return `${row.easteregg}`;
|
|
||||||
}
|
|
||||||
return '';
|
|
||||||
},
|
|
||||||
id: 'easteregg',
|
|
||||||
header: 'Easter Egg?',
|
|
||||||
mantineCopyButtonProps: ({ cell, row }) => ({
|
|
||||||
className: 'easteregg',
|
|
||||||
id: `${cell.getValue()}-easteregg`,
|
|
||||||
}),
|
|
||||||
Cell: ({ renderedCellValue, row }) => renderedCellValue,
|
Cell: ({ renderedCellValue, row }) => renderedCellValue,
|
||||||
Header: ({ column }) => column.columnDef.header,
|
Header: ({ column }) => column.columnDef.header,
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -6,34 +6,26 @@ export default function PersonalizationColumns() {
|
|||||||
() => [
|
() => [
|
||||||
{
|
{
|
||||||
accessorFn: (row: any) => {
|
accessorFn: (row: any) => {
|
||||||
if (row.firstname) {
|
if (row.firstName) {
|
||||||
return `${row.firstname}`;
|
return `${row.firstName}`;
|
||||||
}
|
}
|
||||||
return '';
|
return '';
|
||||||
},
|
},
|
||||||
id: 'firstname',
|
id: 'firstName',
|
||||||
header: 'First Name',
|
header: 'First Name',
|
||||||
size: 50,
|
size: 50,
|
||||||
mantineCopyButtonProps: ({ cell, row }) => ({
|
|
||||||
className: 'firstname',
|
|
||||||
id: `${cell.getValue()}-firstname`,
|
|
||||||
}),
|
|
||||||
Cell: ({ renderedCellValue, row }) => renderedCellValue,
|
Cell: ({ renderedCellValue, row }) => renderedCellValue,
|
||||||
Header: ({ column }) => column.columnDef.header,
|
Header: ({ column }) => column.columnDef.header,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
accessorFn: (row: any) => {
|
accessorFn: (row: any) => {
|
||||||
if (row.lastname) {
|
if (row.lastName) {
|
||||||
return `${row.lastname}`;
|
return `${row.lastName}`;
|
||||||
}
|
}
|
||||||
return '';
|
return '';
|
||||||
},
|
},
|
||||||
id: 'lastname',
|
id: 'lastName',
|
||||||
header: 'Last Name',
|
header: 'Last Name',
|
||||||
mantineCopyButtonProps: ({ cell, row }) => ({
|
|
||||||
className: 'lastname',
|
|
||||||
id: `${cell.getValue()}-lastname`,
|
|
||||||
}),
|
|
||||||
Cell: ({ renderedCellValue, row }) => renderedCellValue,
|
Cell: ({ renderedCellValue, row }) => renderedCellValue,
|
||||||
Header: ({ column }) => column.columnDef.header,
|
Header: ({ column }) => column.columnDef.header,
|
||||||
},
|
},
|
||||||
@@ -46,10 +38,6 @@ export default function PersonalizationColumns() {
|
|||||||
},
|
},
|
||||||
id: 'email',
|
id: 'email',
|
||||||
header: 'Email',
|
header: 'Email',
|
||||||
mantineCopyButtonProps: ({ cell, row }) => ({
|
|
||||||
className: 'email',
|
|
||||||
id: `${cell.getValue()}-email`,
|
|
||||||
}),
|
|
||||||
Cell: ({ renderedCellValue, row }) => renderedCellValue,
|
Cell: ({ renderedCellValue, row }) => renderedCellValue,
|
||||||
Header: ({ column }) => column.columnDef.header,
|
Header: ({ column }) => column.columnDef.header,
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -7,12 +7,12 @@ export default function ThemeProvider({
|
|||||||
return (
|
return (
|
||||||
<Box
|
<Box
|
||||||
style={{
|
style={{
|
||||||
'--color-text-pri': theme.colortextpri,
|
'--color-text-pri': theme.primary,
|
||||||
'--color-text-acc': theme.colortextacc,
|
'--color-text-acc': theme.accent,
|
||||||
'--color-background': theme.colorbackground,
|
'--color-background': theme.backgroundColor,
|
||||||
'--color-border': theme.colorborder,
|
'--color-border': theme.border,
|
||||||
'--color-search-background': theme.colorsearchbackground,
|
'--color-search-background': theme.searchColor,
|
||||||
'--image-background': `url(${theme.imagebackground})`,
|
'--image-background': `url(${theme.backgroundImage})`,
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{children}
|
{children}
|
||||||
|
|||||||
@@ -13,9 +13,13 @@ import { useLocalStorage } from '@mantine/hooks';
|
|||||||
export default function Homepage({ theme }: any) {
|
export default function Homepage({ theme }: any) {
|
||||||
const { data, isFetching } = useQueryAPI({ endpoint: 'api/messages' });
|
const { data, isFetching } = useQueryAPI({ endpoint: 'api/messages' });
|
||||||
const [displayedGreeting, setDisplayedGreeting] = useState('');
|
const [displayedGreeting, setDisplayedGreeting] = useState('');
|
||||||
const [contentType, setContentType] = useLocalStorage<any>({
|
const [appFilter, setAppFilter] = useLocalStorage<[any]>({
|
||||||
key: 'contenttype',
|
key: 'appFilter',
|
||||||
defaultValue: 'All',
|
defaultValue: ['All'],
|
||||||
|
});
|
||||||
|
const [bookmarkFilter, setBookmarkFilter] = useLocalStorage<[any]>({
|
||||||
|
key: 'bookmarkFilter',
|
||||||
|
defaultValue: ['All'],
|
||||||
});
|
});
|
||||||
function date() {
|
function date() {
|
||||||
const currentDate = new Date();
|
const currentDate = new Date();
|
||||||
@@ -33,18 +37,18 @@ export default function Homepage({ theme }: any) {
|
|||||||
const greet = Math.floor(currentTime.getHours() / 6);
|
const greet = Math.floor(currentTime.getHours() / 6);
|
||||||
const easterEggChance = Math.floor(Math.random() * 100);
|
const easterEggChance = Math.floor(Math.random() * 100);
|
||||||
let timeBased: any = [];
|
let timeBased: any = [];
|
||||||
let easterEggs: any = [];
|
let customGreetings: any = [];
|
||||||
for (const l of list) {
|
for (const l of list) {
|
||||||
if (l.easteregg === 'N') {
|
if (l.customGreeting === 0) {
|
||||||
timeBased = timeBased.concat(l);
|
timeBased = timeBased.concat(l);
|
||||||
} else {
|
} else {
|
||||||
easterEggs = easterEggs.concat(l);
|
customGreetings = customGreetings.concat(l);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (easterEggChance > 10 || easterEggs.length === 0) {
|
if (easterEggChance > 10 || customGreetings.length === 0) {
|
||||||
return timeBased[greet].message;
|
return timeBased[greet].message;
|
||||||
}
|
}
|
||||||
return easterEggs[Math.floor(Math.random() * easterEggs.length)].message;
|
return customGreetings[Math.floor(Math.random() * customGreetings.length)].message;
|
||||||
}
|
}
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
@@ -57,12 +61,14 @@ export default function Homepage({ theme }: any) {
|
|||||||
<Stack gap={0} className={stackClasses.containerStack} justify='center'>
|
<Stack gap={0} className={stackClasses.containerStack} justify='center'>
|
||||||
<Search />
|
<Search />
|
||||||
<Header date={date()} greet={displayedGreeting} />
|
<Header date={date()} greet={displayedGreeting} />
|
||||||
<Applications contentType={contentType} />
|
<Applications contentType={appFilter} />
|
||||||
<Bookmarks contentType={contentType} />
|
<Bookmarks contentType={bookmarkFilter} />
|
||||||
<SettingsButton
|
<SettingsButton
|
||||||
theme={theme}
|
theme={theme}
|
||||||
contentType={contentType}
|
setAppFilter={setAppFilter}
|
||||||
setContentType={setContentType}
|
appFilter={appFilter}
|
||||||
|
setBookmarkFilter={setBookmarkFilter}
|
||||||
|
bookmarkFilter={bookmarkFilter}
|
||||||
/>
|
/>
|
||||||
</Stack>
|
</Stack>
|
||||||
);
|
);
|
||||||
|
|||||||
@@ -13,6 +13,8 @@ function Applications({ contentType }: any) {
|
|||||||
}
|
}
|
||||||
}, [isFetching]);
|
}, [isFetching]);
|
||||||
return (
|
return (
|
||||||
|
<>
|
||||||
|
{applications.length > 0 && (
|
||||||
<Stack id='apps' style={{ gap: 0 }}>
|
<Stack id='apps' style={{ gap: 0 }}>
|
||||||
<Text className={texts.sectionTitle} classNames={texts}>
|
<Text className={texts.sectionTitle} classNames={texts}>
|
||||||
Applications
|
Applications
|
||||||
@@ -31,20 +33,25 @@ function Applications({ contentType }: any) {
|
|||||||
paddingBottom: 'var(--module-spacing)',
|
paddingBottom: 'var(--module-spacing)',
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{applications?.map((item: any) => {
|
{applications?.map((application: any) => {
|
||||||
if (item.category === contentType || contentType === 'All')
|
if (
|
||||||
|
contentType.includes(application.filterName) ||
|
||||||
|
contentType.includes('All')
|
||||||
|
)
|
||||||
return (
|
return (
|
||||||
<AppItem
|
<AppItem
|
||||||
key={item.name}
|
key={application.name}
|
||||||
name={item.name}
|
name={application.name}
|
||||||
url={item.url}
|
url={application.url}
|
||||||
icon={item.icon}
|
icon={application.icon}
|
||||||
category={item.category}
|
category={application.category}
|
||||||
/>
|
/>
|
||||||
);
|
);
|
||||||
})}
|
})}
|
||||||
</Stack>
|
</Stack>
|
||||||
</Stack>
|
</Stack>
|
||||||
|
)}
|
||||||
|
</>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -20,7 +20,6 @@ function Links({ contentType }: any) {
|
|||||||
setCategories(groupData);
|
setCategories(groupData);
|
||||||
}
|
}
|
||||||
}, [linksIsFetched, groupsIsFetched]);
|
}, [linksIsFetched, groupsIsFetched]);
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<>
|
<>
|
||||||
{groupsIsFetched && linksIsFetched && categories?.length > 0 && (
|
{groupsIsFetched && linksIsFetched && categories?.length > 0 && (
|
||||||
@@ -39,13 +38,16 @@ function Links({ contentType }: any) {
|
|||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{categories.map((category: any) => {
|
{categories.map((category: any) => {
|
||||||
if (category.column_filter === contentType || contentType === 'All') {
|
if (
|
||||||
|
contentType.includes(category.filterName) ||
|
||||||
|
contentType.includes('All')
|
||||||
|
) {
|
||||||
return (
|
return (
|
||||||
<LinkGroups
|
<LinkGroups
|
||||||
key={category.id}
|
key={category.id}
|
||||||
category={category.category_name}
|
category={category.categoryName}
|
||||||
links={bookmarks.filter(
|
links={bookmarks.filter(
|
||||||
(bookmark: any) => bookmark.category === category.category_index,
|
(bookmark: any) => bookmark.category === category.categoryName,
|
||||||
)}
|
)}
|
||||||
/>
|
/>
|
||||||
);
|
);
|
||||||
|
|||||||
@@ -22,7 +22,7 @@ function MessageInfo() {
|
|||||||
group={index + 1}
|
group={index + 1}
|
||||||
index={greeting.index}
|
index={greeting.index}
|
||||||
greeting={greeting.message}
|
greeting={greeting.message}
|
||||||
easterEgg={greeting.easteregg}
|
easterEgg={greeting.customGreeting}
|
||||||
/>
|
/>
|
||||||
))}
|
))}
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -63,6 +63,7 @@ export default function Search() {
|
|||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
<TextInput
|
<TextInput
|
||||||
|
autoFocus
|
||||||
className={textInputClasses.search}
|
className={textInputClasses.search}
|
||||||
classNames={textInputClasses}
|
classNames={textInputClasses}
|
||||||
spellCheck='true'
|
spellCheck='true'
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
import { Button, Menu, NavLink, Select } from '@mantine/core';
|
import { Button, Menu, MultiSelect, NavLink } from '@mantine/core';
|
||||||
import { useEffect, useState } from 'react';
|
import { useEffect, useState } from 'react';
|
||||||
import { FiMenu, FiMonitor } from 'react-icons/fi';
|
import { FiMenu, FiMonitor } from 'react-icons/fi';
|
||||||
import { useQueryAPI } from '../../../hooks/useAPI';
|
import { useQueryAPI } from '../../../hooks/useAPI';
|
||||||
@@ -7,7 +7,13 @@ import menu from '../../../styles/Menu.module.css';
|
|||||||
import navLink from '../../../styles/NavLink.module.css';
|
import navLink from '../../../styles/NavLink.module.css';
|
||||||
import selectClasses from '../../../styles/Select.module.css';
|
import selectClasses from '../../../styles/Select.module.css';
|
||||||
|
|
||||||
function SettingsButton({ contentType, setContentType, theme }: any) {
|
function SettingsButton({
|
||||||
|
appFilter,
|
||||||
|
setAppFilter,
|
||||||
|
bookmarkFilter,
|
||||||
|
setBookmarkFilter,
|
||||||
|
theme,
|
||||||
|
}: any) {
|
||||||
const { data, isFetched } = useQueryAPI({ endpoint: 'api/appCategories' });
|
const { data, isFetched } = useQueryAPI({ endpoint: 'api/appCategories' });
|
||||||
const [categories, setCategories] = useState([{ value: 'All', label: 'All' }]);
|
const [categories, setCategories] = useState([{ value: 'All', label: 'All' }]);
|
||||||
|
|
||||||
@@ -15,7 +21,7 @@ function SettingsButton({ contentType, setContentType, theme }: any) {
|
|||||||
if (data) {
|
if (data) {
|
||||||
const list: [any] =
|
const list: [any] =
|
||||||
data.map((category: any) => {
|
data.map((category: any) => {
|
||||||
return { value: category.category, label: category.category };
|
return { value: category.filterName, label: category.filterName };
|
||||||
}) || [];
|
}) || [];
|
||||||
list.unshift({ value: 'All', label: 'All' });
|
list.unshift({ value: 'All', label: 'All' });
|
||||||
setCategories(list);
|
setCategories(list);
|
||||||
@@ -57,13 +63,24 @@ function SettingsButton({ contentType, setContentType, theme }: any) {
|
|||||||
classNames={navLink}
|
classNames={navLink}
|
||||||
/>
|
/>
|
||||||
</NavLink>
|
</NavLink>
|
||||||
<Select
|
<MultiSelect
|
||||||
label='Homepage Filter'
|
label='App Filter'
|
||||||
data={categories ?? []}
|
data={categories ?? []}
|
||||||
defaultValue={contentType}
|
defaultValue={appFilter}
|
||||||
withCheckIcon={false}
|
withCheckIcon={false}
|
||||||
onChange={(data: any) => {
|
onChange={(data: any) => {
|
||||||
setContentType(data);
|
setAppFilter(data);
|
||||||
|
}}
|
||||||
|
classNames={selectClasses}
|
||||||
|
comboboxProps={{ withinPortal: false }}
|
||||||
|
/>
|
||||||
|
<MultiSelect
|
||||||
|
label='Bookmark Filter'
|
||||||
|
data={categories ?? []}
|
||||||
|
defaultValue={bookmarkFilter}
|
||||||
|
withCheckIcon={false}
|
||||||
|
onChange={(data: any) => {
|
||||||
|
setBookmarkFilter(data);
|
||||||
}}
|
}}
|
||||||
classNames={selectClasses}
|
classNames={selectClasses}
|
||||||
comboboxProps={{ withinPortal: false }}
|
comboboxProps={{ withinPortal: false }}
|
||||||
|
|||||||
@@ -11,9 +11,9 @@ const BookmarkSettings = () => {
|
|||||||
});
|
});
|
||||||
const {
|
const {
|
||||||
data: groupData,
|
data: groupData,
|
||||||
isFetching: groupDataisFetching,
|
isFetching: groupDataIsFetching,
|
||||||
isLoading: groupDataisLoading,
|
isLoading: groupDataIsLoading,
|
||||||
isFetched: groupDataisFetched,
|
isFetched: groupDataIsFetched,
|
||||||
} = useQueryAPI({ endpoint: 'api/categories' });
|
} = useQueryAPI({ endpoint: 'api/categories' });
|
||||||
const [bookmarkData, setBookmarkData] = useState<any>([]);
|
const [bookmarkData, setBookmarkData] = useState<any>([]);
|
||||||
const [groups, setGroups] = useState([]);
|
const [groups, setGroups] = useState([]);
|
||||||
@@ -26,15 +26,14 @@ const BookmarkSettings = () => {
|
|||||||
});
|
});
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
if (groupDataisFetched) {
|
if (groupData) {
|
||||||
const groupList = groupData.map((category: any) => {
|
const groupList = groupData?.map((category: any) => {
|
||||||
return category.category_name;
|
return category.categoryName;
|
||||||
});
|
});
|
||||||
setGroups(groupList);
|
setGroups(groupList);
|
||||||
setFullyFetched(true);
|
setFullyFetched(true);
|
||||||
}
|
}
|
||||||
}, [groupDataisFetched]);
|
}, [groupData]);
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<Stack>
|
<Stack>
|
||||||
<Text className={textClasses.settingsSubTitle} classNames={textClasses}>
|
<Text className={textClasses.settingsSubTitle} classNames={textClasses}>
|
||||||
@@ -42,11 +41,12 @@ const BookmarkSettings = () => {
|
|||||||
</Text>
|
</Text>
|
||||||
<DataTable
|
<DataTable
|
||||||
tableName='Applications'
|
tableName='Applications'
|
||||||
columns={BookmarkColumns(groups, groupData)}
|
columns={BookmarkColumns(groups)}
|
||||||
tableData={bookmarkData}
|
tableData={bookmarkData}
|
||||||
isFetching={isFetching}
|
isFetching={isFetching}
|
||||||
isLoading={isLoading}
|
isLoading={isLoading}
|
||||||
endpoint={endpoint}
|
endpoint={endpoint}
|
||||||
|
grouping='category'
|
||||||
/>
|
/>
|
||||||
</Stack>
|
</Stack>
|
||||||
);
|
);
|
||||||
|
|||||||
@@ -5,7 +5,7 @@ import PersonalizationColumns from '../../../DataTable/columns/PersonalizationCo
|
|||||||
import { useQueryAPI } from '../../../hooks/useAPI';
|
import { useQueryAPI } from '../../../hooks/useAPI';
|
||||||
import { textClasses } from '../../../styles';
|
import { textClasses } from '../../../styles';
|
||||||
const PersonalizationSettings = () => {
|
const PersonalizationSettings = () => {
|
||||||
const endpoint = 'api/personaldata';
|
const endpoint = 'api/personalData';
|
||||||
const { data, isFetching, isLoading, isFetched } = useQueryAPI({
|
const { data, isFetching, isLoading, isFetched } = useQueryAPI({
|
||||||
endpoint: endpoint,
|
endpoint: endpoint,
|
||||||
});
|
});
|
||||||
|
|||||||
@@ -22,7 +22,7 @@ export default function ThemeModalContent({ selectedTheme }: any) {
|
|||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
<Icon
|
<Icon
|
||||||
style={{ color: previewTheme.theme.colortextpri }}
|
style={{ color: previewTheme.theme.primary }}
|
||||||
icon={'mdi:check'}
|
icon={'mdi:check'}
|
||||||
height={32}
|
height={32}
|
||||||
width={32}
|
width={32}
|
||||||
@@ -43,7 +43,7 @@ export default function ThemeModalContent({ selectedTheme }: any) {
|
|||||||
fontWeight: 400,
|
fontWeight: 400,
|
||||||
fontSize: 11,
|
fontSize: 11,
|
||||||
fontStyle: 'normal',
|
fontStyle: 'normal',
|
||||||
color: previewTheme.theme.colortextpri,
|
color: previewTheme.theme.primary,
|
||||||
fontFamily:
|
fontFamily:
|
||||||
'-apple-system, Jost, BlinkMacSystemFont, Helvetica Neue, Roboto, sans-serif !important',
|
'-apple-system, Jost, BlinkMacSystemFont, Helvetica Neue, Roboto, sans-serif !important',
|
||||||
margin: 0,
|
margin: 0,
|
||||||
@@ -56,7 +56,7 @@ export default function ThemeModalContent({ selectedTheme }: any) {
|
|||||||
fontWeight: 400,
|
fontWeight: 400,
|
||||||
fontSize: 11,
|
fontSize: 11,
|
||||||
fontStyle: 'italic',
|
fontStyle: 'italic',
|
||||||
color: previewTheme.theme.colortextacc,
|
color: previewTheme.theme.accent,
|
||||||
fontFamily:
|
fontFamily:
|
||||||
'-apple-system, Jost, BlinkMacSystemFont, Helvetica Neue, Roboto, sans-serif !important',
|
'-apple-system, Jost, BlinkMacSystemFont, Helvetica Neue, Roboto, sans-serif !important',
|
||||||
margin: 0,
|
margin: 0,
|
||||||
@@ -73,14 +73,14 @@ export default function ThemeModalContent({ selectedTheme }: any) {
|
|||||||
<Stack
|
<Stack
|
||||||
style={{
|
style={{
|
||||||
width: '100%',
|
width: '100%',
|
||||||
backgroundColor: selectedTheme.colorbackground,
|
backgroundColor: selectedTheme.backgroundColor,
|
||||||
borderRadius: '10px',
|
borderRadius: '10px',
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
<Group
|
<Group
|
||||||
justify='center'
|
justify='center'
|
||||||
style={{
|
style={{
|
||||||
color: selectedTheme.colortextpri,
|
color: selectedTheme.primary,
|
||||||
paddingTop: '1rem',
|
paddingTop: '1rem',
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
@@ -97,14 +97,14 @@ export default function ThemeModalContent({ selectedTheme }: any) {
|
|||||||
textTransform: 'uppercase',
|
textTransform: 'uppercase',
|
||||||
marginTop: '20px',
|
marginTop: '20px',
|
||||||
marginBottom: '20px',
|
marginBottom: '20px',
|
||||||
color: selectedTheme.colortextpri,
|
color: selectedTheme.primary,
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
Applications
|
Applications
|
||||||
</Text>
|
</Text>
|
||||||
<Stack
|
<Stack
|
||||||
style={{
|
style={{
|
||||||
background: selectedTheme.colorbackground,
|
background: selectedTheme.backgroundColor,
|
||||||
gap: '.25rem',
|
gap: '.25rem',
|
||||||
backgroundSize: 'cover',
|
backgroundSize: 'cover',
|
||||||
borderBottom: '0px solid',
|
borderBottom: '0px solid',
|
||||||
@@ -134,7 +134,7 @@ export default function ThemeModalContent({ selectedTheme }: any) {
|
|||||||
textTransform: 'uppercase',
|
textTransform: 'uppercase',
|
||||||
marginTop: '20px',
|
marginTop: '20px',
|
||||||
marginBottom: '20px',
|
marginBottom: '20px',
|
||||||
color: selectedTheme.colortextpri,
|
color: selectedTheme.primary,
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
Bookmarks
|
Bookmarks
|
||||||
@@ -166,7 +166,7 @@ export default function ThemeModalContent({ selectedTheme }: any) {
|
|||||||
fontWeight: 400,
|
fontWeight: 400,
|
||||||
height: '10px',
|
height: '10px',
|
||||||
width: 'auto',
|
width: 'auto',
|
||||||
color: selectedTheme.colortextacc,
|
color: selectedTheme.accent,
|
||||||
textTransform: 'uppercase',
|
textTransform: 'uppercase',
|
||||||
marginTop: '20px',
|
marginTop: '20px',
|
||||||
marginBottom: '20px',
|
marginBottom: '20px',
|
||||||
@@ -179,7 +179,7 @@ export default function ThemeModalContent({ selectedTheme }: any) {
|
|||||||
display: 'block',
|
display: 'block',
|
||||||
fontSize: '14px',
|
fontSize: '14px',
|
||||||
lineHeight: 2,
|
lineHeight: 2,
|
||||||
color: selectedTheme.colortextpri,
|
color: selectedTheme.primary,
|
||||||
}}
|
}}
|
||||||
component='a'
|
component='a'
|
||||||
>
|
>
|
||||||
@@ -190,7 +190,7 @@ export default function ThemeModalContent({ selectedTheme }: any) {
|
|||||||
display: 'block',
|
display: 'block',
|
||||||
fontSize: '14px',
|
fontSize: '14px',
|
||||||
lineHeight: 2,
|
lineHeight: 2,
|
||||||
color: selectedTheme.colortextpri,
|
color: selectedTheme.primary,
|
||||||
}}
|
}}
|
||||||
component='a'
|
component='a'
|
||||||
>
|
>
|
||||||
@@ -213,7 +213,7 @@ export default function ThemeModalContent({ selectedTheme }: any) {
|
|||||||
fontWeight: 400,
|
fontWeight: 400,
|
||||||
height: '10px',
|
height: '10px',
|
||||||
width: 'auto',
|
width: 'auto',
|
||||||
color: selectedTheme.colortextacc,
|
color: selectedTheme.accent,
|
||||||
textTransform: 'uppercase',
|
textTransform: 'uppercase',
|
||||||
marginTop: '20px',
|
marginTop: '20px',
|
||||||
marginBottom: '20px',
|
marginBottom: '20px',
|
||||||
@@ -226,7 +226,7 @@ export default function ThemeModalContent({ selectedTheme }: any) {
|
|||||||
display: 'block',
|
display: 'block',
|
||||||
fontSize: '14px',
|
fontSize: '14px',
|
||||||
lineHeight: 2,
|
lineHeight: 2,
|
||||||
color: selectedTheme.colortextpri,
|
color: selectedTheme.primary,
|
||||||
}}
|
}}
|
||||||
component='a'
|
component='a'
|
||||||
>
|
>
|
||||||
@@ -237,7 +237,7 @@ export default function ThemeModalContent({ selectedTheme }: any) {
|
|||||||
display: 'block',
|
display: 'block',
|
||||||
fontSize: '14px',
|
fontSize: '14px',
|
||||||
lineHeight: 2,
|
lineHeight: 2,
|
||||||
color: selectedTheme.colortextpri,
|
color: selectedTheme.primary,
|
||||||
}}
|
}}
|
||||||
component='a'
|
component='a'
|
||||||
>
|
>
|
||||||
|
|||||||
@@ -123,11 +123,11 @@ function ThemesSettings({ theme }: any) {
|
|||||||
onClick={() => {
|
onClick={() => {
|
||||||
setColorId('primary');
|
setColorId('primary');
|
||||||
openPicker();
|
openPicker();
|
||||||
setColorValue(selectedTheme.colortextpri);
|
setColorValue(selectedTheme.primary);
|
||||||
}}
|
}}
|
||||||
radius={'sm'}
|
radius={'sm'}
|
||||||
w={'100px'}
|
w={'100px'}
|
||||||
color={selectedTheme.colortextpri}
|
color={selectedTheme.primary}
|
||||||
style={{ cursor: 'pointer' }}
|
style={{ cursor: 'pointer' }}
|
||||||
/>
|
/>
|
||||||
</Group>
|
</Group>
|
||||||
@@ -137,11 +137,11 @@ function ThemesSettings({ theme }: any) {
|
|||||||
onClick={() => {
|
onClick={() => {
|
||||||
setColorId('accent');
|
setColorId('accent');
|
||||||
openPicker();
|
openPicker();
|
||||||
setColorValue(selectedTheme.colortextacc);
|
setColorValue(selectedTheme.accent);
|
||||||
}}
|
}}
|
||||||
radius={'sm'}
|
radius={'sm'}
|
||||||
w={'100px'}
|
w={'100px'}
|
||||||
color={selectedTheme.colortextacc}
|
color={selectedTheme.accent}
|
||||||
style={{ cursor: 'pointer' }}
|
style={{ cursor: 'pointer' }}
|
||||||
/>
|
/>
|
||||||
</Group>
|
</Group>
|
||||||
@@ -151,11 +151,11 @@ function ThemesSettings({ theme }: any) {
|
|||||||
onClick={() => {
|
onClick={() => {
|
||||||
setColorId('background');
|
setColorId('background');
|
||||||
openPicker();
|
openPicker();
|
||||||
setColorValue(selectedTheme.colorbackground);
|
setColorValue(selectedTheme.backgroundColor);
|
||||||
}}
|
}}
|
||||||
radius={'sm'}
|
radius={'sm'}
|
||||||
w={'100px'}
|
w={'100px'}
|
||||||
color={selectedTheme.colorbackground}
|
color={selectedTheme.backgroundColor}
|
||||||
style={{ cursor: 'pointer' }}
|
style={{ cursor: 'pointer' }}
|
||||||
/>
|
/>
|
||||||
</Group>
|
</Group>
|
||||||
@@ -165,11 +165,11 @@ function ThemesSettings({ theme }: any) {
|
|||||||
onClick={() => {
|
onClick={() => {
|
||||||
setColorId('border');
|
setColorId('border');
|
||||||
openPicker();
|
openPicker();
|
||||||
setColorValue(selectedTheme.colorborder);
|
setColorValue(selectedTheme.border);
|
||||||
}}
|
}}
|
||||||
radius={'sm'}
|
radius={'sm'}
|
||||||
w={'100px'}
|
w={'100px'}
|
||||||
color={selectedTheme.colorborder}
|
color={selectedTheme.border}
|
||||||
style={{ cursor: 'pointer' }}
|
style={{ cursor: 'pointer' }}
|
||||||
/>
|
/>
|
||||||
</Group>
|
</Group>
|
||||||
@@ -179,20 +179,23 @@ function ThemesSettings({ theme }: any) {
|
|||||||
onClick={() => {
|
onClick={() => {
|
||||||
setColorId('searchbackground');
|
setColorId('searchbackground');
|
||||||
openPicker();
|
openPicker();
|
||||||
setColorValue(selectedTheme.colorsearchbackground);
|
setColorValue(selectedTheme.searchColor);
|
||||||
}}
|
}}
|
||||||
radius={'sm'}
|
radius={'sm'}
|
||||||
w={'100px'}
|
w={'100px'}
|
||||||
color={selectedTheme.colorsearchbackground}
|
color={selectedTheme.searchColor}
|
||||||
style={{ cursor: 'pointer' }}
|
style={{ cursor: 'pointer' }}
|
||||||
/>
|
/>
|
||||||
</Group>
|
</Group>
|
||||||
<Group c={'black'} justify='space-between'>
|
<Group c={'black'} justify='space-between'>
|
||||||
<TextInput
|
<TextInput
|
||||||
label='Background Image Path'
|
label='Background Image Path'
|
||||||
value={selectedTheme.imagebackground}
|
value={selectedTheme.backgroundImage}
|
||||||
onChange={(e) =>
|
onChange={(e) =>
|
||||||
setSelectedTheme({ ...selectedTheme, imagebackground: e.target.value })
|
setSelectedTheme({
|
||||||
|
...selectedTheme,
|
||||||
|
backgroundImage: e.target.value,
|
||||||
|
})
|
||||||
}
|
}
|
||||||
styles={{
|
styles={{
|
||||||
label: {
|
label: {
|
||||||
@@ -220,31 +223,31 @@ function ThemesSettings({ theme }: any) {
|
|||||||
case 'primary':
|
case 'primary':
|
||||||
setSelectedTheme({
|
setSelectedTheme({
|
||||||
...selectedTheme,
|
...selectedTheme,
|
||||||
colortextpri: colorValue,
|
primary: colorValue,
|
||||||
});
|
});
|
||||||
break;
|
break;
|
||||||
case 'accent':
|
case 'accent':
|
||||||
setSelectedTheme({
|
setSelectedTheme({
|
||||||
...selectedTheme,
|
...selectedTheme,
|
||||||
colortextacc: colorValue,
|
accent: colorValue,
|
||||||
});
|
});
|
||||||
break;
|
break;
|
||||||
case 'background':
|
case 'background':
|
||||||
setSelectedTheme({
|
setSelectedTheme({
|
||||||
...selectedTheme,
|
...selectedTheme,
|
||||||
colorbackground: colorValue,
|
backgroundColor: colorValue,
|
||||||
});
|
});
|
||||||
break;
|
break;
|
||||||
case 'border':
|
case 'border':
|
||||||
setSelectedTheme({
|
setSelectedTheme({
|
||||||
...selectedTheme,
|
...selectedTheme,
|
||||||
colorborder: colorValue,
|
border: colorValue,
|
||||||
});
|
});
|
||||||
break;
|
break;
|
||||||
case 'searchbackground':
|
case 'searchbackground':
|
||||||
setSelectedTheme({
|
setSelectedTheme({
|
||||||
...selectedTheme,
|
...selectedTheme,
|
||||||
colorsearchbackground: colorValue,
|
searchColor: colorValue,
|
||||||
});
|
});
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
@@ -295,12 +298,12 @@ function ThemesSettings({ theme }: any) {
|
|||||||
setSelectedTheme({
|
setSelectedTheme({
|
||||||
id: undefined,
|
id: undefined,
|
||||||
name: 'default',
|
name: 'default',
|
||||||
imagebackground: 'none',
|
backgroundImage: 'none',
|
||||||
colorbackground: '#EEEEEE',
|
backgroundColor: '#EEEEEE',
|
||||||
colorsearchbackground: '#00000033',
|
searchColor: '#00000033',
|
||||||
colortextpri: '#222222',
|
primary: '#222222',
|
||||||
colortextacc: '#5c5c5c',
|
accent: '#5c5c5c',
|
||||||
colorborder: '#5c5c5c',
|
border: '#5c5c5c',
|
||||||
});
|
});
|
||||||
open();
|
open();
|
||||||
}}
|
}}
|
||||||
@@ -316,9 +319,9 @@ function ThemesSettings({ theme }: any) {
|
|||||||
w={'100%'}
|
w={'100%'}
|
||||||
h={'75px'}
|
h={'75px'}
|
||||||
style={{
|
style={{
|
||||||
backgroundColor: theme.colorbackground,
|
backgroundColor: theme.backgroundColor,
|
||||||
border: `solid ${theme.colorborder}`,
|
border: `solid ${theme.border}`,
|
||||||
color: theme.colortextpri,
|
color: theme.primary,
|
||||||
}}
|
}}
|
||||||
data-theme={theme.name}
|
data-theme={theme.name}
|
||||||
onClick={() => {
|
onClick={() => {
|
||||||
@@ -337,11 +340,11 @@ function ThemesSettings({ theme }: any) {
|
|||||||
>
|
>
|
||||||
<FiEdit />
|
<FiEdit />
|
||||||
</ActionIcon>
|
</ActionIcon>
|
||||||
<ColorSwatch color={theme.colorbackground} />
|
<ColorSwatch color={theme.backgroundColor} />
|
||||||
<ColorSwatch color={theme.colorsearchbackground} />
|
<ColorSwatch color={theme.searchColor} />
|
||||||
<ColorSwatch color={theme.colortextpri} />
|
<ColorSwatch color={theme.primary} />
|
||||||
<ColorSwatch color={theme.colortextacc} />
|
<ColorSwatch color={theme.accent} />
|
||||||
<ColorSwatch color={theme.colorborder} />
|
<ColorSwatch color={theme.border} />
|
||||||
|
|
||||||
<ActionIcon
|
<ActionIcon
|
||||||
className={actionIconClasses.editButton}
|
className={actionIconClasses.editButton}
|
||||||
|
|||||||
Reference in New Issue
Block a user