@hh.ru/magritte-ui-link 4.3.11 → 4.3.13
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/Link.d.ts +4 -3
- package/Link.js +1 -1
- package/Link.js.map +1 -1
- package/VerticallyCenteredIcon.js +1 -1
- package/index.css +530 -530
- package/package.json +7 -7
- package/types.d.ts +2 -5
- package/types.js.map +1 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@hh.ru/magritte-ui-link",
|
|
3
|
-
"version": "4.3.
|
|
3
|
+
"version": "4.3.13",
|
|
4
4
|
"main": "index.js",
|
|
5
5
|
"types": "index.d.ts",
|
|
6
6
|
"sideEffects": [
|
|
@@ -22,11 +22,11 @@
|
|
|
22
22
|
"dependencies": {
|
|
23
23
|
"@hh.ru/magritte-common-keyboard": "4.0.2",
|
|
24
24
|
"@hh.ru/magritte-common-use-disabled": "1.0.9",
|
|
25
|
-
"@hh.ru/magritte-design-tokens": "19.1.
|
|
26
|
-
"@hh.ru/magritte-types": "
|
|
27
|
-
"@hh.ru/magritte-ui-icon": "7.9.
|
|
28
|
-
"@hh.ru/magritte-ui-theme-provider": "1.1.
|
|
29
|
-
"@hh.ru/magritte-ui-typography": "3.0.
|
|
25
|
+
"@hh.ru/magritte-design-tokens": "19.1.2",
|
|
26
|
+
"@hh.ru/magritte-types": "5.0.0",
|
|
27
|
+
"@hh.ru/magritte-ui-icon": "7.9.3",
|
|
28
|
+
"@hh.ru/magritte-ui-theme-provider": "1.1.31",
|
|
29
|
+
"@hh.ru/magritte-ui-typography": "3.0.19"
|
|
30
30
|
},
|
|
31
31
|
"peerDependencies": {
|
|
32
32
|
"classnames": ">=2.3.2",
|
|
@@ -35,5 +35,5 @@
|
|
|
35
35
|
"publishConfig": {
|
|
36
36
|
"access": "public"
|
|
37
37
|
},
|
|
38
|
-
"gitHead": "
|
|
38
|
+
"gitHead": "34aa8b63db1d1af2d969ef765d060ac8f59cd9ff"
|
|
39
39
|
}
|
package/types.d.ts
CHANGED
|
@@ -1,9 +1,8 @@
|
|
|
1
|
-
import { ReactElement } from 'react';
|
|
2
|
-
import { ComponentWithCustomElement, ForwardRefRenderFuncWithCustomElement } from '@hh.ru/magritte-types';
|
|
3
1
|
import { type IconWrapperComponentSize16, type IconWrapperComponentSize24 } from '@hh.ru/magritte-ui-icon/src/iconTypes';
|
|
4
2
|
import { TextTypography, HeadersTypography } from '@hh.ru/magritte-ui-typography';
|
|
5
3
|
export type LinkStyle = 'neutral' | 'accent' | 'positive' | 'negative' | 'warning' | 'contrast';
|
|
6
4
|
export interface LinkProps {
|
|
5
|
+
children?: React.ReactNode;
|
|
7
6
|
/** Кастомный элемент для линка */
|
|
8
7
|
Element: 'a' | 'button';
|
|
9
8
|
/** Расположение ссылки в тексте */
|
|
@@ -29,6 +28,4 @@ export interface LinkProps {
|
|
|
29
28
|
/** Включает подчеркивание */
|
|
30
29
|
underlined?: boolean;
|
|
31
30
|
}
|
|
32
|
-
export
|
|
33
|
-
export type LinkWithCustomElement = ComponentWithCustomElement<LinkProps, 'a'>;
|
|
34
|
-
export declare const isLinkComponent: (component: ReactElement) => component is ReactElement<LinkProps, string | import("react").JSXElementConstructor<any>>;
|
|
31
|
+
export declare const isLinkComponent: (component: React.ReactElement) => component is React.ReactElement<LinkProps>;
|
package/types.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.js","sources":["../src/types.ts"],"sourcesContent":["import { isValidElement
|
|
1
|
+
{"version":3,"file":"types.js","sources":["../src/types.ts"],"sourcesContent":["import { isValidElement } from 'react';\n\nimport {\n type IconWrapperComponentSize16,\n type IconWrapperComponentSize24,\n} from '@hh.ru/magritte-ui-icon/src/iconTypes';\nimport { TextTypography, HeadersTypography } from '@hh.ru/magritte-ui-typography';\n\nexport type LinkStyle = 'neutral' | 'accent' | 'positive' | 'negative' | 'warning' | 'contrast';\n\nexport interface LinkProps {\n children?: React.ReactNode;\n /** Кастомный элемент для линка */\n Element: 'a' | 'button';\n /** Расположение ссылки в тексте */\n inline?: boolean;\n /** Стиль компонента в зависимости от назначения */\n style?: LinkStyle;\n /** Отображение иконки с левой стороны ссылки */\n iconLeft?: IconWrapperComponentSize16 | IconWrapperComponentSize24;\n /** Отображение иконки с правой стороны ссылки */\n iconRight?: IconWrapperComponentSize16 | IconWrapperComponentSize24;\n /** Ссылка перестает реагировать на любое взаимодействие */\n disabled?: boolean;\n /** Типография */\n typography?: TextTypography | HeadersTypography;\n /** Ссылка */\n href?: string;\n /** Кастомный data-qa для тестирования */\n 'data-qa'?: string;\n /** Вспомогательный лейбл для скринридеров */\n 'aria-label'?: string;\n /** Флаг включения visited состояния */\n enableVisited?: boolean;\n /** Включает подчеркивание */\n underlined?: boolean;\n}\n\nexport const isLinkComponent = (component: React.ReactElement): component is React.ReactElement<LinkProps> => {\n return isValidElement(component) && typeof component.type !== 'string' && 'isLink' in component?.type;\n};\n"],"names":[],"mappings":";;AAsCa,MAAA,eAAe,GAAG,CAAC,SAA6B,KAAgD;AACzG,IAAA,OAAO,cAAc,CAAC,SAAS,CAAC,IAAI,OAAO,SAAS,CAAC,IAAI,KAAK,QAAQ,IAAI,QAAQ,IAAI,SAAS,EAAE,IAAI,CAAC;AAC1G;;;;"}
|