/
linkClasses.ts
97 lines (92 loc) · 3 KB
/
linkClasses.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
import { generateUtilityClass, generateUtilityClasses } from '../className';
export interface LinkClasses {
/** Styles applied to the root element. */
root: string;
/** Styles applied to the root element if `color="primary"`. */
colorPrimary: string;
/** Styles applied to the root element if `color="neutral"`. */
colorNeutral: string;
/** Styles applied to the root element if `color="danger"`. */
colorDanger: string;
/** Styles applied to the root element if `color="info"`. */
colorInfo: string;
/** Styles applied to the root element if `color="success"`. */
colorSuccess: string;
/** Styles applied to the root element if `color="warning"`. */
colorWarning: string;
/** State class applied to the root element if `disabled={true}`. */
disabled: string;
/** State class applied to the root element if the link is keyboard focused. */
focusVisible: string;
/** Styles applied to the root element if `variant="plain"`. */
variantPlain: string;
/** Styles applied to the root element if `variant="outlined"`. */
variantOutlined: string;
/** Styles applied to the root element if `variant="soft"`. */
variantSoft: string;
/** Styles applied to the root element if `variant="solid"`. */
variantSolid: string;
/** Styles applied to the root element if `underline="none"`. */
underlineNone: string;
/** Styles applied to the root element if `underline="hover"`. */
underlineHover: string;
/** Styles applied to the root element if `underline="always"`. */
underlineAlways: string;
/** Styles applied to the root element if `level="h1"`. */
h1: string;
/** Styles applied to the root element if `level="h2"`. */
h2: string;
/** Styles applied to the root element if `level="h3"`. */
h3: string;
/** Styles applied to the root element if `level="h4"`. */
h4: string;
/** Styles applied to the root element if `level="h5"`. */
h5: string;
/** Styles applied to the root element if `level="h6"`. */
h6: string;
/** Styles applied to the root element if `level="body1"`. */
body1: string;
/** Styles applied to the root element if `level="body2"`. */
body2: string;
/** Styles applied to the root element if `level="body3"`. */
body3: string;
/** Styles applied to the startDecorator element */
startDecorator: string;
/** Styles applied to the endDecorator element */
endDecorator: string;
}
export type LinkClassKey = keyof LinkClasses;
export function getLinkUtilityClass(slot: string): string {
return generateUtilityClass('JoyLink', slot);
}
const linkClasses: LinkClasses = generateUtilityClasses('JoyLink', [
'root',
'disabled',
'focusVisible',
'colorPrimary',
'colorNeutral',
'colorDanger',
'colorInfo',
'colorSuccess',
'colorWarning',
'focusVisible',
'variantPlain',
'variantOutlined',
'variantSoft',
'variantSolid',
'underlineNone',
'underlineHover',
'underlineAlways',
'h1',
'h2',
'h3',
'h4',
'h5',
'h6',
'body1',
'body2',
'body3',
'startDecorator',
'endDecorator',
]);
export default linkClasses;