@primer/react 0.0.0-20260601133816 → 0.0.0-20260601173513
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/CHANGELOG.md +13 -23
- package/dist/ActionList/ActionList-2a35a40c.css +2 -0
- package/dist/ActionList/ActionList-2a35a40c.css.map +1 -0
- package/dist/ActionList/ActionList.module.css.js +2 -2
- package/dist/ActionList/Item.d.ts.map +1 -1
- package/dist/ActionList/Item.js +118 -125
- package/dist/ActionList/TrailingAction.d.ts.map +1 -1
- package/dist/ActionList/TrailingAction.js +0 -1
- package/dist/ActionList/Visuals.js +4 -6
- package/dist/Text/{Text-d649cda5.css → Text-ca7603b7.css} +2 -2
- package/dist/Text/Text-ca7603b7.css.map +1 -0
- package/dist/Text/Text.d.ts +0 -3
- package/dist/Text/Text.d.ts.map +1 -1
- package/dist/Text/Text.js +14 -20
- package/dist/Text/Text.module.css.js +1 -1
- package/dist/ThemeProvider.d.ts +0 -6
- package/dist/ThemeProvider.d.ts.map +1 -1
- package/dist/ThemeProvider.js +21 -38
- package/dist/Timeline/Timeline-ff81db92.css +2 -0
- package/dist/Timeline/Timeline-ff81db92.css.map +1 -0
- package/dist/Timeline/Timeline.d.ts +7 -7
- package/dist/Timeline/Timeline.d.ts.map +1 -1
- package/dist/Timeline/Timeline.js +6 -4
- package/dist/Timeline/Timeline.module.css.js +1 -1
- package/dist/TreeView/TreeView-0fe09f34.css +2 -0
- package/dist/TreeView/TreeView-0fe09f34.css.map +1 -0
- package/dist/TreeView/TreeView.d.ts.map +1 -1
- package/dist/TreeView/TreeView.js +8 -21
- package/dist/TreeView/TreeView.module.css.js +2 -2
- package/generated/components.json +0 -20
- package/package.json +1 -1
- package/dist/ActionList/ActionList-1940009e.css +0 -2
- package/dist/ActionList/ActionList-1940009e.css.map +0 -1
- package/dist/Text/Text-d649cda5.css.map +0 -1
- package/dist/Timeline/Timeline-0c88f21b.css +0 -2
- package/dist/Timeline/Timeline-0c88f21b.css.map +0 -1
- package/dist/TreeView/TreeView-1bf45a33.css +0 -2
- package/dist/TreeView/TreeView-1bf45a33.css.map +0 -1
|
@@ -139,7 +139,7 @@ const TrailingVisual = t0 => {
|
|
|
139
139
|
//
|
|
140
140
|
// This preserves the left alignment of item text.
|
|
141
141
|
const VisualOrIndicator = t0 => {
|
|
142
|
-
const $ = c(
|
|
142
|
+
const $ = c(5);
|
|
143
143
|
const {
|
|
144
144
|
children,
|
|
145
145
|
labelId,
|
|
@@ -157,10 +157,9 @@ const VisualOrIndicator = t0 => {
|
|
|
157
157
|
return children;
|
|
158
158
|
}
|
|
159
159
|
let t1;
|
|
160
|
-
if ($[0] !== VisualComponent || $[1] !== className || $[2] !== inactiveText || $[3] !== labelId
|
|
160
|
+
if ($[0] !== VisualComponent || $[1] !== className || $[2] !== inactiveText || $[3] !== labelId) {
|
|
161
161
|
t1 = inactiveText ? /*#__PURE__*/jsx("span", {
|
|
162
162
|
className: classes.InactiveButtonWrap,
|
|
163
|
-
"data-position": position,
|
|
164
163
|
children: /*#__PURE__*/jsx(Tooltip, {
|
|
165
164
|
text: inactiveText,
|
|
166
165
|
type: "description",
|
|
@@ -183,10 +182,9 @@ const VisualOrIndicator = t0 => {
|
|
|
183
182
|
$[1] = className;
|
|
184
183
|
$[2] = inactiveText;
|
|
185
184
|
$[3] = labelId;
|
|
186
|
-
$[4] =
|
|
187
|
-
$[5] = t1;
|
|
185
|
+
$[4] = t1;
|
|
188
186
|
} else {
|
|
189
|
-
t1 = $[
|
|
187
|
+
t1 = $[4];
|
|
190
188
|
}
|
|
191
189
|
return t1;
|
|
192
190
|
};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
.prc-Text-Text-9mHv3:where([data-size=small]){font-size:var(--text-body-size-small,.75rem);line-height:var(--text-body-lineHeight-small,1.625)}.prc-Text-Text-9mHv3:where([data-size=medium]){font-size:var(--text-body-size-medium,.875rem);line-height:var(--text-body-lineHeight-medium,1.5)}.prc-Text-Text-9mHv3:where([data-size=large]){font-size:var(--text-body-size-large,1rem);line-height:var(--text-body-lineHeight-large,1.5)}.prc-Text-Text-9mHv3:where([data-weight=light]){font-weight:var(--base-text-weight-light,300)}.prc-Text-Text-9mHv3:where([data-weight=normal]){font-weight:var(--base-text-weight-normal,400)}.prc-Text-Text-9mHv3:where([data-weight=medium]){font-weight:var(--base-text-weight-medium,500)}.prc-Text-Text-9mHv3:where([data-weight=semibold]){font-weight:var(--base-text-weight-semibold,600)}
|
|
2
|
-
/*# sourceMappingURL=Text-
|
|
1
|
+
.prc-Text-Text-9mHv3:where([data-size=small]){font-size:var(--text-body-size-small,.75rem);line-height:var(--text-body-lineHeight-small,1.625)}.prc-Text-Text-9mHv3:where([data-size=medium]){font-size:var(--text-body-size-medium,.875rem);line-height:var(--text-body-lineHeight-medium,1.5)}.prc-Text-Text-9mHv3:where([data-size=large]){font-size:var(--text-body-size-large,1rem);line-height:var(--text-body-lineHeight-large,1.5)}.prc-Text-Text-9mHv3:where([data-weight=light]){font-weight:var(--base-text-weight-light,300)}.prc-Text-Text-9mHv3:where([data-weight=normal]){font-weight:var(--base-text-weight-normal,400)}.prc-Text-Text-9mHv3:where([data-weight=medium]){font-weight:var(--base-text-weight-medium,500)}.prc-Text-Text-9mHv3:where([data-weight=semibold]){font-weight:var(--base-text-weight-semibold,600)}
|
|
2
|
+
/*# sourceMappingURL=Text-ca7603b7.css.map */
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/Text/Text.module.css.js"],"names":[],"mappings":"AACE,8CACE,4CAAsC,CACtC,mDACF,CAEA,+CACE,8CAAuC,CACvC,kDACF,CAEA,8CACE,0CAAsC,CACtC,iDACF,CAEA,gDACE,6CACF,CAEA,iDACE,8CACF,CAEA,iDACE,8CACF,CAEA,mDACE,gDACF","file":"Text-ca7603b7.css","sourcesContent":[".Text {\n &:where([data-size='small']) {\n font-size: var(--text-body-size-small);\n line-height: var(--text-body-lineHeight-small);\n }\n\n &:where([data-size='medium']) {\n font-size: var(--text-body-size-medium);\n line-height: var(--text-body-lineHeight-medium);\n }\n\n &:where([data-size='large']) {\n font-size: var(--text-body-size-large);\n line-height: var(--text-body-lineHeight-large);\n }\n\n &:where([data-weight='light']) {\n font-weight: var(--base-text-weight-light);\n }\n\n &:where([data-weight='normal']) {\n font-weight: var(--base-text-weight-normal);\n }\n\n &:where([data-weight='medium']) {\n font-weight: var(--base-text-weight-medium);\n }\n\n &:where([data-weight='semibold']) {\n font-weight: var(--base-text-weight-semibold);\n }\n}\n"]}
|
package/dist/Text/Text.d.ts
CHANGED
|
@@ -3,18 +3,15 @@ import { type PolymorphicProps } from '../utils/modern-polymorphic';
|
|
|
3
3
|
export type TextProps<As extends React.ElementType = 'span'> = PolymorphicProps<As, 'span', {
|
|
4
4
|
size?: 'large' | 'medium' | 'small';
|
|
5
5
|
weight?: 'light' | 'normal' | 'medium' | 'semibold';
|
|
6
|
-
whiteSpace?: 'pre' | 'normal' | 'nowrap' | 'pre-wrap' | 'pre-line';
|
|
7
6
|
className?: string;
|
|
8
7
|
}>;
|
|
9
8
|
declare const _default: <As extends React.ElementType>(props: (React.ComponentPropsWithRef<React.ElementType extends As ? "span" : As> & {
|
|
10
9
|
size?: "large" | "medium" | "small";
|
|
11
10
|
weight?: "light" | "normal" | "medium" | "semibold";
|
|
12
|
-
whiteSpace?: "pre" | "normal" | "nowrap" | "pre-wrap" | "pre-line";
|
|
13
11
|
className?: string;
|
|
14
12
|
} extends infer T ? T extends React.ComponentPropsWithRef<React.ElementType extends As ? "span" : As> & {
|
|
15
13
|
size?: "large" | "medium" | "small";
|
|
16
14
|
weight?: "light" | "normal" | "medium" | "semibold";
|
|
17
|
-
whiteSpace?: "pre" | "normal" | "nowrap" | "pre-wrap" | "pre-line";
|
|
18
15
|
className?: string;
|
|
19
16
|
} ? T extends unknown ? Omit<T, "as"> : never : never : never) & {
|
|
20
17
|
as?: As | undefined;
|
package/dist/Text/Text.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Text.d.ts","sourceRoot":"","sources":["../../src/Text/Text.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAG9B,OAAO,EAAkB,KAAK,gBAAgB,EAAC,MAAM,6BAA6B,CAAA;AAElF,MAAM,MAAM,SAAS,CAAC,EAAE,SAAS,KAAK,CAAC,WAAW,GAAG,MAAM,IAAI,gBAAgB,CAC7E,EAAE,EACF,MAAM,EACN;IACE,IAAI,CAAC,EAAE,OAAO,GAAG,QAAQ,GAAG,OAAO,CAAA;IACnC,MAAM,CAAC,EAAE,OAAO,GAAG,QAAQ,GAAG,QAAQ,GAAG,UAAU,CAAA;IACnD,
|
|
1
|
+
{"version":3,"file":"Text.d.ts","sourceRoot":"","sources":["../../src/Text/Text.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAG9B,OAAO,EAAkB,KAAK,gBAAgB,EAAC,MAAM,6BAA6B,CAAA;AAElF,MAAM,MAAM,SAAS,CAAC,EAAE,SAAS,KAAK,CAAC,WAAW,GAAG,MAAM,IAAI,gBAAgB,CAC7E,EAAE,EACF,MAAM,EACN;IACE,IAAI,CAAC,EAAE,OAAO,GAAG,QAAQ,GAAG,OAAO,CAAA;IACnC,MAAM,CAAC,EAAE,OAAO,GAAG,QAAQ,GAAG,QAAQ,GAAG,UAAU,CAAA;IACnD,SAAS,CAAC,EAAE,MAAM,CAAA;CACnB,CACF,CAAA;yBAGa,EAAE,SAAS,KAAK,CAAC,WAAW;WAP/B,OAAO,GAAG,QAAQ,GAAG,OAAO;aAC1B,OAAO,GAAG,QAAQ,GAAG,QAAQ,GAAG,UAAU;gBACvC,MAAM;;WAFX,OAAO,GAAG,QAAQ,GAAG,OAAO;aAC1B,OAAO,GAAG,QAAQ,GAAG,QAAQ,GAAG,UAAU;gBACvC,MAAM;;;;AAetB,wBAAoC"}
|
package/dist/Text/Text.js
CHANGED
|
@@ -6,20 +6,18 @@ import { jsx } from 'react/jsx-runtime';
|
|
|
6
6
|
|
|
7
7
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
8
8
|
function Text(props, ref) {
|
|
9
|
-
const $ = c(
|
|
9
|
+
const $ = c(15);
|
|
10
10
|
let className;
|
|
11
11
|
let rest;
|
|
12
12
|
let size;
|
|
13
13
|
let t0;
|
|
14
14
|
let weight;
|
|
15
|
-
let whiteSpace;
|
|
16
15
|
if ($[0] !== props) {
|
|
17
16
|
({
|
|
18
17
|
as: t0,
|
|
19
18
|
className,
|
|
20
19
|
size,
|
|
21
20
|
weight,
|
|
22
|
-
whiteSpace,
|
|
23
21
|
...rest
|
|
24
22
|
} = props);
|
|
25
23
|
$[0] = props;
|
|
@@ -28,44 +26,40 @@ function Text(props, ref) {
|
|
|
28
26
|
$[3] = size;
|
|
29
27
|
$[4] = t0;
|
|
30
28
|
$[5] = weight;
|
|
31
|
-
$[6] = whiteSpace;
|
|
32
29
|
} else {
|
|
33
30
|
className = $[1];
|
|
34
31
|
rest = $[2];
|
|
35
32
|
size = $[3];
|
|
36
33
|
t0 = $[4];
|
|
37
34
|
weight = $[5];
|
|
38
|
-
whiteSpace = $[6];
|
|
39
35
|
}
|
|
40
36
|
const Component = t0 === undefined ? "span" : t0;
|
|
41
37
|
let t1;
|
|
42
|
-
if ($[
|
|
38
|
+
if ($[6] !== className) {
|
|
43
39
|
t1 = clsx(className, classes.Text);
|
|
44
|
-
$[
|
|
45
|
-
$[
|
|
40
|
+
$[6] = className;
|
|
41
|
+
$[7] = t1;
|
|
46
42
|
} else {
|
|
47
|
-
t1 = $[
|
|
43
|
+
t1 = $[7];
|
|
48
44
|
}
|
|
49
45
|
let t2;
|
|
50
|
-
if ($[
|
|
46
|
+
if ($[8] !== Component || $[9] !== ref || $[10] !== rest || $[11] !== size || $[12] !== t1 || $[13] !== weight) {
|
|
51
47
|
t2 = /*#__PURE__*/jsx(Component, {
|
|
52
48
|
className: t1,
|
|
53
49
|
"data-size": size,
|
|
54
50
|
"data-weight": weight,
|
|
55
|
-
"data-white-space": whiteSpace,
|
|
56
51
|
...rest,
|
|
57
52
|
ref: ref
|
|
58
53
|
});
|
|
59
|
-
$[
|
|
60
|
-
$[
|
|
61
|
-
$[
|
|
62
|
-
$[
|
|
63
|
-
$[
|
|
64
|
-
$[
|
|
65
|
-
$[
|
|
66
|
-
$[16] = t2;
|
|
54
|
+
$[8] = Component;
|
|
55
|
+
$[9] = ref;
|
|
56
|
+
$[10] = rest;
|
|
57
|
+
$[11] = size;
|
|
58
|
+
$[12] = t1;
|
|
59
|
+
$[13] = weight;
|
|
60
|
+
$[14] = t2;
|
|
67
61
|
} else {
|
|
68
|
-
t2 = $[
|
|
62
|
+
t2 = $[14];
|
|
69
63
|
}
|
|
70
64
|
return t2;
|
|
71
65
|
}
|
package/dist/ThemeProvider.d.ts
CHANGED
|
@@ -10,12 +10,6 @@ export type ThemeProviderProps = {
|
|
|
10
10
|
dayScheme?: string;
|
|
11
11
|
nightScheme?: string;
|
|
12
12
|
preventSSRMismatch?: boolean;
|
|
13
|
-
/**
|
|
14
|
-
* When true, only provides theme context to descendants without rendering
|
|
15
|
-
* a wrapping `<div>` with `data-*` theme attributes.
|
|
16
|
-
* @default false
|
|
17
|
-
*/
|
|
18
|
-
contextOnly?: boolean;
|
|
19
13
|
};
|
|
20
14
|
export declare const ThemeProvider: React.FC<React.PropsWithChildren<ThemeProviderProps>>;
|
|
21
15
|
export declare function useTheme(): {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ThemeProvider.d.ts","sourceRoot":"","sources":["../src/ThemeProvider.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AAMzB,eAAO,MAAM,gBAAgB,QAAQ,CAAA;AAKrC,MAAM,MAAM,KAAK,GAAG;IAAC,CAAC,GAAG,EAAE,MAAM,GAAG,GAAG,CAAA;CAAC,CAAA;AACxC,KAAK,SAAS,GAAG,KAAK,G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CAAC;oBAC1C,KAAK,CAAC,QAAQ,CAAC,KAAK,CAAC,cAAc,CAAC,MAAM,CAAC,CAAC;EAmH7D;AAED,wBAAgB,iBAAiB,CAAC,MAAM,EAAE,OAAO,CAAC,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC,EAAE,QAAQ,EAAE,MAAM,UAG1F;AAqED,eAAe,aAAa,CAAA"}
|
package/dist/ThemeProvider.js
CHANGED
|
@@ -43,7 +43,7 @@ const getServerHandoff = id => {
|
|
|
43
43
|
const emptySubscribe = () => () => {};
|
|
44
44
|
const ThemeProvider = t0 => {
|
|
45
45
|
var _ref, _props$colorMode, _ref2, _props$dayScheme, _ref3, _props$nightScheme;
|
|
46
|
-
const $ = c(
|
|
46
|
+
const $ = c(42);
|
|
47
47
|
let children;
|
|
48
48
|
let props;
|
|
49
49
|
if ($[0] !== t0) {
|
|
@@ -154,9 +154,10 @@ const ThemeProvider = t0 => {
|
|
|
154
154
|
t6 = $[28];
|
|
155
155
|
}
|
|
156
156
|
const contextValue = t6;
|
|
157
|
-
|
|
157
|
+
const t7 = colorMode === "auto" ? "auto" : colorScheme.includes("dark") ? "dark" : "light";
|
|
158
|
+
let t8;
|
|
158
159
|
if ($[29] !== props.preventSSRMismatch || $[30] !== resolvedColorMode || $[31] !== uniqueDataId) {
|
|
159
|
-
|
|
160
|
+
t8 = props.preventSSRMismatch ? /*#__PURE__*/jsx("script", {
|
|
160
161
|
type: "application/json",
|
|
161
162
|
id: `__PRIMER_DATA_${uniqueDataId}__`,
|
|
162
163
|
dangerouslySetInnerHTML: {
|
|
@@ -168,56 +169,38 @@ const ThemeProvider = t0 => {
|
|
|
168
169
|
$[29] = props.preventSSRMismatch;
|
|
169
170
|
$[30] = resolvedColorMode;
|
|
170
171
|
$[31] = uniqueDataId;
|
|
171
|
-
$[32] =
|
|
172
|
+
$[32] = t8;
|
|
172
173
|
} else {
|
|
173
|
-
|
|
174
|
+
t8 = $[32];
|
|
174
175
|
}
|
|
175
|
-
const ssrHandoffScript = t7;
|
|
176
|
-
if (props.contextOnly) {
|
|
177
|
-
let t8;
|
|
178
|
-
if ($[33] !== children || $[34] !== contextValue || $[35] !== ssrHandoffScript) {
|
|
179
|
-
t8 = /*#__PURE__*/jsxs(ThemeContext.Provider, {
|
|
180
|
-
value: contextValue,
|
|
181
|
-
children: [children, ssrHandoffScript]
|
|
182
|
-
});
|
|
183
|
-
$[33] = children;
|
|
184
|
-
$[34] = contextValue;
|
|
185
|
-
$[35] = ssrHandoffScript;
|
|
186
|
-
$[36] = t8;
|
|
187
|
-
} else {
|
|
188
|
-
t8 = $[36];
|
|
189
|
-
}
|
|
190
|
-
return t8;
|
|
191
|
-
}
|
|
192
|
-
const t8 = colorMode === "auto" ? "auto" : colorScheme.includes("dark") ? "dark" : "light";
|
|
193
176
|
let t9;
|
|
194
|
-
if ($[
|
|
177
|
+
if ($[33] !== children || $[34] !== dayScheme || $[35] !== nightScheme || $[36] !== t7 || $[37] !== t8) {
|
|
195
178
|
t9 = /*#__PURE__*/jsxs("div", {
|
|
196
|
-
"data-color-mode":
|
|
179
|
+
"data-color-mode": t7,
|
|
197
180
|
"data-light-theme": dayScheme,
|
|
198
181
|
"data-dark-theme": nightScheme,
|
|
199
|
-
children: [children,
|
|
182
|
+
children: [children, t8]
|
|
200
183
|
});
|
|
201
|
-
$[
|
|
202
|
-
$[
|
|
203
|
-
$[
|
|
204
|
-
$[
|
|
205
|
-
$[
|
|
206
|
-
$[
|
|
184
|
+
$[33] = children;
|
|
185
|
+
$[34] = dayScheme;
|
|
186
|
+
$[35] = nightScheme;
|
|
187
|
+
$[36] = t7;
|
|
188
|
+
$[37] = t8;
|
|
189
|
+
$[38] = t9;
|
|
207
190
|
} else {
|
|
208
|
-
t9 = $[
|
|
191
|
+
t9 = $[38];
|
|
209
192
|
}
|
|
210
193
|
let t10;
|
|
211
|
-
if ($[
|
|
194
|
+
if ($[39] !== contextValue || $[40] !== t9) {
|
|
212
195
|
t10 = /*#__PURE__*/jsx(ThemeContext.Provider, {
|
|
213
196
|
value: contextValue,
|
|
214
197
|
children: t9
|
|
215
198
|
});
|
|
216
|
-
$[
|
|
217
|
-
$[
|
|
218
|
-
$[
|
|
199
|
+
$[39] = contextValue;
|
|
200
|
+
$[40] = t9;
|
|
201
|
+
$[41] = t10;
|
|
219
202
|
} else {
|
|
220
|
-
t10 = $[
|
|
203
|
+
t10 = $[41];
|
|
221
204
|
}
|
|
222
205
|
return t10;
|
|
223
206
|
};
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
.prc-Timeline-Timeline-awSoC{display:flex;flex-direction:column;list-style:none;margin:0;padding:0}:is(.prc-Timeline-Timeline-awSoC:where([data-clip-sidebar=start]),.prc-Timeline-Timeline-awSoC:where([data-clip-sidebar=both])) .prc-Timeline-TimelineItem-QwDVH:first-child{padding-top:0}:is(:is(.prc-Timeline-Timeline-awSoC:where([data-clip-sidebar=start]),.prc-Timeline-Timeline-awSoC:where([data-clip-sidebar=both])) .prc-Timeline-TimelineItem-QwDVH:first-child) .prc-Timeline-TimelineItemAvatar-4zO8f{top:var(--base-size-16,1rem)}:is(:is(.prc-Timeline-Timeline-awSoC:where([data-clip-sidebar=start]),.prc-Timeline-Timeline-awSoC:where([data-clip-sidebar=both])) .prc-Timeline-TimelineItem-QwDVH:first-child):where([data-condensed]):before{top:var(--base-size-12,.75rem)}:is(:is(.prc-Timeline-Timeline-awSoC:where([data-clip-sidebar=start]),.prc-Timeline-Timeline-awSoC:where([data-clip-sidebar=both])) .prc-Timeline-TimelineItem-QwDVH:first-child):where([data-condensed]) .prc-Timeline-TimelineItemAvatar-4zO8f{top:calc(var(--base-size-8,.5rem) + var(--base-size-8,.5rem))}:is(.prc-Timeline-Timeline-awSoC:where([data-clip-sidebar=end]),.prc-Timeline-Timeline-awSoC:where([data-clip-sidebar=both])) .prc-Timeline-TimelineItem-QwDVH:last-child{padding-bottom:0}:is(:is(.prc-Timeline-Timeline-awSoC:where([data-clip-sidebar=end]),.prc-Timeline-Timeline-awSoC:where([data-clip-sidebar=both])) .prc-Timeline-TimelineItem-QwDVH:last-child):where([data-condensed]):before{height:var(--base-size-12,.75rem)}.prc-Timeline-TimelineItem-QwDVH{display:flex;margin-left:var(--base-size-16,1rem);padding:var(--base-size-16,1rem) 0;position:relative}.prc-Timeline-TimelineItem-QwDVH:before{background-color:var(--borderColor-muted,#d1d9e0b3);bottom:0;content:"";display:block;left:0;position:absolute;top:0;width:2px}.prc-Timeline-TimelineItem-QwDVH:where([data-condensed]){padding-bottom:0;padding-top:var(--base-size-4,.25rem)}.prc-Timeline-TimelineItem-QwDVH:where([data-condensed]):last-child{padding-bottom:var(--base-size-16,1rem)}.prc-Timeline-TimelineItem-QwDVH:where([data-condensed]) .prc-Timeline-TimelineBadge-u0qSm{background-color:var(--bgColor-default,#fff);border:0;color:var(--fgColor-muted,#59636e);height:16px;margin-bottom:var(--base-size-8,.5rem);margin-top:var(--base-size-8,.5rem)}.prc-Timeline-TimelineItem-QwDVH:where([data-condensed]) .prc-Timeline-TimelineItemAvatar-4zO8f{top:calc(var(--base-size-4,.25rem) + var(--base-size-8,.5rem) + var(--base-size-8,.5rem))}.prc-Timeline-TimelineItemAvatar-4zO8f{left:calc((var(--base-size-40,2.5rem) + var(--base-size-32,2rem))*-1);position:absolute;top:calc(var(--base-size-16,1rem) + var(--base-size-16,1rem));transform:translateY(-50%);z-index:1}.prc-Timeline-TimelineBadgeWrapper-SZw4k{position:relative;z-index:1}.prc-Timeline-TimelineBadge-u0qSm{align-items:center;background-color:var(--timelineBadge-bgColor,#f6f8fa);border-color:var(--bgColor-default,#fff);border-radius:50%;border-style:solid;border-width:var(--borderWidth-thick,.125rem);color:var(--fgColor-muted,#59636e);display:flex;flex-shrink:0;height:32px;justify-content:center;margin-left:-15px;margin-right:var(--base-size-8,.5rem);overflow:hidden;width:32px}.prc-Timeline-TimelineBadge-u0qSm:where([data-variant]){color:var(--fgColor-onEmphasis,#fff)}.prc-Timeline-TimelineBadge-u0qSm:where([data-variant=accent]){background-color:var(--bgColor-accent-emphasis,#0969da)}.prc-Timeline-TimelineBadge-u0qSm:where([data-variant=success]){background-color:var(--bgColor-success-emphasis,#1f883d)}.prc-Timeline-TimelineBadge-u0qSm:where([data-variant=attention]){background-color:var(--bgColor-attention-emphasis,#9a6700)}.prc-Timeline-TimelineBadge-u0qSm:where([data-variant=severe]){background-color:var(--bgColor-severe-emphasis,#bc4c00)}.prc-Timeline-TimelineBadge-u0qSm:where([data-variant=danger]){background-color:var(--bgColor-danger-emphasis,#cf222e)}.prc-Timeline-TimelineBadge-u0qSm:where([data-variant=done]){background-color:var(--bgColor-done-emphasis,#8250df)}.prc-Timeline-TimelineBadge-u0qSm:where([data-variant=open]){background-color:var(--bgColor-open-emphasis,#1f883d)}.prc-Timeline-TimelineBadge-u0qSm:where([data-variant=closed]){background-color:var(--bgColor-closed-emphasis,#cf222e)}.prc-Timeline-TimelineBadge-u0qSm:where([data-variant=sponsors]){background-color:var(--bgColor-sponsors-emphasis,#bf3989)}.prc-Timeline-TimelineBody-tjOtb{color:var(--fgColor-muted,#59636e);flex:auto;font-size:var(--text-body-size-medium,.875rem);margin-top:calc(var(--base-size-4,.25rem) + 1px);max-width:100%;min-width:0}.prc-Timeline-TimelineBreak-X8eti{background-color:var(--bgColor-default,#fff);border:0;border-top:var(--borderWidth-thicker,.25rem) solid var(--borderColor-default,#d1d9e0);height:var(--base-size-24,1.5rem);margin:0;margin-bottom:calc(var(--base-size-16,1rem)*-1);margin-left:0;position:relative;z-index:1}.prc-Timeline-TimelineBreak-X8eti:has(+[data-condensed]){margin-bottom:calc(var(--base-size-12,.75rem)*-1)}.prc-Timeline-TimelineItemActions-56Y7h{align-items:center;align-self:flex-start;display:flex;flex-shrink:0;gap:var(--base-size-8,.5rem);margin-left:auto;min-height:var(--base-size-32,2rem)}
|
|
2
|
+
/*# sourceMappingURL=Timeline-ff81db92.css.map */
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["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3B,QAAS,CACT,+CAA6C,CAC7C,aAAc,CALd,iBAAkB,CAClB,SAaF,CAHE,yDACE,iDACF,CAGF,wCAEE,kBAAmB,CACnB,qBAAsB,CAFtB,YAAa,CAOb,aAAc,CADd,4BAAuB,CADvB,gBAAiB,CADjB,mCAIF","file":"Timeline-ff81db92.css","sourcesContent":[".Timeline {\n display: flex;\n flex-direction: column;\n list-style: none;\n padding: 0;\n margin: 0;\n\n &:where([data-clip-sidebar='start']),\n &:where([data-clip-sidebar='both']) {\n .TimelineItem:first-child {\n padding-top: 0;\n\n .TimelineItemAvatar {\n /* No padding-top on first item: badge center is at 0 + 16px (half-badge) */\n top: var(--base-size-16);\n }\n\n &:where([data-condensed])::before {\n top: var(--base-size-12);\n }\n\n &:where([data-condensed]) .TimelineItemAvatar {\n /* No padding-top + condensed: badge center is at 0 + 8px margin + 8px half-badge */\n top: calc(var(--base-size-8) + var(--base-size-8));\n }\n }\n }\n\n &:where([data-clip-sidebar='end']),\n &:where([data-clip-sidebar='both']) {\n .TimelineItem:last-child {\n padding-bottom: 0;\n\n &:where([data-condensed])::before {\n height: var(--base-size-12);\n }\n }\n }\n}\n\n.TimelineItem {\n position: relative;\n display: flex;\n padding: var(--base-size-16) 0;\n margin-left: var(--base-size-16);\n\n &::before {\n position: absolute;\n top: 0;\n bottom: 0;\n left: 0;\n display: block;\n width: 2px;\n content: '';\n /* stylelint-disable-next-line primer/colors */\n background-color: var(--borderColor-muted);\n }\n\n &:where([data-condensed]) {\n padding-top: var(--base-size-4);\n padding-bottom: 0;\n\n &:last-child {\n padding-bottom: var(--base-size-16);\n }\n\n .TimelineBadge {\n height: 16px;\n margin-top: var(--base-size-8);\n margin-bottom: var(--base-size-8);\n color: var(--fgColor-muted);\n background-color: var(--bgColor-default);\n border: 0;\n }\n\n .TimelineItemAvatar {\n /* Vertically center against the condensed badge (4px padding-top + 8px badge top margin + 8px half-badge) */\n top: calc(var(--base-size-4) + var(--base-size-8) + var(--base-size-8));\n }\n }\n}\n\n.TimelineItemAvatar {\n position: absolute;\n /* Place avatar in the left gutter, aligned with surrounding actor avatars (~72px from item content) */\n left: calc(-1 * (var(--base-size-40) + var(--base-size-32)));\n /* Vertically center against the default badge (16px padding-top + 16px half-badge) */\n top: calc(var(--base-size-16) + var(--base-size-16));\n z-index: 1;\n transform: translateY(-50%);\n}\n\n.TimelineBadgeWrapper {\n position: relative;\n z-index: 1;\n}\n\n.TimelineBadge {\n display: flex;\n width: 32px;\n height: 32px;\n margin-right: var(--base-size-8);\n /* stylelint-disable-next-line primer/spacing */\n margin-left: -15px;\n flex-shrink: 0;\n overflow: hidden;\n color: var(--fgColor-muted);\n\n /* TODOl not quite sure if this is the correct migration for this line */\n background-color: var(--timelineBadge-bgColor);\n /* stylelint-disable-next-line primer/colors */\n border-color: var(--bgColor-default);\n border-style: solid;\n border-width: var(--borderWidth-thick);\n border-radius: 50%;\n align-items: center;\n justify-content: center;\n\n &:where([data-variant]) {\n color: var(--fgColor-onEmphasis);\n }\n\n &:where([data-variant='accent']) {\n background-color: var(--bgColor-accent-emphasis);\n }\n\n &:where([data-variant='success']) {\n background-color: var(--bgColor-success-emphasis);\n }\n\n &:where([data-variant='attention']) {\n background-color: var(--bgColor-attention-emphasis);\n }\n\n &:where([data-variant='severe']) {\n background-color: var(--bgColor-severe-emphasis);\n }\n\n &:where([data-variant='danger']) {\n background-color: var(--bgColor-danger-emphasis);\n }\n\n &:where([data-variant='done']) {\n background-color: var(--bgColor-done-emphasis);\n }\n\n &:where([data-variant='open']) {\n background-color: var(--bgColor-open-emphasis);\n }\n\n &:where([data-variant='closed']) {\n background-color: var(--bgColor-closed-emphasis);\n }\n\n &:where([data-variant='sponsors']) {\n background-color: var(--bgColor-sponsors-emphasis);\n }\n}\n\n.TimelineBody {\n min-width: 0;\n max-width: 100%;\n /* stylelint-disable-next-line primer/spacing */\n margin-top: calc(var(--base-size-4) + 1px);\n font-size: var(--text-body-size-medium);\n color: var(--fgColor-muted);\n flex: auto;\n}\n\n.TimelineBreak {\n position: relative;\n z-index: 1;\n height: var(--base-size-24);\n margin: 0;\n margin-bottom: calc(-1 * var(--base-size-16));\n margin-left: 0;\n background-color: var(--bgColor-default);\n border: 0;\n border-top: var(--borderWidth-thicker) solid var(--borderColor-default);\n\n /* stylelint-disable-next-line selector-pseudo-class-disallowed-list -- scoped to CSS Module, audited (github/github-ui#17224) */\n &:has(+ [data-condensed]) {\n margin-bottom: calc(-1 * var(--base-size-12));\n }\n}\n\n.TimelineItemActions {\n display: flex;\n align-items: center;\n align-self: flex-start;\n /* Match the badge wrapper height (32px in both default and condensed) so contents vertically center against the badge */\n min-height: var(--base-size-32);\n margin-left: auto;\n gap: var(--base-size-8);\n flex-shrink: 0;\n}\n"]}
|
|
@@ -3,7 +3,7 @@ type StyledTimelineProps = {
|
|
|
3
3
|
clipSidebar?: boolean | 'start' | 'end' | 'both';
|
|
4
4
|
className?: string;
|
|
5
5
|
};
|
|
6
|
-
export type TimelineProps = StyledTimelineProps & React.ComponentPropsWithoutRef<'
|
|
6
|
+
export type TimelineProps = StyledTimelineProps & Omit<React.ComponentPropsWithoutRef<'ol'>, 'role'>;
|
|
7
7
|
type StyledTimelineItemProps = {
|
|
8
8
|
condensed?: boolean;
|
|
9
9
|
className?: string;
|
|
@@ -11,8 +11,8 @@ type StyledTimelineItemProps = {
|
|
|
11
11
|
/**
|
|
12
12
|
* @deprecated Use the `TimelineItemProps` type instead
|
|
13
13
|
*/
|
|
14
|
-
export type TimelineItemsProps = StyledTimelineItemProps & React.ComponentPropsWithoutRef<'
|
|
15
|
-
export type TimelineItemProps = StyledTimelineItemProps & React.ComponentPropsWithoutRef<'
|
|
14
|
+
export type TimelineItemsProps = StyledTimelineItemProps & React.ComponentPropsWithoutRef<'li'>;
|
|
15
|
+
export type TimelineItemProps = StyledTimelineItemProps & React.ComponentPropsWithoutRef<'li'>;
|
|
16
16
|
export type TimelineBadgeVariant = 'accent' | 'success' | 'attention' | 'severe' | 'danger' | 'done' | 'open' | 'closed' | 'sponsors';
|
|
17
17
|
export type TimelineBadgeProps = {
|
|
18
18
|
children?: React.ReactNode;
|
|
@@ -27,7 +27,7 @@ export type TimelineBodyProps = {
|
|
|
27
27
|
export type TimelineBreakProps = {
|
|
28
28
|
/** Class name for custom styling */
|
|
29
29
|
className?: string;
|
|
30
|
-
} & React.ComponentPropsWithoutRef<'
|
|
30
|
+
} & Omit<React.ComponentPropsWithoutRef<'li'>, 'role'>;
|
|
31
31
|
export type TimelineActionsProps = {
|
|
32
32
|
/** Class name for custom styling */
|
|
33
33
|
className?: string;
|
|
@@ -36,8 +36,8 @@ export type TimelineAvatarProps = {
|
|
|
36
36
|
/** Class name for custom styling */
|
|
37
37
|
className?: string;
|
|
38
38
|
} & React.ComponentPropsWithoutRef<'div'>;
|
|
39
|
-
declare const _default: React.ForwardRefExoticComponent<StyledTimelineProps & Omit<React.DetailedHTMLProps<React.
|
|
40
|
-
Item: React.ForwardRefExoticComponent<StyledTimelineItemProps & Omit<React.DetailedHTMLProps<React.
|
|
39
|
+
declare const _default: React.ForwardRefExoticComponent<StyledTimelineProps & Omit<Omit<React.DetailedHTMLProps<React.OlHTMLAttributes<HTMLOListElement>, HTMLOListElement>, "ref">, "role"> & React.RefAttributes<HTMLOListElement>> & {
|
|
40
|
+
Item: React.ForwardRefExoticComponent<StyledTimelineItemProps & Omit<React.DetailedHTMLProps<React.LiHTMLAttributes<HTMLLIElement>, HTMLLIElement>, "ref"> & React.RefAttributes<HTMLLIElement>>;
|
|
41
41
|
Avatar: React.ForwardRefExoticComponent<{
|
|
42
42
|
/** Class name for custom styling */
|
|
43
43
|
className?: string;
|
|
@@ -53,7 +53,7 @@ declare const _default: React.ForwardRefExoticComponent<StyledTimelineProps & Om
|
|
|
53
53
|
Break: React.ForwardRefExoticComponent<{
|
|
54
54
|
/** Class name for custom styling */
|
|
55
55
|
className?: string;
|
|
56
|
-
} & Omit<React.DetailedHTMLProps<React.
|
|
56
|
+
} & Omit<Omit<React.DetailedHTMLProps<React.LiHTMLAttributes<HTMLLIElement>, HTMLLIElement>, "ref">, "role"> & React.RefAttributes<HTMLLIElement>>;
|
|
57
57
|
Actions: React.ForwardRefExoticComponent<{
|
|
58
58
|
/** Class name for custom styling */
|
|
59
59
|
className?: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Timeline.d.ts","sourceRoot":"","sources":["../../src/Timeline/Timeline.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,MAAM,OAAO,CAAA;AAGzB,KAAK,mBAAmB,GAAG;IAAC,WAAW,CAAC,EAAE,OAAO,GAAG,OAAO,GAAG,KAAK,GAAG,MAAM,CAAC;IAAC,SAAS,CAAC,EAAE,MAAM,CAAA;CAAC,CAAA;AAEjG,MAAM,MAAM,aAAa,GAAG,mBAAmB,GAAG,KAAK,CAAC,wBAAwB,CAAC,
|
|
1
|
+
{"version":3,"file":"Timeline.d.ts","sourceRoot":"","sources":["../../src/Timeline/Timeline.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,MAAM,OAAO,CAAA;AAGzB,KAAK,mBAAmB,GAAG;IAAC,WAAW,CAAC,EAAE,OAAO,GAAG,OAAO,GAAG,KAAK,GAAG,MAAM,CAAC;IAAC,SAAS,CAAC,EAAE,MAAM,CAAA;CAAC,CAAA;AAEjG,MAAM,MAAM,aAAa,GAAG,mBAAmB,GAAG,IAAI,CAAC,KAAK,CAAC,wBAAwB,CAAC,IAAI,CAAC,EAAE,MAAM,CAAC,CAAA;AA0BpG,KAAK,uBAAuB,GAAG;IAAC,SAAS,CAAC,EAAE,OAAO,CAAC;IAAC,SAAS,CAAC,EAAE,MAAM,CAAA;CAAC,CAAA;AAExE;;GAEG;AACH,MAAM,MAAM,kBAAkB,GAAG,uBAAuB,GAAG,KAAK,CAAC,wBAAwB,CAAC,IAAI,CAAC,CAAA;AAE/F,MAAM,MAAM,iBAAiB,GAAG,uBAAuB,GAAG,KAAK,CAAC,wBAAwB,CAAC,IAAI,CAAC,CAAA;A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3;
|
|
50
50
|
if ($[8] !== forwardRef || $[9] !== props || $[10] !== resolvedClipSidebar || $[11] !== t2) {
|
|
51
|
-
t3 = /*#__PURE__*/jsx("
|
|
51
|
+
t3 = /*#__PURE__*/jsx("ol", {
|
|
52
52
|
...props,
|
|
53
|
+
role: "list",
|
|
53
54
|
className: t2,
|
|
54
55
|
ref: forwardRef,
|
|
55
56
|
"data-clip-sidebar": resolvedClipSidebar
|
|
@@ -101,7 +102,7 @@ const TimelineItem = /*#__PURE__*/React.forwardRef((t0, forwardRef) => {
|
|
|
101
102
|
const t2 = condensed ? "" : undefined;
|
|
102
103
|
let t3;
|
|
103
104
|
if ($[6] !== forwardRef || $[7] !== props || $[8] !== t1 || $[9] !== t2) {
|
|
104
|
-
t3 = /*#__PURE__*/jsx("
|
|
105
|
+
t3 = /*#__PURE__*/jsx("li", {
|
|
105
106
|
...props,
|
|
106
107
|
className: t1,
|
|
107
108
|
ref: forwardRef,
|
|
@@ -233,10 +234,11 @@ const TimelineBreak = /*#__PURE__*/React.forwardRef((t0, forwardRef) => {
|
|
|
233
234
|
}
|
|
234
235
|
let t2;
|
|
235
236
|
if ($[5] !== forwardRef || $[6] !== props || $[7] !== t1) {
|
|
236
|
-
t2 = /*#__PURE__*/jsx("
|
|
237
|
+
t2 = /*#__PURE__*/jsx("li", {
|
|
237
238
|
...props,
|
|
238
239
|
className: t1,
|
|
239
|
-
ref: forwardRef
|
|
240
|
+
ref: forwardRef,
|
|
241
|
+
role: "presentation"
|
|
240
242
|
});
|
|
241
243
|
$[5] = forwardRef;
|
|
242
244
|
$[6] = props;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import './Timeline-
|
|
1
|
+
import './Timeline-ff81db92.css';
|
|
2
2
|
|
|
3
3
|
var classes = {"Timeline":"prc-Timeline-Timeline-awSoC","TimelineItem":"prc-Timeline-TimelineItem-QwDVH","TimelineItemAvatar":"prc-Timeline-TimelineItemAvatar-4zO8f","TimelineBadge":"prc-Timeline-TimelineBadge-u0qSm","TimelineBadgeWrapper":"prc-Timeline-TimelineBadgeWrapper-SZw4k","TimelineBody":"prc-Timeline-TimelineBody-tjOtb","TimelineBreak":"prc-Timeline-TimelineBreak-X8eti","TimelineItemActions":"prc-Timeline-TimelineItemActions-56Y7h"};
|
|
4
4
|
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
.prc-TreeView-TreeViewRootUlStyles-Mzrmj{list-style:none;margin:0;padding:0}.prc-TreeView-TreeViewRootUlStyles-Mzrmj .prc-TreeView-TreeViewItem-Ter5f{outline:none}:is(.prc-TreeView-TreeViewRootUlStyles-Mzrmj .prc-TreeView-TreeViewItem-Ter5f):focus-visible>div,:is(.prc-TreeView-TreeViewRootUlStyles-Mzrmj .prc-TreeView-TreeViewItem-Ter5f).focus-visible>div{box-shadow:var(--boxShadow-thick,inset 0 0 0 .125rem) var(--fgColor-accent,#0969da)}@media (forced-colors:active){:is(.prc-TreeView-TreeViewRootUlStyles-Mzrmj .prc-TreeView-TreeViewItem-Ter5f):focus-visible>div,:is(.prc-TreeView-TreeViewRootUlStyles-Mzrmj .prc-TreeView-TreeViewItem-Ter5f).focus-visible>div{outline:2px solid HighlightText;outline-offset:-2}}[data-has-leading-action]:is(.prc-TreeView-TreeViewRootUlStyles-Mzrmj .prc-TreeView-TreeViewItem-Ter5f){--has-leading-action:1}.prc-TreeView-TreeViewRootUlStyles-Mzrmj .prc-TreeView-TreeViewItemContainer-z6qqQ{--level:1;--toggle-width:1rem;--min-item-height:2rem;border-radius:var(--borderRadius-medium,.375rem);color:var(--fgColor-default,#1f2328);cursor:pointer;display:grid;font-size:var(--text-body-size-medium,.875rem);grid-template-areas:"spacer leadingAction toggle content trailingAction";grid-template-columns:var(--spacer-width) var(--leading-action-width) var(--toggle-width) 1fr;position:relative;width:100%;--leading-action-width:calc(var(--has-leading-action, 0)*1.5rem);--spacer-width:calc((var(--level) - 1)*(var(--toggle-width)/2))}:is(.prc-TreeView-TreeViewRootUlStyles-Mzrmj .prc-TreeView-TreeViewItemContainer-z6qqQ):hover{background-color:var(--control-transparent-bgColor-hover,#818b981a)}@media (forced-colors:active){:is(.prc-TreeView-TreeViewRootUlStyles-Mzrmj .prc-TreeView-TreeViewItemContainer-z6qqQ):hover{outline:2px solid transparent;outline-offset:-2px}}@media (pointer:coarse){.prc-TreeView-TreeViewRootUlStyles-Mzrmj .prc-TreeView-TreeViewItemContainer-z6qqQ{--toggle-width:1.5rem;--min-item-height:2.75rem}}:is(.prc-TreeView-TreeViewRootUlStyles-Mzrmj .prc-TreeView-TreeViewItemContainer-z6qqQ):has(.prc-TreeView-TreeViewItemSkeleton-FGlnx):hover{background-color:transparent;cursor:default}@media (forced-colors:active){:is(.prc-TreeView-TreeViewRootUlStyles-Mzrmj .prc-TreeView-TreeViewItemContainer-z6qqQ):has(.prc-TreeView-TreeViewItemSkeleton-FGlnx):hover{outline:none}}.prc-TreeView-TreeViewRootUlStyles-Mzrmj:where([data-omit-spacer=true]) .prc-TreeView-TreeViewItemContainer-z6qqQ{grid-template-columns:0 0 0 1fr}.prc-TreeView-TreeViewRootUlStyles-Mzrmj .prc-TreeView-TreeViewItem-Ter5f[aria-current=true]>.prc-TreeView-TreeViewItemContainer-z6qqQ{background-color:var(--control-transparent-bgColor-selected,#818b9826)}:is(.prc-TreeView-TreeViewRootUlStyles-Mzrmj .prc-TreeView-TreeViewItem-Ter5f[aria-current=true]>.prc-TreeView-TreeViewItemContainer-z6qqQ):after{background-color:var(--fgColor-accent,#0969da);border-radius:var(--borderRadius-medium,.375rem);content:"";height:1.5rem;left:calc(var(--base-size-8,.5rem)*-1);position:absolute;top:calc(50% - var(--base-size-12,.75rem));width:.25rem}@media (forced-colors:active){:is(.prc-TreeView-TreeViewRootUlStyles-Mzrmj .prc-TreeView-TreeViewItem-Ter5f[aria-current=true]>.prc-TreeView-TreeViewItemContainer-z6qqQ):after{background-color:HighlightText}}.prc-TreeView-TreeViewRootUlStyles-Mzrmj .prc-TreeView-TreeViewItemToggle-hq3Xq{align-items:flex-start;color:var(--fgColor-muted,#59636e);display:flex;grid-area:toggle;height:100%;justify-content:center;padding-top:calc(var(--min-item-height)/2 - var(--base-size-12,.75rem)/2)}.prc-TreeView-TreeViewRootUlStyles-Mzrmj .prc-TreeView-TreeViewItemToggleHover-H9tbt:hover{background-color:var(--control-transparent-bgColor-hover,#818b981a)}.prc-TreeView-TreeViewRootUlStyles-Mzrmj .prc-TreeView-TreeViewItemToggleEnd-nWt9I{border-bottom-left-radius:var(--borderRadius-medium,.375rem);border-top-left-radius:var(--borderRadius-medium,.375rem)}.prc-TreeView-TreeViewRootUlStyles-Mzrmj .prc-TreeView-TreeViewItemContent-RKsCI{display:flex;gap:var(--stack-gap-condensed,.5rem);grid-area:content;height:100%;line-height:var(--custom-line-height,var(--text-body-lineHeight-medium,1.4285));padding:0 var(--base-size-8,.5rem);padding-bottom:calc((var(--min-item-height) - var(--custom-line-height, 1.3rem))/2);padding-top:calc((var(--min-item-height) - var(--custom-line-height, 1.3rem))/2)}.prc-TreeView-TreeViewRootUlStyles-Mzrmj .prc-TreeView-TreeViewItemContentText-FFaKp{flex:1 1 auto;width:0}.prc-TreeView-TreeViewRootUlStyles-Mzrmj:where([data-truncate-text=true]) .prc-TreeView-TreeViewItemContentText-FFaKp{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.prc-TreeView-TreeViewRootUlStyles-Mzrmj:where([data-truncate-text=false]) .prc-TreeView-TreeViewItemContentText-FFaKp{word-break:break-word}.prc-TreeView-TreeViewRootUlStyles-Mzrmj .prc-TreeView-TreeViewItemVisual-naWzj{align-items:center;color:var(--fgColor-muted,#59636e);display:flex;height:var(--custom-line-height,1.3rem)}.prc-TreeView-TreeViewRootUlStyles-Mzrmj .prc-TreeView-TreeViewItemLeadingAction-vmOIV{color:var(--fgColor-muted,#59636e);display:flex;grid-area:leadingAction}:is(.prc-TreeView-TreeViewRootUlStyles-Mzrmj .prc-TreeView-TreeViewItemLeadingAction-vmOIV)>button{flex-shrink:1}.prc-TreeView-TreeViewRootUlStyles-Mzrmj .prc-TreeView-TreeViewItemTrailingAction-h9M5g{color:var(--fgColor-muted,#59636e);display:flex;grid-area:trailingAction}.prc-TreeView-TreeViewRootUlStyles-Mzrmj .prc-TreeView-TreeViewItemTrailingActionButton-pCTdP{flex-shrink:1}.prc-TreeView-TreeViewRootUlStyles-Mzrmj .prc-TreeView-TreeViewItemLevelLine-F-0-2{border-color:var(--borderColor-muted,#d1d9e0b3);border-right:var(--borderWidth-thin,.0625rem) solid;height:100%;width:100%}@media (hover:hover){.prc-TreeView-TreeViewRootUlStyles-Mzrmj .prc-TreeView-TreeViewItemLevelLine-F-0-2{border-color:transparent}.prc-TreeView-TreeViewRootUlStyles-Mzrmj:focus-within .prc-TreeView-TreeViewItemLevelLine-F-0-2,.prc-TreeView-TreeViewRootUlStyles-Mzrmj:hover .prc-TreeView-TreeViewItemLevelLine-F-0-2{border-color:var(--borderColor-muted,#d1d9e0b3)}}.prc-TreeView-TreeViewRootUlStyles-Mzrmj .prc-TreeView-TreeViewDirectoryIcon-yP1oY{color:var(--treeViewItem-leadingVisual-iconColor-rest,#54aeff);display:grid}.prc-TreeView-TreeViewRootUlStyles-Mzrmj .prc-TreeView-TreeViewVisuallyHidden-1N8xK{height:1px;margin:-1px;overflow:hidden;padding:0;position:absolute;width:1px;clip:rect(0,0,0,0);border-width:0;white-space:nowrap}.prc-TreeView-TreeViewSkeletonItemContainerStyle-lKqwd{align-items:center;column-gap:.5rem;display:flex;height:2rem}@media (pointer:coarse){.prc-TreeView-TreeViewSkeletonItemContainerStyle-lKqwd{height:2.75rem}}.prc-TreeView-TreeViewSkeletonItemContainerStyle-lKqwd:nth-of-type(5n+1){--tree-item-loading-width:67%}.prc-TreeView-TreeViewSkeletonItemContainerStyle-lKqwd:nth-of-type(5n+2){--tree-item-loading-width:47%}.prc-TreeView-TreeViewSkeletonItemContainerStyle-lKqwd:nth-of-type(5n+3){--tree-item-loading-width:73%}.prc-TreeView-TreeViewSkeletonItemContainerStyle-lKqwd:nth-of-type(5n+4){--tree-item-loading-width:64%}.prc-TreeView-TreeViewSkeletonItemContainerStyle-lKqwd:nth-of-type(5n+5){--tree-item-loading-width:50%}.prc-TreeView-TreeItemSkeletonTextStyles-8VJ-g{width:var(--tree-item-loading-width,67%)}
|
|
2
|
+
/*# sourceMappingURL=TreeView-0fe09f34.css.map */
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/TreeView/TreeView.module.css.js"],"names":[],"mappings":"AAAA,yCAGE,eAAgB,CADhB,QAAS,CADT,SAsPF,CArOE,0EACE,YAgBF,CAdE,kMAEE,mFAOF,CALE,8BAJF,kMAKI,+BAAgC,CAEhC,iBAEJ,CADE,CAGF,wGACE,sBACF,CAGF,mFACE,SAAU,CACV,mBAAoB,CACpB,sBAAuB,CAQvB,gDAAyC,CAFzC,oCAA6B,CAC7B,cAAe,CAJf,YAAa,CAEb,8CAAuC,CAKvC,wEAAyE,CADzE,6FAA8F,CAP9F,iBAAkB,CAElB,UAAW,CAQX,gEAAmE,CACnE,+DA8BF,CA5BE,8FACE,mEAMF,CAJE,8BAHF,8FAII,6BAA8B,CAC9B,mBAEJ,CADE,CAGF,wBA3BF,mFA4BI,qBAAsB,CACtB,yBAiBJ,CAhBE,CAQA,4IAEE,4BAA6B,CAD7B,cAMF,CAHE,8BAJF,4IAKI,YAEJ,CADE,CAIJ,kHACE,+BACF,CAEA,uIACE,sEAwBF,CApBE,kJAaE,8CAAuC,CACvC,gDAAyC,CARzC,UAAW,CADX,aAAc,CAFd,sCAAmC,CAFnC,iBAAkB,CAClB,0CAAoC,CAEpC,YAeF,CAHE,8BAhBF,kJAiBI,8BAEJ,CADE,CAIJ,gFAWE,sBAAuB,CAHvB,kCAA2B,CAP3B,YAAa,CAQb,gBAAiB,CAPjB,WAAY,CAQZ,sBAAuB,CAHvB,yEAKF,CAEA,2FACE,mEACF,CAEA,mFAEE,4DAAqD,CADrD,yDAEF,CAEA,iFACE,YAAa,CAWb,oCAA+B,CAD/B,iBAAkB,CATlB,WAAY,CAQZ,+EAAkF,CAPlF,kCAA6B,CAM7B,mFAAsF,CAFtF,gFAMF,CAEA,qFACE,aAAc,CACd,OACF,CAEA,sHACE,eAAgB,CAChB,sBAAuB,CACvB,kBACF,CAEA,uHAEE,qBACF,CAEA,gFAOE,kBAAmB,CADnB,kCAA2B,CAL3B,YAAa,CAIb,uCAGF,CAEA,uFAEE,kCAA2B,CAD3B,YAAa,CAEb,uBAKF,CAHE,mGACE,aACF,CAGF,wFAEE,kCAA2B,CAD3B,YAAa,CAEb,wBACF,CAEA,8FACE,aACF,CAEA,mFAQE,+CAAsC,CACtC,mDAA2C,CAP3C,WAAY,CADZ,UASF,CAQA,qBACE,mFACE,wBACF,CAEA,yLAEE,+CACF,CACF,CAEA,mFAEE,8DAAuD,CADvD,YAEF,CAEA,oFAGE,UAAW,CAGX,WAAY,CACZ,eAAgB,CAHhB,SAAU,CAHV,iBAAkB,CAClB,SAAU,CAOV,kBAAsB,CAEtB,cAAe,CADf,kBAEF,CAGF,uDAEE,kBAAmB,CACnB,gBAAkB,CAFlB,YAAa,CAGb,WAyBF,CAvBE,wBANF,uDAOI,cAsBJ,CArBE,CAEA,yEACE,6BACF,CAEA,yEACE,6BACF,CAEA,yEACE,6BACF,CAEA,yEACE,6BACF,CAEA,yEACE,6BACF,CAGF,+CACE,wCACF","file":"TreeView-0fe09f34.css","sourcesContent":[".TreeViewRootUlStyles {\n padding: 0;\n margin: 0;\n list-style: none;\n\n /*\n * WARNING: This is a performance optimization.\n *\n * We define styles for the tree items at the root level of the tree\n * to avoid recomputing the styles for each item when the tree updates.\n * We're sacrificing maintainability for performance because TreeView\n * needs to be performant enough to handle large trees (thousands of items).\n *\n * This is intended to be a temporary solution until we can improve the\n * performance of our styling patterns.\n *\n * Do NOT copy this pattern without understanding the tradeoffs.\n */\n .TreeViewItem {\n outline: none;\n\n &:focus-visible > div,\n &:global(.focus-visible) > div {\n box-shadow: var(--boxShadow-thick) var(--fgColor-accent);\n\n @media (forced-colors: active) {\n outline: 2px solid HighlightText;\n /* stylelint-disable-next-line declaration-property-value-no-unknown */\n outline-offset: -2;\n }\n }\n\n &[data-has-leading-action] {\n --has-leading-action: 1;\n }\n }\n\n .TreeViewItemContainer {\n --level: 1;\n --toggle-width: 1rem;\n --min-item-height: 2rem;\n\n position: relative;\n display: grid;\n width: 100%;\n font-size: var(--text-body-size-medium);\n color: var(--fgColor-default);\n cursor: pointer;\n border-radius: var(--borderRadius-medium);\n grid-template-columns: var(--spacer-width) var(--leading-action-width) var(--toggle-width) 1fr;\n grid-template-areas: 'spacer leadingAction toggle content trailingAction';\n\n --leading-action-width: calc(var(--has-leading-action, 0) * 1.5rem);\n --spacer-width: calc(calc(var(--level) - 1) * (var(--toggle-width) / 2));\n\n &:hover {\n background-color: var(--control-transparent-bgColor-hover);\n\n @media (forced-colors: active) {\n outline: 2px solid transparent;\n outline-offset: -2px;\n }\n }\n\n @media (pointer: coarse) {\n --toggle-width: 1.5rem;\n --min-item-height: 2.75rem;\n }\n\n /*\n * NOTE: Uses descendant :has() - TreeViewItemSkeleton is nested inside\n * TreeViewItemContent > TreeViewItemContentText, not a direct child.\n * This is acceptable as the search is scoped to this element's subtree.\n */\n /* stylelint-disable-next-line selector-pseudo-class-disallowed-list -- scoped to CSS Module, audited (github/github-ui#17224) */\n &:has(.TreeViewItemSkeleton):hover {\n cursor: default;\n background-color: transparent;\n\n @media (forced-colors: active) {\n outline: none;\n }\n }\n }\n\n &:where([data-omit-spacer='true']) .TreeViewItemContainer {\n grid-template-columns: 0 0 0 1fr;\n }\n\n .TreeViewItem[aria-current='true'] > .TreeViewItemContainer {\n background-color: var(--control-transparent-bgColor-selected);\n\n /* Current item indicator */\n /* stylelint-disable-next-line selector-max-specificity */\n &::after {\n position: absolute;\n top: calc(50% - var(--base-size-12));\n left: calc(-1 * var(--base-size-8));\n width: 0.25rem;\n height: 1.5rem;\n content: '';\n\n /*\n * Use fgColor accent for consistency across all themes. Using the \"correct\" variable,\n * --bgColor-accent-emphasis, causes vrt failures for dark high contrast mode\n */\n /* stylelint-disable-next-line primer/colors */\n background-color: var(--fgColor-accent);\n border-radius: var(--borderRadius-medium);\n\n @media (forced-colors: active) {\n background-color: HighlightText;\n }\n }\n }\n\n .TreeViewItemToggle {\n display: flex;\n height: 100%;\n\n /* The toggle should appear vertically centered for single-line items, but remain at the top for items that wrap\n across more lines. */\n /* stylelint-disable-next-line primer/spacing */\n padding-top: calc(var(--min-item-height) / 2 - var(--base-size-12) / 2);\n color: var(--fgColor-muted);\n grid-area: toggle;\n justify-content: center;\n align-items: flex-start;\n }\n\n .TreeViewItemToggleHover:hover {\n background-color: var(--control-transparent-bgColor-hover);\n }\n\n .TreeViewItemToggleEnd {\n border-top-left-radius: var(--borderRadius-medium);\n border-bottom-left-radius: var(--borderRadius-medium);\n }\n\n .TreeViewItemContent {\n display: flex;\n height: 100%;\n padding: 0 var(--base-size-8);\n\n /* The dynamic top and bottom padding to maintain the minimum item height for single line items */\n /* stylelint-disable-next-line primer/spacing */\n padding-top: calc((var(--min-item-height) - var(--custom-line-height, 1.3rem)) / 2);\n /* stylelint-disable-next-line primer/spacing */\n padding-bottom: calc((var(--min-item-height) - var(--custom-line-height, 1.3rem)) / 2);\n line-height: var(--custom-line-height, var(--text-body-lineHeight-medium, 1.4285));\n grid-area: content;\n gap: var(--stack-gap-condensed);\n }\n\n .TreeViewItemContentText {\n flex: 1 1 auto;\n width: 0;\n }\n\n &:where([data-truncate-text='true']) .TreeViewItemContentText {\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n }\n\n &:where([data-truncate-text='false']) .TreeViewItemContentText {\n /* stylelint-disable-next-line declaration-property-value-keyword-no-deprecated */\n word-break: break-word;\n }\n\n .TreeViewItemVisual {\n display: flex;\n\n /* The visual icons should appear vertically centered for single-line items, but remain at the top for items that wrap\n across more lines. */\n height: var(--custom-line-height, 1.3rem);\n color: var(--fgColor-muted);\n align-items: center;\n }\n\n .TreeViewItemLeadingAction {\n display: flex;\n color: var(--fgColor-muted);\n grid-area: leadingAction;\n\n & > button {\n flex-shrink: 1;\n }\n }\n\n .TreeViewItemTrailingAction {\n display: flex;\n color: var(--fgColor-muted);\n grid-area: trailingAction;\n }\n\n .TreeViewItemTrailingActionButton {\n flex-shrink: 1;\n }\n\n .TreeViewItemLevelLine {\n width: 100%;\n height: 100%;\n\n /*\n * On devices without hover, the nesting indicator lines\n * appear at all times.\n */\n border-color: var(--borderColor-muted);\n border-right: var(--borderWidth-thin) solid;\n }\n\n /*\n * On devices with :hover support, the nesting indicator lines\n * fade in when the user mouses over the entire component,\n * or when there's focus inside the component. This makes\n * sure the component remains simple when not in use.\n */\n @media (hover: hover) {\n .TreeViewItemLevelLine {\n border-color: transparent;\n }\n\n &:hover .TreeViewItemLevelLine,\n &:focus-within .TreeViewItemLevelLine {\n border-color: var(--borderColor-muted);\n }\n }\n\n .TreeViewDirectoryIcon {\n display: grid;\n color: var(--treeViewItem-leadingVisual-iconColor-rest);\n }\n\n .TreeViewVisuallyHidden {\n position: absolute;\n width: 1px;\n height: 1px;\n padding: 0;\n /* stylelint-disable-next-line primer/spacing */\n margin: -1px;\n overflow: hidden;\n /* stylelint-disable-next-line property-no-deprecated */\n clip: rect(0, 0, 0, 0);\n white-space: nowrap;\n border-width: 0;\n }\n}\n\n.TreeViewSkeletonItemContainerStyle {\n display: flex;\n align-items: center;\n column-gap: 0.5rem;\n height: 2rem;\n\n @media (pointer: coarse) {\n height: 2.75rem;\n }\n\n &:nth-of-type(5n + 1) {\n --tree-item-loading-width: 67%;\n }\n\n &:nth-of-type(5n + 2) {\n --tree-item-loading-width: 47%;\n }\n\n &:nth-of-type(5n + 3) {\n --tree-item-loading-width: 73%;\n }\n\n &:nth-of-type(5n + 4) {\n --tree-item-loading-width: 64%;\n }\n\n &:nth-of-type(5n + 5) {\n --tree-item-loading-width: 50%;\n }\n}\n\n.TreeItemSkeletonTextStyles {\n width: var(--tree-item-loading-width, 67%);\n}\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TreeView.d.ts","sourceRoot":"","sources":["../../src/TreeView/TreeView.tsx"],"names":[],"mappings":"AAAA,OAAO,EAKL,KAAK,IAAI,EACV,MAAM,wBAAwB,CAAA;AAE/B,OAAO,KAA+B,MAAM,OAAO,CAAA;AAsBnD,OAAO,KAAK,EAAC,gBAAgB,EAAC,MAAM,gBAAgB,CAAA;
|
|
1
|
+
{"version":3,"file":"TreeView.d.ts","sourceRoot":"","sources":["../../src/TreeView/TreeView.tsx"],"names":[],"mappings":"AAAA,OAAO,EAKL,KAAK,IAAI,EACV,MAAM,wBAAwB,CAAA;AAE/B,OAAO,KAA+B,MAAM,OAAO,CAAA;AAsBnD,OAAO,KAAK,EAAC,gBAAgB,EAAC,MAAM,gBAAgB,CAAA;AA4CpD,MAAM,MAAM,aAAa,GAAG;IAC1B,YAAY,CAAC,EAAE,KAAK,CAAC,cAAc,CAAC,YAAY,CAAC,CAAA;IACjD,iBAAiB,CAAC,EAAE,KAAK,CAAC,cAAc,CAAC,iBAAiB,CAAC,CAAA;IAC3D,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAA;IACzB,IAAI,CAAC,EAAE,OAAO,CAAA;IACd,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,KAAK,CAAC,EAAE,KAAK,CAAC,aAAa,CAAA;CAC5B,CAAA;AAED,MAAM,MAAM,wBAAwB,GAAG;IACrC,KAAK,EAAE,MAAM,CAAA;IACb,OAAO,EAAE,MAAM,IAAI,CAAA;IACnB,IAAI,EAAE,IAAI,CAAA;IACV,KAAK,CAAC,EAAE,MAAM,GAAG,MAAM,CAAA;IACvB,SAAS,CAAC,EAAE,MAAM,CAAA;CACnB,CAAA;AAgHD,MAAM,MAAM,iBAAiB,GAAG;IAC9B,YAAY,CAAC,EAAE,KAAK,CAAC,cAAc,CAAC,YAA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,MAAM,CAAA;CACrB,CAAA;AA0ED,MAAM,MAAM,yBAAyB,GAAG;IACtC,KAAK,EAAE,wBAAwB,EAAE,CAAA;IACjC,OAAO,CAAC,EAAE,MAAM,IAAI,CAAA;CACrB,CAAA;AAwED,MAAM,MAAM,wBAAwB,GAAG;IACrC,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAA;IACzB,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,OAAO,CAAC,EAAE,MAAM,IAAI,CAAA;IACpB,SAAS,CAAC,EAAE,MAAM,IAAI,CAAA;CACvB,CAAA;AA4CD,eAAO,MAAM,QAAQ;;;;;;;;CAQnB,CAAA"}
|
|
@@ -46,11 +46,6 @@ const ItemContext = /*#__PURE__*/React.createContext({
|
|
|
46
46
|
trailingActionId: ''
|
|
47
47
|
});
|
|
48
48
|
|
|
49
|
-
// Module-private channel from LoadingItem to the Item it renders. Lets us mark the placeholder
|
|
50
|
-
// row with `data-loading` (used by CSS to suppress hover affordances) without exposing an
|
|
51
|
-
// internal-only prop on the public TreeViewItemProps API.
|
|
52
|
-
const LoadingPlaceholderContext = /*#__PURE__*/React.createContext(false);
|
|
53
|
-
|
|
54
49
|
// ----------------------------------------------------------------------------
|
|
55
50
|
// TreeView
|
|
56
51
|
|
|
@@ -308,7 +303,6 @@ const Item = /*#__PURE__*/React.forwardRef(({
|
|
|
308
303
|
const {
|
|
309
304
|
level
|
|
310
305
|
} = React.useContext(ItemContext);
|
|
311
|
-
const isLoadingPlaceholder = React.useContext(LoadingPlaceholderContext);
|
|
312
306
|
const {
|
|
313
307
|
hasSubTree,
|
|
314
308
|
subTree,
|
|
@@ -406,7 +400,6 @@ const Item = /*#__PURE__*/React.forwardRef(({
|
|
|
406
400
|
"aria-current": isCurrentItem ? 'true' : undefined,
|
|
407
401
|
"aria-selected": isFocused ? 'true' : 'false',
|
|
408
402
|
"data-has-leading-action": slots.leadingAction ? true : undefined,
|
|
409
|
-
"data-loading": isLoadingPlaceholder ? true : undefined,
|
|
410
403
|
onKeyDown: handleKeyDown,
|
|
411
404
|
onFocus: event_1 => {
|
|
412
405
|
// Defer scroll to the next animation frame so that rapid keyboard
|
|
@@ -785,13 +778,10 @@ const LoadingItem = /*#__PURE__*/React.forwardRef((t0, ref) => {
|
|
|
785
778
|
}
|
|
786
779
|
let t4;
|
|
787
780
|
if ($[5] !== itemId || $[6] !== ref || $[7] !== t1 || $[8] !== t3) {
|
|
788
|
-
t4 = /*#__PURE__*/
|
|
789
|
-
|
|
790
|
-
|
|
791
|
-
|
|
792
|
-
ref: ref,
|
|
793
|
-
children: [t1, t3]
|
|
794
|
-
})
|
|
781
|
+
t4 = /*#__PURE__*/jsxs(Item, {
|
|
782
|
+
id: itemId,
|
|
783
|
+
ref: ref,
|
|
784
|
+
children: [t1, t3]
|
|
795
785
|
});
|
|
796
786
|
$[5] = itemId;
|
|
797
787
|
$[6] = ref;
|
|
@@ -823,13 +813,10 @@ const LoadingItem = /*#__PURE__*/React.forwardRef((t0, ref) => {
|
|
|
823
813
|
}
|
|
824
814
|
let t3;
|
|
825
815
|
if ($[12] !== itemId || $[13] !== ref) {
|
|
826
|
-
t3 = /*#__PURE__*/
|
|
827
|
-
|
|
828
|
-
|
|
829
|
-
|
|
830
|
-
ref: ref,
|
|
831
|
-
children: [t1, t2]
|
|
832
|
-
})
|
|
816
|
+
t3 = /*#__PURE__*/jsxs(Item, {
|
|
817
|
+
id: itemId,
|
|
818
|
+
ref: ref,
|
|
819
|
+
children: [t1, t2]
|
|
833
820
|
});
|
|
834
821
|
$[12] = itemId;
|
|
835
822
|
$[13] = ref;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import './TreeView-
|
|
1
|
+
import './TreeView-0fe09f34.css';
|
|
2
2
|
|
|
3
|
-
var classes = {"TreeViewRootUlStyles":"prc-TreeView-TreeViewRootUlStyles-Mzrmj","TreeViewItem":"prc-TreeView-TreeViewItem-Ter5f","TreeViewItemContainer":"prc-TreeView-TreeViewItemContainer-z6qqQ","TreeViewItemToggle":"prc-TreeView-TreeViewItemToggle-hq3Xq","TreeViewItemToggleHover":"prc-TreeView-TreeViewItemToggleHover-H9tbt","TreeViewItemToggleEnd":"prc-TreeView-TreeViewItemToggleEnd-nWt9I","TreeViewItemContent":"prc-TreeView-TreeViewItemContent-RKsCI","TreeViewItemContentText":"prc-TreeView-TreeViewItemContentText-FFaKp","TreeViewItemVisual":"prc-TreeView-TreeViewItemVisual-naWzj","TreeViewItemLeadingAction":"prc-TreeView-TreeViewItemLeadingAction-vmOIV","TreeViewItemTrailingAction":"prc-TreeView-TreeViewItemTrailingAction-h9M5g","TreeViewItemTrailingActionButton":"prc-TreeView-TreeViewItemTrailingActionButton-pCTdP","TreeViewItemLevelLine":"prc-TreeView-TreeViewItemLevelLine-F-0-2","TreeViewDirectoryIcon":"prc-TreeView-TreeViewDirectoryIcon-yP1oY","TreeViewVisuallyHidden":"prc-TreeView-TreeViewVisuallyHidden-1N8xK","TreeViewSkeletonItemContainerStyle":"prc-TreeView-TreeViewSkeletonItemContainerStyle-lKqwd","TreeItemSkeletonTextStyles":"prc-TreeView-TreeItemSkeletonTextStyles-8VJ-g"};
|
|
3
|
+
var classes = {"TreeViewRootUlStyles":"prc-TreeView-TreeViewRootUlStyles-Mzrmj","TreeViewItem":"prc-TreeView-TreeViewItem-Ter5f","TreeViewItemContainer":"prc-TreeView-TreeViewItemContainer-z6qqQ","TreeViewItemSkeleton":"prc-TreeView-TreeViewItemSkeleton-FGlnx","TreeViewItemToggle":"prc-TreeView-TreeViewItemToggle-hq3Xq","TreeViewItemToggleHover":"prc-TreeView-TreeViewItemToggleHover-H9tbt","TreeViewItemToggleEnd":"prc-TreeView-TreeViewItemToggleEnd-nWt9I","TreeViewItemContent":"prc-TreeView-TreeViewItemContent-RKsCI","TreeViewItemContentText":"prc-TreeView-TreeViewItemContentText-FFaKp","TreeViewItemVisual":"prc-TreeView-TreeViewItemVisual-naWzj","TreeViewItemLeadingAction":"prc-TreeView-TreeViewItemLeadingAction-vmOIV","TreeViewItemTrailingAction":"prc-TreeView-TreeViewItemTrailingAction-h9M5g","TreeViewItemTrailingActionButton":"prc-TreeView-TreeViewItemTrailingActionButton-pCTdP","TreeViewItemLevelLine":"prc-TreeView-TreeViewItemLevelLine-F-0-2","TreeViewDirectoryIcon":"prc-TreeView-TreeViewDirectoryIcon-yP1oY","TreeViewVisuallyHidden":"prc-TreeView-TreeViewVisuallyHidden-1N8xK","TreeViewSkeletonItemContainerStyle":"prc-TreeView-TreeViewSkeletonItemContainerStyle-lKqwd","TreeItemSkeletonTextStyles":"prc-TreeView-TreeItemSkeletonTextStyles-8VJ-g"};
|
|
4
4
|
|
|
5
5
|
export { classes as default };
|
|
@@ -7520,26 +7520,6 @@
|
|
|
7520
7520
|
{
|
|
7521
7521
|
"id": "components-text-features--semibold-weight",
|
|
7522
7522
|
"code": "() => (\n <Text as=\"span\" weight=\"semibold\">\n Stylized text\n </Text>\n)"
|
|
7523
|
-
},
|
|
7524
|
-
{
|
|
7525
|
-
"id": "components-text-features--pre-white-space",
|
|
7526
|
-
"code": "() => (\n <Text as=\"span\" whiteSpace=\"pre\">\n Stylized text\n </Text>\n)"
|
|
7527
|
-
},
|
|
7528
|
-
{
|
|
7529
|
-
"id": "components-text-features--normal-white-space",
|
|
7530
|
-
"code": "() => (\n <Text as=\"span\" whiteSpace=\"normal\">\n Stylized text\n </Text>\n)"
|
|
7531
|
-
},
|
|
7532
|
-
{
|
|
7533
|
-
"id": "components-text-features--nowrap-white-space",
|
|
7534
|
-
"code": "() => (\n <Text as=\"span\" whiteSpace=\"nowrap\">\n Stylized text\n </Text>\n)"
|
|
7535
|
-
},
|
|
7536
|
-
{
|
|
7537
|
-
"id": "components-text-features--pre-wrap-white-space",
|
|
7538
|
-
"code": "() => (\n <Text as=\"span\" whiteSpace=\"pre-wrap\">\n Stylized text\n </Text>\n)"
|
|
7539
|
-
},
|
|
7540
|
-
{
|
|
7541
|
-
"id": "components-text-features--pre-line-white-space",
|
|
7542
|
-
"code": "() => (\n <Text as=\"span\" whiteSpace=\"pre-line\">\n Stylized text\n </Text>\n)"
|
|
7543
7523
|
}
|
|
7544
7524
|
],
|
|
7545
7525
|
"importPath": "@primer/react",
|
package/package.json
CHANGED