itembox images et cache
This commit is contained in:
parent
83291c246b
commit
6602bfd408
Binary file not shown.
@ -3,57 +3,53 @@
|
|||||||
"WorkspaceRootPath": "C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\",
|
"WorkspaceRootPath": "C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\",
|
||||||
"Documents": [
|
"Documents": [
|
||||||
{
|
{
|
||||||
"AbsoluteMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\components\\nav\\Navbar.jsx||{14D17961-FE51-464D-9111-C4AF11D7D99A}",
|
"AbsoluteMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|C:\\Users\\Admin\\Source\\Repos\\2024-DEV-BUT3\\src\\api\\image-request.js||{14D17961-FE51-464D-9111-C4AF11D7D99A}",
|
||||||
"RelativeMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|solutionrelative:src\\components\\nav\\Navbar.jsx||{14D17961-FE51-464D-9111-C4AF11D7D99A}"
|
"RelativeMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|solutionrelative:src\\api\\image-request.js||{14D17961-FE51-464D-9111-C4AF11D7D99A}"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"AbsoluteMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\components\\app-layout.jsx||{14D17961-FE51-464D-9111-C4AF11D7D99A}",
|
"AbsoluteMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\components\\item\\RoomItemsList.jsx||{14D17961-FE51-464D-9111-C4AF11D7D99A}",
|
||||||
"RelativeMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|solutionrelative:src\\components\\app-layout.jsx||{14D17961-FE51-464D-9111-C4AF11D7D99A}"
|
"RelativeMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|solutionrelative:src\\components\\item\\RoomItemsList.jsx||{14D17961-FE51-464D-9111-C4AF11D7D99A}"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"AbsoluteMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\contexts\\auth-context.jsx||{14D17961-FE51-464D-9111-C4AF11D7D99A}",
|
"AbsoluteMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\components\\item\\ItemBox.jsx||{14D17961-FE51-464D-9111-C4AF11D7D99A}",
|
||||||
"RelativeMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|solutionrelative:src\\contexts\\auth-context.jsx||{14D17961-FE51-464D-9111-C4AF11D7D99A}"
|
"RelativeMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|solutionrelative:src\\components\\item\\ItemBox.jsx||{14D17961-FE51-464D-9111-C4AF11D7D99A}"
|
||||||
},
|
|
||||||
{
|
|
||||||
"AbsoluteMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\components\\authenticated.jsx||{14D17961-FE51-464D-9111-C4AF11D7D99A}",
|
|
||||||
"RelativeMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|solutionrelative:src\\components\\authenticated.jsx||{14D17961-FE51-464D-9111-C4AF11D7D99A}"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"AbsoluteMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\api\\authentication.js||{14D17961-FE51-464D-9111-C4AF11D7D99A}",
|
|
||||||
"RelativeMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|solutionrelative:src\\api\\authentication.js||{14D17961-FE51-464D-9111-C4AF11D7D99A}"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"AbsoluteMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\App.jsx||{14D17961-FE51-464D-9111-C4AF11D7D99A}",
|
|
||||||
"RelativeMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|solutionrelative:src\\App.jsx||{14D17961-FE51-464D-9111-C4AF11D7D99A}"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"AbsoluteMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\pages\\test.jsx||{14D17961-FE51-464D-9111-C4AF11D7D99A}",
|
|
||||||
"RelativeMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|solutionrelative:src\\pages\\test.jsx||{14D17961-FE51-464D-9111-C4AF11D7D99A}"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"AbsoluteMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\api\\room.js||{14D17961-FE51-464D-9111-C4AF11D7D99A}",
|
|
||||||
"RelativeMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|solutionrelative:src\\api\\room.js||{14D17961-FE51-464D-9111-C4AF11D7D99A}"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"AbsoluteMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\.vs\\2024-DEV-BUT3\\config\\applicationhost.config||{FA3CD31E-987B-443A-9B81-186104E8DAC1}",
|
|
||||||
"RelativeMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|solutionrelative:.vs\\2024-DEV-BUT3\\config\\applicationhost.config||{FA3CD31E-987B-443A-9B81-186104E8DAC1}"
|
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"AbsoluteMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\components\\item\\ItemPage.jsx||{14D17961-FE51-464D-9111-C4AF11D7D99A}",
|
"AbsoluteMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\components\\item\\ItemPage.jsx||{14D17961-FE51-464D-9111-C4AF11D7D99A}",
|
||||||
"RelativeMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|solutionrelative:src\\components\\item\\ItemPage.jsx||{14D17961-FE51-464D-9111-C4AF11D7D99A}"
|
"RelativeMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|solutionrelative:src\\components\\item\\ItemPage.jsx||{14D17961-FE51-464D-9111-C4AF11D7D99A}"
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"AbsoluteMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\api\\index.js||{14D17961-FE51-464D-9111-C4AF11D7D99A}",
|
||||||
|
"RelativeMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|solutionrelative:src\\api\\index.js||{14D17961-FE51-464D-9111-C4AF11D7D99A}"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"AbsoluteMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\components\\app-layout.jsx||{14D17961-FE51-464D-9111-C4AF11D7D99A}",
|
||||||
|
"RelativeMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|solutionrelative:src\\components\\app-layout.jsx||{14D17961-FE51-464D-9111-C4AF11D7D99A}"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"AbsoluteMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\main.jsx||{14D17961-FE51-464D-9111-C4AF11D7D99A}",
|
||||||
|
"RelativeMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|solutionrelative:src\\main.jsx||{14D17961-FE51-464D-9111-C4AF11D7D99A}"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"AbsoluteMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\App.jsx||{14D17961-FE51-464D-9111-C4AF11D7D99A}",
|
||||||
|
"RelativeMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|solutionrelative:src\\App.jsx||{14D17961-FE51-464D-9111-C4AF11D7D99A}"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"AbsoluteMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\components\\nav\\Navbar.jsx||{14D17961-FE51-464D-9111-C4AF11D7D99A}",
|
||||||
|
"RelativeMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|solutionrelative:src\\components\\nav\\Navbar.jsx||{14D17961-FE51-464D-9111-C4AF11D7D99A}"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"AbsoluteMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\api\\room.js||{14D17961-FE51-464D-9111-C4AF11D7D99A}",
|
||||||
|
"RelativeMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|solutionrelative:src\\api\\room.js||{14D17961-FE51-464D-9111-C4AF11D7D99A}"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"AbsoluteMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\pages\\test.jsx||{14D17961-FE51-464D-9111-C4AF11D7D99A}",
|
||||||
|
"RelativeMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|solutionrelative:src\\pages\\test.jsx||{14D17961-FE51-464D-9111-C4AF11D7D99A}"
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"AbsoluteMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\package.json||{90A6B3A7-C1A3-4009-A288-E2FF89E96FA0}",
|
"AbsoluteMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\package.json||{90A6B3A7-C1A3-4009-A288-E2FF89E96FA0}",
|
||||||
"RelativeMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|solutionrelative:package.json||{90A6B3A7-C1A3-4009-A288-E2FF89E96FA0}"
|
"RelativeMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|solutionrelative:package.json||{90A6B3A7-C1A3-4009-A288-E2FF89E96FA0}"
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"AbsoluteMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\vitest.config.js||{14D17961-FE51-464D-9111-C4AF11D7D99A}",
|
|
||||||
"RelativeMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|solutionrelative:vitest.config.js||{14D17961-FE51-464D-9111-C4AF11D7D99A}"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"AbsoluteMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\vite.config.js||{14D17961-FE51-464D-9111-C4AF11D7D99A}",
|
|
||||||
"RelativeMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|solutionrelative:vite.config.js||{14D17961-FE51-464D-9111-C4AF11D7D99A}"
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"AbsoluteMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|C:\\Users\\Admin\\Source\\Repos\\2024-DEV-BUT3\\src\\hooks\\page-title-context.jsx||{14D17961-FE51-464D-9111-C4AF11D7D99A}",
|
"AbsoluteMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|C:\\Users\\Admin\\Source\\Repos\\2024-DEV-BUT3\\src\\hooks\\page-title-context.jsx||{14D17961-FE51-464D-9111-C4AF11D7D99A}",
|
||||||
"RelativeMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|solutionrelative:src\\hooks\\page-title-context.jsx||{14D17961-FE51-464D-9111-C4AF11D7D99A}"
|
"RelativeMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|solutionrelative:src\\hooks\\page-title-context.jsx||{14D17961-FE51-464D-9111-C4AF11D7D99A}"
|
||||||
@ -68,128 +64,89 @@
|
|||||||
"DockedWidth": 200,
|
"DockedWidth": 200,
|
||||||
"SelectedChildIndex": 3,
|
"SelectedChildIndex": 3,
|
||||||
"Children": [
|
"Children": [
|
||||||
{
|
|
||||||
"$type": "Document",
|
|
||||||
"DocumentIndex": 2,
|
|
||||||
"Title": "auth-context.jsx",
|
|
||||||
"DocumentMoniker": "C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\contexts\\auth-context.jsx",
|
|
||||||
"RelativeDocumentMoniker": "src\\contexts\\auth-context.jsx",
|
|
||||||
"ToolTip": "C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\contexts\\auth-context.jsx",
|
|
||||||
"RelativeToolTip": "src\\contexts\\auth-context.jsx",
|
|
||||||
"ViewState": "AQIAACoAAAAAAAAAAAAAADwAAAAEAAAA",
|
|
||||||
"Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.003663|",
|
|
||||||
"WhenOpened": "2024-05-07T09:38:35.04Z",
|
|
||||||
"EditorCaption": ""
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"$type": "Document",
|
|
||||||
"DocumentIndex": 3,
|
|
||||||
"Title": "authenticated.jsx",
|
|
||||||
"DocumentMoniker": "C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\components\\authenticated.jsx",
|
|
||||||
"RelativeDocumentMoniker": "src\\components\\authenticated.jsx",
|
|
||||||
"ToolTip": "C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\components\\authenticated.jsx",
|
|
||||||
"RelativeToolTip": "src\\components\\authenticated.jsx",
|
|
||||||
"ViewState": "AQIAAAAAAAAAAAAAAAAAAAAAAAAAAAAA",
|
|
||||||
"Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.003663|",
|
|
||||||
"WhenOpened": "2024-05-07T09:38:15.52Z",
|
|
||||||
"EditorCaption": ""
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"$type": "Document",
|
|
||||||
"DocumentIndex": 4,
|
|
||||||
"Title": "authentication.js",
|
|
||||||
"DocumentMoniker": "C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\api\\authentication.js",
|
|
||||||
"RelativeDocumentMoniker": "src\\api\\authentication.js",
|
|
||||||
"ToolTip": "C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\api\\authentication.js",
|
|
||||||
"RelativeToolTip": "src\\api\\authentication.js",
|
|
||||||
"ViewState": "AQIAAAAAAAAAAAAAAAAAAB0AAAACAAAA",
|
|
||||||
"Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.001646|",
|
|
||||||
"WhenOpened": "2024-05-07T09:34:33.928Z",
|
|
||||||
"EditorCaption": ""
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"$type": "Document",
|
|
||||||
"DocumentIndex": 0,
|
|
||||||
"Title": "Navbar.jsx",
|
|
||||||
"DocumentMoniker": "C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\components\\nav\\Navbar.jsx",
|
|
||||||
"RelativeDocumentMoniker": "src\\components\\nav\\Navbar.jsx",
|
|
||||||
"ToolTip": "C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\components\\nav\\Navbar.jsx",
|
|
||||||
"RelativeToolTip": "src\\components\\nav\\Navbar.jsx",
|
|
||||||
"ViewState": "AQIAAAsAAAAAAAAAAAAQwBIAAAAgAAAA",
|
|
||||||
"Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.003663|",
|
|
||||||
"WhenOpened": "2024-05-06T21:42:24.983Z",
|
|
||||||
"EditorCaption": ""
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"$type": "Document",
|
|
||||||
"DocumentIndex": 1,
|
|
||||||
"Title": "app-layout.jsx",
|
|
||||||
"DocumentMoniker": "C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\components\\app-layout.jsx",
|
|
||||||
"RelativeDocumentMoniker": "src\\components\\app-layout.jsx",
|
|
||||||
"ToolTip": "C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\components\\app-layout.jsx",
|
|
||||||
"RelativeToolTip": "src\\components\\app-layout.jsx",
|
|
||||||
"ViewState": "AQIAAAAAAAAAAAAAAAAAABAAAAAUAAAA",
|
|
||||||
"Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.003663|",
|
|
||||||
"WhenOpened": "2024-05-07T08:58:37.766Z",
|
|
||||||
"EditorCaption": ""
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"$type": "Bookmark",
|
"$type": "Bookmark",
|
||||||
"Name": "ST:1:0:{d212f56b-c48a-434c-a121-1c5d80b59b9f}"
|
"Name": "ST:1:0:{d212f56b-c48a-434c-a121-1c5d80b59b9f}"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"$type": "Document",
|
"$type": "Document",
|
||||||
"DocumentIndex": 8,
|
"DocumentIndex": 1,
|
||||||
"Title": "applicationhost.config",
|
"Title": "RoomItemsList.jsx",
|
||||||
"DocumentMoniker": "C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\.vs\\2024-DEV-BUT3\\config\\applicationhost.config",
|
"DocumentMoniker": "C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\components\\item\\RoomItemsList.jsx",
|
||||||
"RelativeDocumentMoniker": ".vs\\2024-DEV-BUT3\\config\\applicationhost.config",
|
"RelativeDocumentMoniker": "src\\components\\item\\RoomItemsList.jsx",
|
||||||
"ToolTip": "C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\.vs\\2024-DEV-BUT3\\config\\applicationhost.config",
|
"ToolTip": "C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\components\\item\\RoomItemsList.jsx",
|
||||||
"RelativeToolTip": ".vs\\2024-DEV-BUT3\\config\\applicationhost.config",
|
"RelativeToolTip": "src\\components\\item\\RoomItemsList.jsx",
|
||||||
"ViewState": "AQIAAAAAAAAAAAAAAAAAAAAAAAAAAAAA",
|
"ViewState": "AQIAAAAAAAAAAAAAAAAAABwAAABiAAAA",
|
||||||
"Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.000601|",
|
"Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.003663|",
|
||||||
"WhenOpened": "2024-05-06T23:30:27.125Z",
|
"WhenOpened": "2024-05-09T12:04:41.785Z",
|
||||||
"EditorCaption": ""
|
"EditorCaption": ""
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"$type": "Document",
|
"$type": "Document",
|
||||||
"DocumentIndex": 11,
|
"DocumentIndex": 4,
|
||||||
"Title": "vitest.config.js",
|
"Title": "index.js",
|
||||||
"DocumentMoniker": "C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\vitest.config.js",
|
"DocumentMoniker": "C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\api\\index.js",
|
||||||
"RelativeDocumentMoniker": "vitest.config.js",
|
"RelativeDocumentMoniker": "src\\api\\index.js",
|
||||||
"ToolTip": "C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\vitest.config.js",
|
"ToolTip": "C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\api\\index.js",
|
||||||
"RelativeToolTip": "vitest.config.js",
|
"RelativeToolTip": "src\\api\\index.js",
|
||||||
"ViewState": "AQIAAAAAAAAAAAAAAAAAAAAAAAAAAAAA",
|
"ViewState": "AQIAAAAAAAAAAAAAAAAAAAIAAAAeAAAA",
|
||||||
"Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.001646|",
|
"Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.001646|",
|
||||||
"WhenOpened": "2024-05-06T23:20:08.112Z"
|
"WhenOpened": "2024-05-09T12:03:27.48Z",
|
||||||
|
"EditorCaption": ""
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"$type": "Document",
|
"$type": "Document",
|
||||||
"DocumentIndex": 12,
|
"DocumentIndex": 0,
|
||||||
"Title": "vite.config.js",
|
"Title": "image-request.js",
|
||||||
"DocumentMoniker": "C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\vite.config.js",
|
"DocumentMoniker": "C:\\Users\\Admin\\Source\\Repos\\2024-DEV-BUT3\\src\\api\\image-request.js",
|
||||||
"RelativeDocumentMoniker": "vite.config.js",
|
"RelativeDocumentMoniker": "src\\api\\image-request.js",
|
||||||
"ToolTip": "C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\vite.config.js",
|
"ToolTip": "C:\\Users\\Admin\\Source\\Repos\\2024-DEV-BUT3\\src\\api\\image-request.js",
|
||||||
"RelativeToolTip": "vite.config.js",
|
"RelativeToolTip": "src\\api\\image-request.js",
|
||||||
"ViewState": "AQIAAAAAAAAAAAAAAAAAAAAAAAAAAAAA",
|
"ViewState": "AQIAAAAAAAAAAAAAAAAAABEAAAAAAAAA",
|
||||||
"Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.001646|",
|
"Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.001646|",
|
||||||
"WhenOpened": "2024-05-06T23:20:02.873Z"
|
"WhenOpened": "2024-05-09T11:59:29.915Z",
|
||||||
|
"EditorCaption": ""
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"$type": "Document",
|
"$type": "Document",
|
||||||
"DocumentIndex": 7,
|
"DocumentIndex": 5,
|
||||||
|
"Title": "app-layout.jsx",
|
||||||
|
"DocumentMoniker": "C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\components\\app-layout.jsx",
|
||||||
|
"RelativeDocumentMoniker": "src\\components\\app-layout.jsx",
|
||||||
|
"ToolTip": "C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\components\\app-layout.jsx",
|
||||||
|
"RelativeToolTip": "src\\components\\app-layout.jsx",
|
||||||
|
"ViewState": "AQIAAAAAAAAAAAAAAAAAACYAAAAcAAAA",
|
||||||
|
"Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.003663|",
|
||||||
|
"WhenOpened": "2024-05-07T10:59:39.423Z",
|
||||||
|
"EditorCaption": ""
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"$type": "Document",
|
||||||
|
"DocumentIndex": 8,
|
||||||
|
"Title": "Navbar.jsx",
|
||||||
|
"DocumentMoniker": "C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\components\\nav\\Navbar.jsx",
|
||||||
|
"RelativeDocumentMoniker": "src\\components\\nav\\Navbar.jsx",
|
||||||
|
"ToolTip": "C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\components\\nav\\Navbar.jsx",
|
||||||
|
"RelativeToolTip": "src\\components\\nav\\Navbar.jsx",
|
||||||
|
"ViewState": "AQIAADUAAAAAAAAAAAAQwFAAAAAVAAAA",
|
||||||
|
"Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.003663|",
|
||||||
|
"WhenOpened": "2024-05-07T10:56:14.054Z"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"$type": "Document",
|
||||||
|
"DocumentIndex": 9,
|
||||||
"Title": "room.js",
|
"Title": "room.js",
|
||||||
"DocumentMoniker": "C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\api\\room.js",
|
"DocumentMoniker": "C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\api\\room.js",
|
||||||
"RelativeDocumentMoniker": "src\\api\\room.js",
|
"RelativeDocumentMoniker": "src\\api\\room.js",
|
||||||
"ToolTip": "C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\api\\room.js",
|
"ToolTip": "C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\api\\room.js",
|
||||||
"RelativeToolTip": "src\\api\\room.js",
|
"RelativeToolTip": "src\\api\\room.js",
|
||||||
"ViewState": "AQIAAAAAAAAAAAAAAAAAAA4AAAAAAAAA",
|
"ViewState": "AQIAAAAAAAAAAAAAAAAAAAkAAAASAAAA",
|
||||||
"Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.001646|",
|
"Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.001646|",
|
||||||
"WhenOpened": "2024-05-06T22:06:47.739Z",
|
"WhenOpened": "2024-05-06T22:06:47.739Z"
|
||||||
"EditorCaption": ""
|
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"$type": "Document",
|
"$type": "Document",
|
||||||
"DocumentIndex": 6,
|
"DocumentIndex": 10,
|
||||||
"Title": "test.jsx",
|
"Title": "test.jsx",
|
||||||
"DocumentMoniker": "C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\pages\\test.jsx",
|
"DocumentMoniker": "C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\pages\\test.jsx",
|
||||||
"RelativeDocumentMoniker": "src\\pages\\test.jsx",
|
"RelativeDocumentMoniker": "src\\pages\\test.jsx",
|
||||||
@ -197,25 +154,48 @@
|
|||||||
"RelativeToolTip": "src\\pages\\test.jsx",
|
"RelativeToolTip": "src\\pages\\test.jsx",
|
||||||
"ViewState": "AQIAAAAAAAAAAAAAAAAAABMAAAACAAAA",
|
"ViewState": "AQIAAAAAAAAAAAAAAAAAABMAAAACAAAA",
|
||||||
"Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.003663|",
|
"Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.003663|",
|
||||||
"WhenOpened": "2024-05-06T18:36:04.359Z",
|
"WhenOpened": "2024-05-06T18:36:04.359Z"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"$type": "Document",
|
||||||
|
"DocumentIndex": 3,
|
||||||
|
"Title": "ItemPage.jsx",
|
||||||
|
"DocumentMoniker": "C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\components\\item\\ItemPage.jsx",
|
||||||
|
"RelativeDocumentMoniker": "src\\components\\item\\ItemPage.jsx",
|
||||||
|
"ToolTip": "C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\components\\item\\ItemPage.jsx",
|
||||||
|
"RelativeToolTip": "src\\components\\item\\ItemPage.jsx",
|
||||||
|
"ViewState": "AQIAABIAAAAAAAAAAAAAACkAAAAXAAAA",
|
||||||
|
"Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.003663|",
|
||||||
|
"WhenOpened": "2024-05-06T18:36:16.712Z",
|
||||||
"EditorCaption": ""
|
"EditorCaption": ""
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"$type": "Document",
|
"$type": "Document",
|
||||||
"DocumentIndex": 5,
|
"DocumentIndex": 6,
|
||||||
|
"Title": "main.jsx",
|
||||||
|
"DocumentMoniker": "C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\main.jsx",
|
||||||
|
"RelativeDocumentMoniker": "src\\main.jsx",
|
||||||
|
"ToolTip": "C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\main.jsx",
|
||||||
|
"RelativeToolTip": "src\\main.jsx",
|
||||||
|
"ViewState": "AQIAAAAAAAAAAAAAAAAAAAwAAAAAAAAA",
|
||||||
|
"Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.003663|",
|
||||||
|
"WhenOpened": "2024-05-07T11:03:34.632Z"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"$type": "Document",
|
||||||
|
"DocumentIndex": 7,
|
||||||
"Title": "App.jsx",
|
"Title": "App.jsx",
|
||||||
"DocumentMoniker": "C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\App.jsx",
|
"DocumentMoniker": "C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\App.jsx",
|
||||||
"RelativeDocumentMoniker": "src\\App.jsx",
|
"RelativeDocumentMoniker": "src\\App.jsx",
|
||||||
"ToolTip": "C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\App.jsx",
|
"ToolTip": "C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\App.jsx",
|
||||||
"RelativeToolTip": "src\\App.jsx",
|
"RelativeToolTip": "src\\App.jsx",
|
||||||
"ViewState": "AQIAAAAAAAAAAAAAAAAAABEAAAAAAAAA",
|
"ViewState": "AQIAAAAAAAAAAAAAAAAAAA4AAAAAAAAA",
|
||||||
"Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.003663|",
|
"Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.003663|",
|
||||||
"WhenOpened": "2024-05-06T16:40:31.952Z",
|
"WhenOpened": "2024-05-06T16:40:31.952Z"
|
||||||
"EditorCaption": ""
|
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"$type": "Document",
|
"$type": "Document",
|
||||||
"DocumentIndex": 10,
|
"DocumentIndex": 11,
|
||||||
"Title": "package.json",
|
"Title": "package.json",
|
||||||
"DocumentMoniker": "C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\package.json",
|
"DocumentMoniker": "C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\package.json",
|
||||||
"RelativeDocumentMoniker": "package.json",
|
"RelativeDocumentMoniker": "package.json",
|
||||||
@ -227,7 +207,7 @@
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
"$type": "Document",
|
"$type": "Document",
|
||||||
"DocumentIndex": 13,
|
"DocumentIndex": 12,
|
||||||
"Title": "page-title-context.jsx",
|
"Title": "page-title-context.jsx",
|
||||||
"DocumentMoniker": "C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\hooks\\page-title-context.jsx",
|
"DocumentMoniker": "C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\hooks\\page-title-context.jsx",
|
||||||
"RelativeDocumentMoniker": "src\\hooks\\page-title-context.jsx",
|
"RelativeDocumentMoniker": "src\\hooks\\page-title-context.jsx",
|
||||||
@ -236,18 +216,25 @@
|
|||||||
"ViewState": "AQIAAAAAAAAAAAAAAAAAAAgAAAAMAAAA",
|
"ViewState": "AQIAAAAAAAAAAAAAAAAAAAgAAAAMAAAA",
|
||||||
"Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.003663|",
|
"Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.003663|",
|
||||||
"WhenOpened": "2024-05-06T19:10:02.382Z"
|
"WhenOpened": "2024-05-06T19:10:02.382Z"
|
||||||
|
}
|
||||||
|
]
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"DockedWidth": 200,
|
||||||
|
"SelectedChildIndex": 0,
|
||||||
|
"Children": [
|
||||||
{
|
{
|
||||||
"$type": "Document",
|
"$type": "Document",
|
||||||
"DocumentIndex": 9,
|
"DocumentIndex": 2,
|
||||||
"Title": "ItemPage.jsx",
|
"Title": "ItemBox.jsx",
|
||||||
"DocumentMoniker": "C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\components\\item\\ItemPage.jsx",
|
"DocumentMoniker": "C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\components\\item\\ItemBox.jsx",
|
||||||
"RelativeDocumentMoniker": "src\\components\\item\\ItemPage.jsx",
|
"RelativeDocumentMoniker": "src\\components\\item\\ItemBox.jsx",
|
||||||
"ToolTip": "C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\components\\item\\ItemPage.jsx",
|
"ToolTip": "C:\\Users\\Admin\\source\\repos\\2024-DEV-BUT3\\src\\components\\item\\ItemBox.jsx",
|
||||||
"RelativeToolTip": "src\\components\\item\\ItemPage.jsx",
|
"RelativeToolTip": "src\\components\\item\\ItemBox.jsx",
|
||||||
"ViewState": "AQIAAAAAAAAAAAAAAAAAACQAAAApAAAA",
|
"ViewState": "AQIAAAAAAAAAAAAAAAAAABwAAAA7AAAA",
|
||||||
"Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.003663|",
|
"Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.003663|",
|
||||||
"WhenOpened": "2024-05-06T18:36:16.712Z"
|
"WhenOpened": "2024-05-09T12:03:58.04Z",
|
||||||
|
"EditorCaption": ""
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
@ -1,8 +1,16 @@
|
|||||||
{
|
{
|
||||||
"ExpandedNodes": [
|
"ExpandedNodes": [
|
||||||
"",
|
"",
|
||||||
"\\src\\assets\\styles"
|
"\\src",
|
||||||
|
"\\src\\api",
|
||||||
|
"\\src\\components",
|
||||||
|
"\\src\\components\\form",
|
||||||
|
"\\src\\components\\item",
|
||||||
|
"\\src\\components\\nav",
|
||||||
|
"\\src\\contexts",
|
||||||
|
"\\src\\pages",
|
||||||
|
"\\src\\pages\\authenticated"
|
||||||
],
|
],
|
||||||
"SelectedNode": "\\package.json",
|
"SelectedNode": "\\src\\main.jsx",
|
||||||
"PreviewInSolutionExplorer": false
|
"PreviewInSolutionExplorer": false
|
||||||
}
|
}
|
BIN
.vs/slnx.sqlite
BIN
.vs/slnx.sqlite
Binary file not shown.
24
src/api/image-request.js
Normal file
24
src/api/image-request.js
Normal file
@ -0,0 +1,24 @@
|
|||||||
|
const API_KEY = 'AIzaSyA_w7wmOAibpiDF5H3mXuL9AhcN-KVkFg4';
|
||||||
|
const CSE_ID = '611cd62b5f315445c';
|
||||||
|
|
||||||
|
export async function searchAndResizeImage(query) {
|
||||||
|
try {
|
||||||
|
const response = await fetch(`https://www.googleapis.com/customsearch/v1?key=${API_KEY}&cx=${CSE_ID}&q=${query}&searchType=image&num=1&imgSize=medium`);
|
||||||
|
const data = await response.json();
|
||||||
|
|
||||||
|
if (data.items && data.items.length > 0) {
|
||||||
|
const imageUrl = data.items[0].link;
|
||||||
|
console.log('Image URL:', imageUrl);
|
||||||
|
return imageUrl;
|
||||||
|
} else {
|
||||||
|
console.error('No image found.');
|
||||||
|
return "";
|
||||||
|
}
|
||||||
|
} catch (error) {
|
||||||
|
console.error('Error fetching image:', error);
|
||||||
|
return "";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -1,2 +1,3 @@
|
|||||||
export * from './authentication'
|
export * from './authentication'
|
||||||
export * from './user'
|
export * from './user'
|
||||||
|
export * from './image-request'
|
||||||
|
@ -1,12 +1,43 @@
|
|||||||
import React from 'react';
|
import React, { useEffect, useState } from 'react';
|
||||||
|
import { searchAndResizeImage } from '../../api/image-request'
|
||||||
|
|
||||||
// Composant Image atomique
|
|
||||||
const Image = ({ src, alt }) => {
|
// Composant Image
|
||||||
return <img src={src} alt={alt} style={{ display: 'block', margin: 'auto' }} />;
|
const Image = ({ src, alt, request, _id }) => {
|
||||||
|
const [cacheUrl, setCacheUrl] = useState(null);
|
||||||
|
|
||||||
|
useEffect(() => {
|
||||||
|
const fetchData = async () => {
|
||||||
|
let cachedUrl = localStorage.getItem(_id);
|
||||||
|
if (!cachedUrl) {
|
||||||
|
try {
|
||||||
|
cachedUrl = await searchAndResizeImage(request);
|
||||||
|
localStorage.setItem(_id, cachedUrl);
|
||||||
|
console.log("Mise en cache de l'image avec l'ID : " + _id);
|
||||||
|
} catch (error) {
|
||||||
|
console.error("Erreur lors de la récupération de l'image : ", error);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
setCacheUrl(cachedUrl);
|
||||||
};
|
};
|
||||||
|
|
||||||
// Composant Description atomique
|
fetchData();
|
||||||
|
}, [request, _id]);
|
||||||
|
|
||||||
|
if (src) {
|
||||||
|
return <img src={src} alt={alt} style={{ display: 'block', margin: 'auto' }} width='150px' height='150px' />;
|
||||||
|
} else if (cacheUrl) {
|
||||||
|
return <img src={cacheUrl} alt={alt} style={{ display: 'block', margin: 'auto' }} width='150px' height='150px' />;
|
||||||
|
} else {
|
||||||
|
return <img src={"https://media.discordapp.net/attachments/1164176196930637956/1167746303820840990/IMG_20231028_104620.jpg?ex=663ddefe&is=663c8d7e&hm=0985ce123fd1751f65388f7fefde5db6ce817e514e30f1d3c81eb28b15e78453&=&"} alt={alt} style={{ display: 'block', margin: 'auto' }} width='150px' height='150px' />;
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
// Composant Description
|
||||||
const Description = ({ title, children }) => {
|
const Description = ({ title, children }) => {
|
||||||
|
if (title.length >= 30) {
|
||||||
|
title = title.slice(0, 22 - 3) + '...';
|
||||||
|
}
|
||||||
return (
|
return (
|
||||||
<div className="description">
|
<div className="description">
|
||||||
<h2>{title}</h2>
|
<h2>{title}</h2>
|
||||||
@ -15,8 +46,9 @@ const Description = ({ title, children }) => {
|
|||||||
);
|
);
|
||||||
};
|
};
|
||||||
|
|
||||||
// Composant Caractéristique atomique
|
// Composant Caractéristique
|
||||||
const Characteristic = ({ label, value }) => {
|
const Characteristic = ({ label, value }) => {
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div className="characteristic">
|
<div className="characteristic">
|
||||||
<strong>{label}:</strong> {value}
|
<strong>{label}:</strong> {value}
|
||||||
@ -24,16 +56,23 @@ const Characteristic = ({ label, value }) => {
|
|||||||
);
|
);
|
||||||
};
|
};
|
||||||
|
|
||||||
// Composant Détails du Produit (combinaison atomique)
|
// Composant Détails du Produit
|
||||||
export const ItemBox = ({ imageUrl, model, brand, purchaseDate, price, onEdit }) => {
|
export const ItemBox = ({ model, brand, purchaseDate, price, onEdit, _id }) => {
|
||||||
|
let productname = brand + " " + model;
|
||||||
|
let formatedPrice = price + "€";
|
||||||
|
let formatedDate = new Date(purchaseDate).toLocaleDateString('fr-FR');
|
||||||
|
|
||||||
|
let request = brand + " " + model
|
||||||
|
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div className="product-details" >
|
<div className="product-details" >
|
||||||
<Image src={imageUrl} alt="Product" />
|
<Description title={productname} >
|
||||||
<Description title="Product Information">
|
<Image request={request} _id={_id} alt="Product" />
|
||||||
<Characteristic label="Model" value={model} />
|
<Characteristic label="Model" value={model} />
|
||||||
<Characteristic label="Brand" value={brand} />
|
<Characteristic label="Brand" value={brand} />
|
||||||
<Characteristic label="Purchase Date" value={purchaseDate} />
|
<Characteristic label="Purchase Date" value={formatedDate} />
|
||||||
<Characteristic label="Price" value={price} />
|
<Characteristic label="Price" value={formatedPrice} />
|
||||||
</Description>
|
</Description>
|
||||||
<button onClick={onEdit}>Edit</button>
|
<button onClick={onEdit}>Edit</button>
|
||||||
</div>
|
</div>
|
||||||
|
@ -3,6 +3,7 @@ import axios from 'axios'; // Assurez-vous que le chemin d'importation soit corr
|
|||||||
import { ItemBox } from './ItemBox';
|
import { ItemBox } from './ItemBox';
|
||||||
import { Space, DatePicker, Row, Col, Select, Input, InputNumber } from 'antd';
|
import { Space, DatePicker, Row, Col, Select, Input, InputNumber } from 'antd';
|
||||||
|
|
||||||
|
|
||||||
const { RangePicker } = DatePicker;
|
const { RangePicker } = DatePicker;
|
||||||
const { Option } = Select;
|
const { Option } = Select;
|
||||||
|
|
||||||
@ -37,8 +38,20 @@ export const ItemPage = () => {
|
|||||||
const response = await axios.get(
|
const response = await axios.get(
|
||||||
`${import.meta.env.VITE_API_URL}/item`,
|
`${import.meta.env.VITE_API_URL}/item`,
|
||||||
);
|
);
|
||||||
|
|
||||||
|
//await response.data.forEach(async (item) => {
|
||||||
|
// let cacheUrl = localStorage.getItem(item._id);
|
||||||
|
// if (cacheUrl == null || cacheUrl == "") {
|
||||||
|
// let request = item.brand + " " + item.model
|
||||||
|
// cacheUrl = await searchAndResizeImage(request)
|
||||||
|
// await localStorage.setItem(item._id, cacheUrl)
|
||||||
|
// console.log("mise en cache "+ item.imageUrl)
|
||||||
|
// }
|
||||||
|
// item.imageUrl = cacheUrl;
|
||||||
|
//})
|
||||||
setItems(response.data);
|
setItems(response.data);
|
||||||
} catch (error) {
|
}
|
||||||
|
catch (error) {
|
||||||
console.error(error);
|
console.error(error);
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
@ -144,3 +157,6 @@ export const ItemPage = () => {
|
|||||||
</div>
|
</div>
|
||||||
);
|
);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -26,7 +26,6 @@ export const RoomItemsList = () => {
|
|||||||
console.error(error);
|
console.error(error);
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
fetchRoomsAndItems();
|
fetchRoomsAndItems();
|
||||||
}, []);
|
}, []);
|
||||||
|
|
||||||
|
@ -12,11 +12,11 @@ setupAxios();
|
|||||||
|
|
||||||
|
|
||||||
ReactDOM.createRoot(document.getElementById("root")).render(
|
ReactDOM.createRoot(document.getElementById("root")).render(
|
||||||
<React.StrictMode>
|
//<React.StrictMode>
|
||||||
<BrowserRouter>
|
<BrowserRouter>
|
||||||
<CookiesProvider>
|
<CookiesProvider>
|
||||||
<App/>
|
<App/>
|
||||||
</CookiesProvider>
|
</CookiesProvider>
|
||||||
</BrowserRouter>
|
</BrowserRouter>
|
||||||
</React.StrictMode>,
|
//</React.StrictMode>,
|
||||||
);
|
);
|
||||||
|
25
src/pages/rooms-stats.jsx
Normal file
25
src/pages/rooms-stats.jsx
Normal file
@ -0,0 +1,25 @@
|
|||||||
|
import React, { useEffect } from 'react';
|
||||||
|
|
||||||
|
import { useAuth } from "../hooks";
|
||||||
|
import { ItemPage } from "../components/item/ItemPage";
|
||||||
|
import { usePageTitle } from '../hooks/page-title-context';
|
||||||
|
|
||||||
|
export const RoomsStats = () => {
|
||||||
|
const { user } = useAuth();
|
||||||
|
const { setPageTitle } = usePageTitle();
|
||||||
|
|
||||||
|
|
||||||
|
// Mettre à jour le titre de la page dans le contexte
|
||||||
|
useEffect(() => {
|
||||||
|
setPageTitle("Toutes les rooms :");
|
||||||
|
}, [setPageTitle]);
|
||||||
|
|
||||||
|
useEffect(() => {
|
||||||
|
setPageTitle("Toutes les rooms :");
|
||||||
|
}, [setPageTitle]);
|
||||||
|
return (
|
||||||
|
<div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
);
|
||||||
|
};
|
Loading…
Reference in New Issue
Block a user