-
Notifications
You must be signed in to change notification settings - Fork 31
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1844 from SanjalKatiyar/add_s3_tabs_skeleton
Add S3 navigation skeleton
- Loading branch information
Showing
9 changed files
with
105 additions
and
29 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
24 changes: 24 additions & 0 deletions
24
packages/odf/components/s3-browser/bucket-overview/ManagementNav.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
import * as React from 'react'; | ||
import { useCustomTranslation } from '@odf/shared/useCustomTranslationHook'; | ||
import Tabs, { TabPage } from '@odf/shared/utils/Tabs'; | ||
|
||
const LifecycleRules = () => <>LIFECYCLE RULES</>; | ||
|
||
const ManagementNav = () => { | ||
const { t } = useCustomTranslation(); | ||
|
||
const pages: TabPage[] = React.useMemo( | ||
() => [ | ||
{ | ||
href: 'lifecycle', | ||
title: t('Lifecycle rules'), | ||
component: LifecycleRules, | ||
}, | ||
], | ||
[t] | ||
); | ||
|
||
return <Tabs id="s3-management-tab" tabs={pages} basePath="management" />; | ||
}; | ||
|
||
export default ManagementNav; |
30 changes: 30 additions & 0 deletions
30
packages/odf/components/s3-browser/bucket-overview/PermissionsNav.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
import * as React from 'react'; | ||
import { useCustomTranslation } from '@odf/shared/useCustomTranslationHook'; | ||
import Tabs, { TabPage } from '@odf/shared/utils/Tabs'; | ||
|
||
const BucketPolicy = () => <>BUCKET POLICY</>; | ||
const Cors = () => <>CORS</>; | ||
|
||
const PermissionsNav = () => { | ||
const { t } = useCustomTranslation(); | ||
|
||
const pages: TabPage[] = React.useMemo( | ||
() => [ | ||
{ | ||
href: 'policy', | ||
title: t('Bucket policy'), | ||
component: BucketPolicy, | ||
}, | ||
{ | ||
href: 'cors', | ||
title: t('CORS'), | ||
component: Cors, | ||
}, | ||
], | ||
[t] | ||
); | ||
|
||
return <Tabs id="s3-permissions-tab" tabs={pages} basePath="permissions" />; | ||
}; | ||
|
||
export default PermissionsNav; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters