-
Notifications
You must be signed in to change notification settings - Fork 44
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'main' into CHARTS-10652
- Loading branch information
Showing
66 changed files
with
914 additions
and
150 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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
export const enum CollectionContentTableQa { | ||
Table = 'coll-content-table', | ||
CollectionLinkRow = 'coll-content-table-coll-link-row', | ||
WorkbookLinkRow = 'coll-content-table-workbook-link-row', | ||
CollectionTitleCell = 'coll-content-table-coll-title-cell', | ||
} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,15 @@ | ||
export {VisualizationsQa} from './visualization'; | ||
export * from './chart'; | ||
export * from './collections'; | ||
export * from './components'; | ||
export * from './connections'; | ||
export * from './chart'; | ||
export * from './editor'; | ||
export * from './datasets'; | ||
export * from './control'; | ||
export * from './dash'; | ||
export * from './datasets'; | ||
export * from './dl-navigation'; | ||
export * from './wizard'; | ||
export * from './control'; | ||
export * from './ql'; | ||
export * from './editor'; | ||
export * from './field-editor'; | ||
export {VisualizationsQa} from './visualization'; | ||
export * from './uikit'; | ||
export * from './ql'; | ||
export * from './settings'; | ||
export * from './uikit'; | ||
export * from './wizard'; |
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 |
---|---|---|
@@ -1,5 +1,6 @@ | ||
export enum WorkbookPage { | ||
export enum WorkbookPageQa { | ||
ListItem = 'workbook-page-list-item', | ||
MenuDropDownBtn = 'workbook-page-list-item-menu-btn', | ||
MenuItemDuplicate = 'workbook-page-list-item-menu-item-duplicate', | ||
Filters = 'workbook-page-filters', | ||
} |
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
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
43 changes: 43 additions & 0 deletions
43
src/ui/components/DashKit/plugins/Title/AnchorLink/AnchorLink.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,43 @@ | ||
import React from 'react'; | ||
|
||
import type {PluginTitleProps} from '@gravity-ui/dashkit'; | ||
import block from 'bem-cn-lite'; | ||
import {useLocation} from 'react-router'; | ||
import {Link} from 'react-router-dom'; | ||
import {DL} from 'ui/constants'; | ||
|
||
import '../Title.scss'; | ||
|
||
const b = block('dashkit-plugin-title-container'); | ||
|
||
interface AnchorLinkProps { | ||
size: PluginTitleProps['data']['size']; | ||
to: string; | ||
show?: boolean; | ||
absolute?: boolean; | ||
top: number; | ||
} | ||
|
||
export const AnchorLink = ({size, to, show, absolute, top}: AnchorLinkProps) => { | ||
const location = useLocation(); | ||
const hash = `#${encodeURIComponent(to)}`; | ||
|
||
const link = {...location, hash}; | ||
|
||
if (DL.IS_MOBILE || !show) { | ||
return null; | ||
} | ||
|
||
return ( | ||
<Link | ||
className={b('anchor', { | ||
size, | ||
absolute, | ||
})} | ||
to={link} | ||
style={{top}} | ||
> | ||
# | ||
</Link> | ||
); | ||
}; |
Oops, something went wrong.