1
0
Fork 0
mirror of https://github.com/pawelmalak/flame.git synced 2025-07-27 06:49:37 +02:00

Add app categories (#2)

add app categories
This commit is contained in:
François Darveau 2021-06-26 15:06:47 -04:00 committed by François Darveau
parent beec2485d5
commit c80e4257ff
4 changed files with 41 additions and 38 deletions

View file

@ -25,7 +25,7 @@ interface ComponentProps {
export enum ContentType {
category,
app,
app
}
const Apps = (props: ComponentProps): JSX.Element => {
@ -34,26 +34,24 @@ const Apps = (props: ComponentProps): JSX.Element => {
const [modalIsOpen, setModalIsOpen] = useState(false);
const [formContentType, setFormContentType] = useState(ContentType.category);
const [isInEdit, setIsInEdit] = useState(false);
const [tableContentType, setTableContentType] = useState(
ContentType.category
);
const [tableContentType, setTableContentType] = useState(ContentType.category);
const [isInUpdate, setIsInUpdate] = useState(false);
const [categoryInUpdate, setCategoryInUpdate] = useState<Category>({
name: "",
name: '',
id: -1,
isPinned: false,
orderId: 0,
type: "apps",
type: 'apps',
apps: [],
bookmarks: [],
createdAt: new Date(),
updatedAt: new Date(),
});
updatedAt: new Date()
})
const [appInUpdate, setAppInUpdate] = useState<App>({
name: "string",
url: "string",
name: 'string',
url: 'string',
categoryId: -1,
icon: "string",
icon: 'string',
isPinned: false,
orderId: 0,
id: 0,