@backstage/ui 0.0.0-nightly-20251105024121 → 0.0.0-nightly-20251107024121
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 +39 -1
- package/dist/components/Accordion/Accordion.esm.js +109 -0
- package/dist/components/Accordion/Accordion.esm.js.map +1 -0
- package/dist/components/Accordion/Accordion.module.css.esm.js +8 -0
- package/dist/components/Accordion/Accordion.module.css.esm.js.map +1 -0
- package/dist/components/Dialog/Dialog.module.css.esm.js +1 -1
- package/dist/components/Popover/Popover.module.css.esm.js +1 -1
- package/dist/components/Select/Select.esm.js +3 -1
- package/dist/components/Select/Select.esm.js.map +1 -1
- package/dist/components/Select/Select.module.css.esm.js +2 -2
- package/dist/index.d.ts +57 -18
- package/dist/index.esm.js +1 -1
- package/dist/utils/componentDefinitions.esm.js +13 -7
- package/dist/utils/componentDefinitions.esm.js.map +1 -1
- package/package.json +2 -2
- package/dist/components/Collapsible/Collapsible.esm.js +0 -55
- package/dist/components/Collapsible/Collapsible.esm.js.map +0 -1
- package/dist/components/Collapsible/Collapsible.module.css.esm.js +0 -8
- package/dist/components/Collapsible/Collapsible.module.css.esm.js.map +0 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# @backstage/ui
|
|
2
2
|
|
|
3
|
-
## 0.0.0-nightly-
|
|
3
|
+
## 0.0.0-nightly-20251107024121
|
|
4
4
|
|
|
5
5
|
### Minor Changes
|
|
6
6
|
|
|
@@ -98,12 +98,50 @@
|
|
|
98
98
|
|
|
99
99
|
If you were passing custom className values to any of these components that relied on the previous behavior, you may need to adjust your styles to account for the default classes now being applied alongside your custom classes.
|
|
100
100
|
|
|
101
|
+
- 83c100e: **BREAKING**: Removed `Collapsible` component. Migrate to `Accordion` or use React Aria `Disclosure`.
|
|
102
|
+
|
|
103
|
+
## Migration Path 1: Accordion (Opinionated Styled Component)
|
|
104
|
+
|
|
105
|
+
Accordion provides preset styling with a similar component structure.
|
|
106
|
+
|
|
107
|
+
```diff
|
|
108
|
+
- import { Collapsible } from '@backstage/ui';
|
|
109
|
+
+ import { Accordion, AccordionTrigger, AccordionPanel } from '@backstage/ui';
|
|
110
|
+
|
|
111
|
+
- <Collapsible.Root>
|
|
112
|
+
- <Collapsible.Trigger render={(props) => <Button {...props}>Toggle</Button>} />
|
|
113
|
+
- <Collapsible.Panel>Content</Collapsible.Panel>
|
|
114
|
+
- </Collapsible.Root>
|
|
115
|
+
|
|
116
|
+
+ <Accordion>
|
|
117
|
+
+ <AccordionTrigger title="Toggle" />
|
|
118
|
+
+ <AccordionPanel>Content</AccordionPanel>
|
|
119
|
+
+ </Accordion>
|
|
120
|
+
```
|
|
121
|
+
|
|
122
|
+
CSS classes: `.bui-CollapsibleRoot` → `.bui-Accordion`, `.bui-CollapsibleTrigger` → `.bui-AccordionTrigger` (now on heading element), `.bui-CollapsiblePanel` → `.bui-AccordionPanel`
|
|
123
|
+
|
|
124
|
+
## Migration Path 2: React Aria Disclosure (Full Customization)
|
|
125
|
+
|
|
126
|
+
For custom styling without preset styles:
|
|
127
|
+
|
|
128
|
+
```tsx
|
|
129
|
+
import { Disclosure, Button, DisclosurePanel } from 'react-aria-components';
|
|
130
|
+
|
|
131
|
+
<Disclosure>
|
|
132
|
+
<Button slot="trigger">Toggle</Button>
|
|
133
|
+
<DisclosurePanel>Content</DisclosurePanel>
|
|
134
|
+
</Disclosure>;
|
|
135
|
+
```
|
|
136
|
+
|
|
101
137
|
### Patch Changes
|
|
102
138
|
|
|
103
139
|
- d01de00: Fix broken external links in Backstage UI Header component.
|
|
140
|
+
- 35a3614: Fixed CSS issues in Select component including popover width constraints, focus outline behavior, and overflow handling.
|
|
104
141
|
- 26c6a78: Fix default text color in Backstage UI
|
|
105
142
|
- deaa427: Fixed Text component to prevent `truncate` prop from being spread to the underlying DOM element.
|
|
106
143
|
- 1059f95: Improved the Link component structure in Backstage UI.
|
|
144
|
+
- 836b0c7: Fixed dialog backdrop appearance in dark mode.
|
|
107
145
|
- 6874094: Migrated CellProfile component from Base UI Avatar to Backstage UI Avatar component.
|
|
108
146
|
- 719d772: Avatar components in x-small and small sizes now display only one initial instead of two, improving readability at smaller dimensions.
|
|
109
147
|
- dac851f: Fix the default font size in Backstage UI.
|
|
@@ -0,0 +1,109 @@
|
|
|
1
|
+
import { jsx, jsxs } from 'react/jsx-runtime';
|
|
2
|
+
import { forwardRef } from 'react';
|
|
3
|
+
import { Disclosure, Heading, Button, DisclosurePanel, DisclosureGroup } from 'react-aria-components';
|
|
4
|
+
import { RiArrowDownSLine } from '@remixicon/react';
|
|
5
|
+
import clsx from 'clsx';
|
|
6
|
+
import { useStyles } from '../../hooks/useStyles.esm.js';
|
|
7
|
+
import styles from './Accordion.module.css.esm.js';
|
|
8
|
+
import { Flex } from '../Flex/Flex.esm.js';
|
|
9
|
+
|
|
10
|
+
const Accordion = forwardRef(({ className, ...props }, ref) => {
|
|
11
|
+
const { classNames, cleanedProps } = useStyles("Accordion", props);
|
|
12
|
+
return /* @__PURE__ */ jsx(
|
|
13
|
+
Disclosure,
|
|
14
|
+
{
|
|
15
|
+
ref,
|
|
16
|
+
className: clsx(classNames.root, styles[classNames.root], className),
|
|
17
|
+
...cleanedProps
|
|
18
|
+
}
|
|
19
|
+
);
|
|
20
|
+
});
|
|
21
|
+
Accordion.displayName = "Accordion";
|
|
22
|
+
const AccordionTrigger = forwardRef(({ className, title, subtitle, children, ...props }, ref) => {
|
|
23
|
+
const { classNames, cleanedProps } = useStyles("Accordion", props);
|
|
24
|
+
return /* @__PURE__ */ jsx(
|
|
25
|
+
Heading,
|
|
26
|
+
{
|
|
27
|
+
ref,
|
|
28
|
+
className: clsx(
|
|
29
|
+
classNames.trigger,
|
|
30
|
+
styles[classNames.trigger],
|
|
31
|
+
className
|
|
32
|
+
),
|
|
33
|
+
...cleanedProps,
|
|
34
|
+
children: /* @__PURE__ */ jsxs(
|
|
35
|
+
Button,
|
|
36
|
+
{
|
|
37
|
+
slot: "trigger",
|
|
38
|
+
className: clsx(
|
|
39
|
+
classNames.triggerButton,
|
|
40
|
+
styles[classNames.triggerButton]
|
|
41
|
+
),
|
|
42
|
+
children: [
|
|
43
|
+
children ? children : /* @__PURE__ */ jsxs(Flex, { gap: "2", align: "center", children: [
|
|
44
|
+
/* @__PURE__ */ jsx(
|
|
45
|
+
"span",
|
|
46
|
+
{
|
|
47
|
+
className: clsx(
|
|
48
|
+
classNames.triggerTitle,
|
|
49
|
+
styles[classNames.triggerTitle]
|
|
50
|
+
),
|
|
51
|
+
children: title
|
|
52
|
+
}
|
|
53
|
+
),
|
|
54
|
+
subtitle && /* @__PURE__ */ jsx(
|
|
55
|
+
"span",
|
|
56
|
+
{
|
|
57
|
+
className: clsx(
|
|
58
|
+
classNames.triggerSubtitle,
|
|
59
|
+
styles[classNames.triggerSubtitle]
|
|
60
|
+
),
|
|
61
|
+
children: subtitle
|
|
62
|
+
}
|
|
63
|
+
)
|
|
64
|
+
] }),
|
|
65
|
+
/* @__PURE__ */ jsx(
|
|
66
|
+
RiArrowDownSLine,
|
|
67
|
+
{
|
|
68
|
+
className: clsx(
|
|
69
|
+
classNames.triggerIcon,
|
|
70
|
+
styles[classNames.triggerIcon]
|
|
71
|
+
),
|
|
72
|
+
size: 16
|
|
73
|
+
}
|
|
74
|
+
)
|
|
75
|
+
]
|
|
76
|
+
}
|
|
77
|
+
)
|
|
78
|
+
}
|
|
79
|
+
);
|
|
80
|
+
});
|
|
81
|
+
AccordionTrigger.displayName = "AccordionTrigger";
|
|
82
|
+
const AccordionPanel = forwardRef(({ className, ...props }, ref) => {
|
|
83
|
+
const { classNames, cleanedProps } = useStyles("Accordion", props);
|
|
84
|
+
return /* @__PURE__ */ jsx(
|
|
85
|
+
DisclosurePanel,
|
|
86
|
+
{
|
|
87
|
+
ref,
|
|
88
|
+
className: clsx(classNames.panel, styles[classNames.panel], className),
|
|
89
|
+
...cleanedProps
|
|
90
|
+
}
|
|
91
|
+
);
|
|
92
|
+
});
|
|
93
|
+
AccordionPanel.displayName = "AccordionPanel";
|
|
94
|
+
const AccordionGroup = forwardRef(({ className, allowsMultiple = false, ...props }, ref) => {
|
|
95
|
+
const { classNames, cleanedProps } = useStyles("Accordion", props);
|
|
96
|
+
return /* @__PURE__ */ jsx(
|
|
97
|
+
DisclosureGroup,
|
|
98
|
+
{
|
|
99
|
+
ref,
|
|
100
|
+
allowsMultipleExpanded: allowsMultiple,
|
|
101
|
+
className: clsx(classNames.group, styles[classNames.group], className),
|
|
102
|
+
...cleanedProps
|
|
103
|
+
}
|
|
104
|
+
);
|
|
105
|
+
});
|
|
106
|
+
AccordionGroup.displayName = "AccordionGroup";
|
|
107
|
+
|
|
108
|
+
export { Accordion, AccordionGroup, AccordionPanel, AccordionTrigger };
|
|
109
|
+
//# sourceMappingURL=Accordion.esm.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Accordion.esm.js","sources":["../../../src/components/Accordion/Accordion.tsx"],"sourcesContent":["/*\n * Copyright 2025 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { forwardRef } from 'react';\nimport {\n Disclosure as RADisclosure,\n Button as RAButton,\n DisclosurePanel as RADisclosurePanel,\n DisclosureGroup as RADisclosureGroup,\n Heading as RAHeading,\n} from 'react-aria-components';\nimport { RiArrowDownSLine } from '@remixicon/react';\nimport clsx from 'clsx';\nimport type {\n AccordionProps,\n AccordionTriggerProps,\n AccordionPanelProps,\n AccordionGroupProps,\n} from './types';\nimport { useStyles } from '../../hooks/useStyles';\nimport styles from './Accordion.module.css';\nimport { Flex } from '../Flex';\n\n/** @public */\nexport const Accordion = forwardRef<\n React.ElementRef<typeof RADisclosure>,\n AccordionProps\n>(({ className, ...props }, ref) => {\n const { classNames, cleanedProps } = useStyles('Accordion', props);\n\n return (\n <RADisclosure\n ref={ref}\n className={clsx(classNames.root, styles[classNames.root], className)}\n {...cleanedProps}\n />\n );\n});\n\nAccordion.displayName = 'Accordion';\n\n/** @public */\nexport const AccordionTrigger = forwardRef<\n React.ElementRef<typeof RAHeading>,\n AccordionTriggerProps\n>(({ className, title, subtitle, children, ...props }, ref) => {\n const { classNames, cleanedProps } = useStyles('Accordion', props);\n\n return (\n <RAHeading\n ref={ref}\n className={clsx(\n classNames.trigger,\n styles[classNames.trigger],\n className,\n )}\n {...cleanedProps}\n >\n <RAButton\n slot=\"trigger\"\n className={clsx(\n classNames.triggerButton,\n styles[classNames.triggerButton],\n )}\n >\n {children ? (\n children\n ) : (\n <Flex gap=\"2\" align=\"center\">\n <span\n className={clsx(\n classNames.triggerTitle,\n styles[classNames.triggerTitle],\n )}\n >\n {title}\n </span>\n {subtitle && (\n <span\n className={clsx(\n classNames.triggerSubtitle,\n styles[classNames.triggerSubtitle],\n )}\n >\n {subtitle}\n </span>\n )}\n </Flex>\n )}\n\n <RiArrowDownSLine\n className={clsx(\n classNames.triggerIcon,\n styles[classNames.triggerIcon],\n )}\n size={16}\n />\n </RAButton>\n </RAHeading>\n );\n});\n\nAccordionTrigger.displayName = 'AccordionTrigger';\n\n/** @public */\nexport const AccordionPanel = forwardRef<\n React.ElementRef<typeof RADisclosurePanel>,\n AccordionPanelProps\n>(({ className, ...props }, ref) => {\n const { classNames, cleanedProps } = useStyles('Accordion', props);\n\n return (\n <RADisclosurePanel\n ref={ref}\n className={clsx(classNames.panel, styles[classNames.panel], className)}\n {...cleanedProps}\n />\n );\n});\n\nAccordionPanel.displayName = 'AccordionPanel';\n\n/** @public */\nexport const AccordionGroup = forwardRef<\n React.ElementRef<typeof RADisclosureGroup>,\n AccordionGroupProps\n>(({ className, allowsMultiple = false, ...props }, ref) => {\n const { classNames, cleanedProps } = useStyles('Accordion', props);\n\n return (\n <RADisclosureGroup\n ref={ref}\n allowsMultipleExpanded={allowsMultiple}\n className={clsx(classNames.group, styles[classNames.group], className)}\n {...cleanedProps}\n />\n );\n});\n\nAccordionGroup.displayName = 'AccordionGroup';\n"],"names":["RADisclosure","RAHeading","RAButton","RADisclosurePanel","RADisclosureGroup"],"mappings":";;;;;;;;;AAqCO,MAAM,SAAA,GAAY,WAGvB,CAAC,EAAE,WAAW,GAAG,KAAA,IAAS,GAAA,KAAQ;AAClC,EAAA,MAAM,EAAE,UAAA,EAAY,YAAA,EAAa,GAAI,SAAA,CAAU,aAAa,KAAK,CAAA;AAEjE,EAAA,uBACE,GAAA;AAAA,IAACA,UAAA;AAAA,IAAA;AAAA,MACC,GAAA;AAAA,MACA,SAAA,EAAW,KAAK,UAAA,CAAW,IAAA,EAAM,OAAO,UAAA,CAAW,IAAI,GAAG,SAAS,CAAA;AAAA,MAClE,GAAG;AAAA;AAAA,GACN;AAEJ,CAAC;AAED,SAAA,CAAU,WAAA,GAAc,WAAA;AAGjB,MAAM,gBAAA,GAAmB,UAAA,CAG9B,CAAC,EAAE,SAAA,EAAW,KAAA,EAAO,QAAA,EAAU,QAAA,EAAU,GAAG,KAAA,EAAM,EAAG,GAAA,KAAQ;AAC7D,EAAA,MAAM,EAAE,UAAA,EAAY,YAAA,EAAa,GAAI,SAAA,CAAU,aAAa,KAAK,CAAA;AAEjE,EAAA,uBACE,GAAA;AAAA,IAACC,OAAA;AAAA,IAAA;AAAA,MACC,GAAA;AAAA,MACA,SAAA,EAAW,IAAA;AAAA,QACT,UAAA,CAAW,OAAA;AAAA,QACX,MAAA,CAAO,WAAW,OAAO,CAAA;AAAA,QACzB;AAAA,OACF;AAAA,MACC,GAAG,YAAA;AAAA,MAEJ,QAAA,kBAAA,IAAA;AAAA,QAACC,MAAA;AAAA,QAAA;AAAA,UACC,IAAA,EAAK,SAA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AAA,CAAW,KAAA,EAAO,OAAO,UAAA,CAAW,KAAK,GAAG,SAAS,CAAA;AAAA,MACpE,GAAG;AAAA;AAAA,GACN;AAEJ,CAAC;AAED,cAAA,CAAe,WAAA,GAAc,gBAAA;AAGtB,MAAM,cAAA,GAAiB,UAAA,CAG5B,CAAC,EAAE,SAAA,EAAW,iBAAiB,KAAA,EAAO,GAAG,KAAA,EAAM,EAAG,GAAA,KAAQ;AAC1D,EAAA,MAAM,EAAE,UAAA,EAAY,YAAA,EAAa,GAAI,SAAA,CAAU,aAAa,KAAK,CAAA;AAEjE,EAAA,uBACE,GAAA;AAAA,IAACC,eAAA;AAAA,IAAA;AAAA,MACC,GAAA;AAAA,MACA,sBAAA,EAAwB,cAAA;AAAA,MACxB,SAAA,EAAW,KAAK,UAAA,CAAW,KAAA,EAAO,OAAO,UAAA,CAAW,KAAK,GAAG,SAAS,CAAA;AAAA,MACpE,GAAG;AAAA;AAAA,GACN;AAEJ,CAAC;AAED,cAAA,CAAe,WAAA,GAAc,gBAAA;;;;"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import styleInject from '../../node_modules_dist/style-inject/dist/style-inject.es.esm.js';
|
|
2
|
+
|
|
3
|
+
var css_248z = "/*\n * Copyright 2025 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n@layer tokens, base, components, utilities;\n\n@layer components {\n .Accordion-module_bui-Accordion__wEbQl {\n width: 100%;\n background-color: var(--bui-bg-surface-1);\n border-radius: var(--bui-radius-3);\n padding: var(--bui-space-3);\n }\n\n .Accordion-module_bui-AccordionTrigger__1fPAs {\n all: unset;\n width: 100%;\n display: flex;\n align-items: center;\n justify-content: space-between;\n }\n\n .Accordion-module_bui-AccordionTriggerButton__3RF1r {\n all: unset;\n width: 100%;\n color: var(--bui-fg-primary);\n display: flex;\n align-items: center;\n justify-content: space-between;\n cursor: pointer;\n text-align: left;\n\n &:focus-visible {\n outline: none;\n transition: none;\n box-shadow: inset 0 0 0 2px var(--bui-ring);\n }\n\n &[data-disabled='true'] {\n background-color: transparent;\n color: var(--bui-fg-disabled);\n cursor: not-allowed;\n }\n }\n\n .Accordion-module_bui-AccordionTriggerTitle__3DOpr {\n font-size: var(--bui-font-size-4);\n font-weight: var(--bui-font-weight-bold);\n line-height: 140%;\n }\n\n .Accordion-module_bui-AccordionTriggerSubtitle__jU446 {\n font-size: var(--bui-font-size-2);\n line-height: 140%;\n color: var(--bui-fg-secondary);\n }\n\n .Accordion-module_bui-AccordionTriggerIcon__1953s {\n transition: transform 150ms ease-out;\n flex-shrink: 0;\n width: 1rem;\n height: 1rem;\n\n [data-expanded='true'] & {\n transform: rotate(180deg);\n }\n }\n\n .Accordion-module_bui-AccordionPanel__1bJFQ {\n [data-expanded='true'] & {\n padding-top: var(--bui-space-1);\n }\n }\n\n .Accordion-module_bui-AccordionGroup__3bll0 {\n display: flex;\n flex-direction: column;\n gap: var(--bui-space-3);\n width: 100%;\n }\n}\n";
|
|
4
|
+
var styles = {"bui-Accordion":"Accordion-module_bui-Accordion__wEbQl","bui-AccordionTrigger":"Accordion-module_bui-AccordionTrigger__1fPAs","bui-AccordionTriggerButton":"Accordion-module_bui-AccordionTriggerButton__3RF1r","bui-AccordionTriggerTitle":"Accordion-module_bui-AccordionTriggerTitle__3DOpr","bui-AccordionTriggerSubtitle":"Accordion-module_bui-AccordionTriggerSubtitle__jU446","bui-AccordionTriggerIcon":"Accordion-module_bui-AccordionTriggerIcon__1953s","bui-AccordionPanel":"Accordion-module_bui-AccordionPanel__1bJFQ","bui-AccordionGroup":"Accordion-module_bui-AccordionGroup__3bll0"};
|
|
5
|
+
styleInject(css_248z);
|
|
6
|
+
|
|
7
|
+
export { styles as default };
|
|
8
|
+
//# sourceMappingURL=Accordion.module.css.esm.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Accordion.module.css.esm.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import styleInject from '../../node_modules_dist/style-inject/dist/style-inject.es.esm.js';
|
|
2
2
|
|
|
3
|
-
var css_248z = "/*\n * Copyright 2025 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n@layer tokens, base, components, utilities;\n\n@layer components {\n .Dialog-module_bui-DialogOverlay__5nqD5 {\n position: fixed;\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n background:
|
|
3
|
+
var css_248z = "/*\n * Copyright 2025 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n@layer tokens, base, components, utilities;\n\n@layer components {\n .Dialog-module_bui-DialogOverlay__5nqD5 {\n position: fixed;\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n background: color-mix(in srgb, var(--bui-gray-2) 80%, transparent);\n display: flex;\n align-items: center;\n justify-content: center;\n z-index: 1000;\n }\n\n [data-theme='dark'] .Dialog-module_bui-Dialog__Cnu24 {\n background: rgba(0, 0, 0, 0.5);\n }\n\n .Dialog-module_bui-DialogOverlay__5nqD5[data-entering] {\n animation: Dialog-module_fade-in__17nJR 200ms ease-out forwards;\n }\n\n .Dialog-module_bui-DialogOverlay__5nqD5[data-exiting] {\n animation: Dialog-module_fade-out__jMAaZ 150ms ease-out forwards;\n }\n\n .Dialog-module_bui-Dialog__Cnu24 {\n background: var(--bui-bg-surface-1);\n border-radius: 0.5rem;\n border: 1px solid var(--bui-border);\n color: var(--bui-fg-primary);\n position: relative;\n width: min(var(--bui-dialog-min-width, 400px), calc(100vw - 3rem));\n max-width: calc(100vw - 3rem);\n height: min(var(--bui-dialog-min-height, auto), calc(100vh - 3rem));\n max-height: calc(100vh - 3rem);\n display: flex;\n flex-direction: column;\n outline: none;\n }\n\n /* Dialog entering animation */\n .Dialog-module_bui-DialogOverlay__5nqD5[data-entering] .Dialog-module_bui-Dialog__Cnu24 {\n animation: Dialog-module_dialog-enter__3NC2w 150ms ease-out forwards;\n }\n\n /* Dialog exiting animation */\n .Dialog-module_bui-DialogOverlay__5nqD5[data-exiting] .Dialog-module_bui-Dialog__Cnu24 {\n animation: Dialog-module_dialog-exit__21RUM 150ms ease-out forwards;\n }\n\n .Dialog-module_bui-DialogHeader__D340y {\n display: flex;\n justify-content: space-between;\n align-items: center;\n padding-inline: var(--bui-space-3);\n padding-block: var(--bui-space-2);\n border-bottom: 1px solid var(--bui-border);\n }\n\n .Dialog-module_bui-DialogHeaderTitle__1UEkF {\n font-size: var(--bui-font-size-3);\n font-weight: var(--bui-font-weight-bold);\n margin: 0;\n }\n\n .Dialog-module_bui-DialogFooter__k2SK8 {\n display: flex;\n align-items: center;\n justify-content: end;\n gap: var(--bui-space-2);\n padding-inline: var(--bui-space-3);\n padding-block: var(--bui-space-3);\n border-top: 1px solid var(--bui-border);\n }\n\n .Dialog-module_bui-DialogBody__2olLx {\n padding: var(--bui-space-3);\n flex: 1;\n overflow-y: auto;\n }\n\n /* Keyframe animations */\n @keyframes Dialog-module_fade-in__17nJR {\n from {\n opacity: 0;\n }\n to {\n opacity: 1;\n }\n }\n\n @keyframes Dialog-module_fade-out__jMAaZ {\n from {\n opacity: 1;\n }\n to {\n opacity: 0;\n }\n }\n\n @keyframes Dialog-module_dialog-enter__3NC2w {\n from {\n opacity: 0.5;\n transform: scale(0.8);\n }\n to {\n opacity: 1;\n transform: scale(1);\n }\n }\n\n @keyframes Dialog-module_dialog-exit__21RUM {\n from {\n opacity: 1;\n transform: scale(1);\n }\n to {\n opacity: 0;\n transform: scale(0.95);\n }\n }\n}\n";
|
|
4
4
|
var styles = {"bui-DialogOverlay":"Dialog-module_bui-DialogOverlay__5nqD5","bui-Dialog":"Dialog-module_bui-Dialog__Cnu24","fade-in":"Dialog-module_fade-in__17nJR","fade-out":"Dialog-module_fade-out__jMAaZ","dialog-enter":"Dialog-module_dialog-enter__3NC2w","dialog-exit":"Dialog-module_dialog-exit__21RUM","bui-DialogHeader":"Dialog-module_bui-DialogHeader__D340y","bui-DialogHeaderTitle":"Dialog-module_bui-DialogHeaderTitle__1UEkF","bui-DialogFooter":"Dialog-module_bui-DialogFooter__k2SK8","bui-DialogBody":"Dialog-module_bui-DialogBody__2olLx"};
|
|
5
5
|
styleInject(css_248z);
|
|
6
6
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import styleInject from '../../node_modules_dist/style-inject/dist/style-inject.es.esm.js';
|
|
2
2
|
|
|
3
|
-
var css_248z = "/*\n * Copyright 2025 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n@layer tokens, base, components, utilities;\n\n@layer components {\n .Popover-module_bui-Popover__100-n {\n margin-right: 12px;\n overflow:
|
|
3
|
+
var css_248z = "/*\n * Copyright 2025 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n@layer tokens, base, components, utilities;\n\n@layer components {\n .Popover-module_bui-Popover__100-n {\n margin-right: 12px;\n overflow-x: hidden;\n overflow-y: auto;\n background-color: var(--bui-bg-surface-1);\n border: 1px solid var(--bui-border);\n border-radius: var(--bui-radius-3);\n padding-block: var(--bui-space-1);\n box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);\n }\n}\n";
|
|
4
4
|
var stylesPopover = {"bui-Popover":"Popover-module_bui-Popover__100-n"};
|
|
5
5
|
styleInject(css_248z);
|
|
6
6
|
|
|
@@ -80,7 +80,9 @@ const Select = forwardRef((props, ref) => {
|
|
|
80
80
|
{
|
|
81
81
|
className: clsx(
|
|
82
82
|
popoverClassNames.root,
|
|
83
|
-
stylesPopover[popoverClassNames.root]
|
|
83
|
+
stylesPopover[popoverClassNames.root],
|
|
84
|
+
classNames.popover,
|
|
85
|
+
styles[classNames.popover]
|
|
84
86
|
),
|
|
85
87
|
children: /* @__PURE__ */ jsx(ListBox, { className: clsx(classNames.list, styles[classNames.list]), children: options?.map((option) => /* @__PURE__ */ jsxs(
|
|
86
88
|
ListBoxItem,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Select.esm.js","sources":["../../../src/components/Select/Select.tsx"],"sourcesContent":["/*\n * Copyright 2024 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { forwardRef, useEffect } from 'react';\nimport {\n Select as AriaSelect,\n SelectValue,\n Button,\n Popover,\n ListBox,\n ListBoxItem,\n Text,\n} from 'react-aria-components';\nimport clsx from 'clsx';\nimport { SelectProps } from './types';\nimport { useStyles } from '../../hooks/useStyles';\nimport { FieldLabel } from '../FieldLabel';\nimport { FieldError } from '../FieldError';\nimport styles from './Select.module.css';\nimport stylesPopover from '../Popover/Popover.module.css';\nimport { RiArrowDownSLine, RiCheckLine } from '@remixicon/react';\n\n/** @public */\nexport const Select = forwardRef<HTMLDivElement, SelectProps>((props, ref) => {\n const { classNames: popoverClassNames } = useStyles('Popover');\n const { classNames, dataAttributes, cleanedProps } = useStyles('Select', {\n size: 'small',\n placeholder: 'Select an option',\n ...props,\n });\n\n const {\n className,\n label,\n description,\n options,\n placeholder,\n size,\n icon,\n 'aria-label': ariaLabel,\n 'aria-labelledby': ariaLabelledBy,\n isRequired,\n secondaryLabel,\n style,\n ...rest\n } = cleanedProps;\n\n useEffect(() => {\n if (!label && !ariaLabel && !ariaLabelledBy) {\n console.warn(\n 'Select requires either a visible label, aria-label, or aria-labelledby for accessibility',\n );\n }\n }, [label, ariaLabel, ariaLabelledBy]);\n\n // If a secondary label is provided, use it. Otherwise, use 'Required' if the field is required.\n const secondaryLabelText = secondaryLabel || (isRequired ? 'Required' : null);\n\n return (\n <AriaSelect\n className={clsx(classNames.root, styles[classNames.root], className)}\n {...dataAttributes}\n ref={ref}\n aria-label={ariaLabel}\n aria-labelledby={ariaLabelledBy}\n {...rest}\n >\n <FieldLabel\n label={label}\n secondaryLabel={secondaryLabelText}\n description={description}\n />\n <Button\n className={clsx(classNames.trigger, styles[classNames.trigger])}\n data-size={dataAttributes['data-size']}\n >\n {icon}\n <SelectValue\n className={clsx(classNames.value, styles[classNames.value])}\n />\n <RiArrowDownSLine aria-hidden=\"true\" />\n </Button>\n <FieldError />\n <Popover\n className={clsx(\n popoverClassNames.root,\n stylesPopover[popoverClassNames.root],\n )}\n >\n <ListBox className={clsx(classNames.list, styles[classNames.list])}>\n {options?.map(option => (\n <ListBoxItem\n key={option.value}\n id={option.value}\n className={clsx(classNames.item, styles[classNames.item])}\n >\n <div\n className={clsx(\n classNames.itemIndicator,\n styles[classNames.itemIndicator],\n )}\n >\n <RiCheckLine />\n </div>\n <Text\n slot=\"label\"\n className={clsx(\n classNames.itemLabel,\n styles[classNames.itemLabel],\n )}\n >\n {option.label}\n </Text>\n </ListBoxItem>\n ))}\n </ListBox>\n </Popover>\n </AriaSelect>\n );\n});\n\nSelect.displayName = 'Select';\n"],"names":["AriaSelect"],"mappings":";;;;;;;;;;;AAoCO,MAAM,MAAA,GAAS,UAAA,CAAwC,CAAC,KAAA,EAAO,GAAA,KAAQ;AAC5E,EAAA,MAAM,EAAE,UAAA,EAAY,iBAAA,EAAkB,GAAI,UAAU,SAAS,CAAA;AAC7D,EAAA,MAAM,EAAE,UAAA,EAAY,cAAA,EAAgB,YAAA,EAAa,GAAI,UAAU,QAAA,EAAU;AAAA,IACvE,IAAA,EAAM,OAAA;AAAA,IACN,WAAA,EAAa,kBAAA;AAAA,IACb,GAAG;AAAA,GACJ,CAAA;AAED,EAAA,MAAM;AAAA,IACJ,SAAA;AAAA,IACA,KAAA;AAAA,IACA,WAAA;AAAA,IACA,OAAA;AAAA,IACA,WAAA;AAAA,IACA,IAAA;AAAA,IACA,IAAA;AAAA,IACA,YAAA,EAAc,SAAA;AAAA,IACd,iBAAA,EAAmB,cAAA;AAAA,IACnB,UAAA;AAAA,IACA,cAAA;AAAA,IACA,KAAA;AAAA,IACA,GAAG;AAAA,GACL,GAAI,YAAA;AAEJ,EAAA,SAAA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,CAAA;AAAA,wBACZ,GAAA;AAAA,UAAC,OAAA;AAAA,UAAA;AAAA,YACC,SAAA,EAAW,IAAA;AAAA,cACT,iBAAA,CAAkB,IAAA;AAAA,cAClB,aAAA,CAAc,kBAAkB,IAAI;AAAA,
|
|
1
|
+
{"version":3,"file":"Select.esm.js","sources":["../../../src/components/Select/Select.tsx"],"sourcesContent":["/*\n * Copyright 2024 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { forwardRef, useEffect } from 'react';\nimport {\n Select as AriaSelect,\n SelectValue,\n Button,\n Popover,\n ListBox,\n ListBoxItem,\n Text,\n} from 'react-aria-components';\nimport clsx from 'clsx';\nimport { SelectProps } from './types';\nimport { useStyles } from '../../hooks/useStyles';\nimport { FieldLabel } from '../FieldLabel';\nimport { FieldError } from '../FieldError';\nimport styles from './Select.module.css';\nimport stylesPopover from '../Popover/Popover.module.css';\nimport { RiArrowDownSLine, RiCheckLine } from '@remixicon/react';\n\n/** @public */\nexport const Select = forwardRef<HTMLDivElement, SelectProps>((props, ref) => {\n const { classNames: popoverClassNames } = useStyles('Popover');\n const { classNames, dataAttributes, cleanedProps } = useStyles('Select', {\n size: 'small',\n placeholder: 'Select an option',\n ...props,\n });\n\n const {\n className,\n label,\n description,\n options,\n placeholder,\n size,\n icon,\n 'aria-label': ariaLabel,\n 'aria-labelledby': ariaLabelledBy,\n isRequired,\n secondaryLabel,\n style,\n ...rest\n } = cleanedProps;\n\n useEffect(() => {\n if (!label && !ariaLabel && !ariaLabelledBy) {\n console.warn(\n 'Select requires either a visible label, aria-label, or aria-labelledby for accessibility',\n );\n }\n }, [label, ariaLabel, ariaLabelledBy]);\n\n // If a secondary label is provided, use it. Otherwise, use 'Required' if the field is required.\n const secondaryLabelText = secondaryLabel || (isRequired ? 'Required' : null);\n\n return (\n <AriaSelect\n className={clsx(classNames.root, styles[classNames.root], className)}\n {...dataAttributes}\n ref={ref}\n aria-label={ariaLabel}\n aria-labelledby={ariaLabelledBy}\n {...rest}\n >\n <FieldLabel\n label={label}\n secondaryLabel={secondaryLabelText}\n description={description}\n />\n <Button\n className={clsx(classNames.trigger, styles[classNames.trigger])}\n data-size={dataAttributes['data-size']}\n >\n {icon}\n <SelectValue\n className={clsx(classNames.value, styles[classNames.value])}\n />\n <RiArrowDownSLine aria-hidden=\"true\" />\n </Button>\n <FieldError />\n <Popover\n className={clsx(\n popoverClassNames.root,\n stylesPopover[popoverClassNames.root],\n classNames.popover,\n styles[classNames.popover],\n )}\n >\n <ListBox className={clsx(classNames.list, styles[classNames.list])}>\n {options?.map(option => (\n <ListBoxItem\n key={option.value}\n id={option.value}\n className={clsx(classNames.item, styles[classNames.item])}\n >\n <div\n className={clsx(\n classNames.itemIndicator,\n styles[classNames.itemIndicator],\n )}\n >\n <RiCheckLine />\n </div>\n <Text\n slot=\"label\"\n className={clsx(\n classNames.itemLabel,\n styles[classNames.itemLabel],\n )}\n >\n {option.label}\n </Text>\n </ListBoxItem>\n ))}\n </ListBox>\n </Popover>\n </AriaSelect>\n );\n});\n\nSelect.displayName = 'Select';\n"],"names":["AriaSelect"],"mappings":";;;;;;;;;;;AAoCO,MAAM,MAAA,GAAS,UAAA,CAAwC,CAAC,KAAA,EAAO,GAAA,KAAQ;AAC5E,EAAA,MAAM,EAAE,UAAA,EAAY,iBAAA,EAAkB,GAAI,UAAU,SAAS,CAAA;AAC7D,EAAA,MAAM,EAAE,UAAA,EAAY,cAAA,EAAgB,YAAA,EAAa,GAAI,UAAU,QAAA,EAAU;AAAA,IACvE,IAAA,EAAM,OAAA;AAAA,IACN,WAAA,EAAa,kBAAA;AAAA,I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;AAAA,sBACC,IAAA,EAAK,OAAA;AAAA,sBACL,SAAA,EAAW,IAAA;AAAA,wBACT,UAAA,CAAW,SAAA;AAAA,wBACX,MAAA,CAAO,WAAW,SAAS;AAAA,uBAC7B;AAAA,sBAEC,QAAA,EAAA,MAAA,CAAO;AAAA;AAAA;AACV;AAAA,eAAA;AAAA,cApBK,MAAA,CAAO;AAAA,aAsBf,CAAA,EACH;AAAA;AAAA;AACF;AAAA;AAAA,GACF;AAEJ,CAAC;AAED,MAAA,CAAO,WAAA,GAAc,QAAA;;;;"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import styleInject from '../../node_modules_dist/style-inject/dist/style-inject.es.esm.js';
|
|
2
2
|
|
|
3
|
-
var css_248z = "/*\n * Copyright 2025 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n@layer tokens, base, components, utilities;\n\n@layer components {\n .Select-module_bui-
|
|
4
|
-
var styles = {"bui-
|
|
3
|
+
var css_248z = "/*\n * Copyright 2025 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n@layer tokens, base, components, utilities;\n\n@layer components {\n .Select-module_bui-SelectPopover__1vFLn {\n min-width: var(--trigger-width);\n }\n\n .Select-module_bui-SelectTrigger__3kJBt {\n box-sizing: border-box;\n border-radius: var(--bui-radius-3);\n border: 1px solid var(--bui-border);\n background-color: var(--bui-bg-surface-1);\n display: flex;\n justify-content: space-between;\n align-items: center;\n cursor: pointer;\n gap: var(--bui-space-2);\n width: 100%;\n\n & svg {\n flex-shrink: 0;\n color: var(--bui-fg-secondary);\n }\n\n &[data-size='small'] {\n height: 2rem;\n padding-inline: var(--bui-space-3);\n }\n\n &[data-size='medium'] {\n height: 3rem;\n padding-inline: var(--bui-space-4);\n }\n\n &[data-size='small'] svg {\n width: 1rem;\n height: 1rem;\n }\n\n &[data-size='medium'] svg {\n width: 1.25rem;\n height: 1.25rem;\n }\n\n &::placeholder {\n color: var(--bui-fg-secondary);\n }\n\n &:hover {\n transition: border-color 0.2s ease-in-out, outline-color 0.2s ease-in-out;\n border-color: var(--bui-border-hover);\n }\n\n &:focus-visible {\n border-color: var(--bui-border-pressed);\n outline: 0;\n }\n\n .Select-module_bui-Select__LDZ15[data-invalid] &,\n &[data-invalid] {\n border-color: var(--bui-fg-danger);\n }\n &[data-invalid]:hover {\n border-width: 2px;\n }\n\n &[data-invalid]:focus-visible {\n border-width: 2px;\n }\n\n &[disabled] {\n cursor: not-allowed;\n border-color: var(--bui-border-disabled);\n color: var(--bui-fg-disabled);\n }\n\n &[disabled] .Select-module_bui-SelectValue__jdoc- {\n color: var(--bui-fg-disabled);\n }\n\n &[data-popup-open] .Select-module_bui-SelectIcon__e97yW {\n transform: rotate(180deg);\n }\n }\n\n .Select-module_bui-SelectValue__jdoc- {\n text-overflow: ellipsis;\n overflow: hidden;\n white-space: nowrap;\n width: 100%;\n font-size: var(--bui-font-size-3);\n font-family: var(--bui-font-regular);\n font-weight: var(--bui-font-weight-regular);\n color: var(--bui-fg-primary);\n text-align: left;\n\n & .Select-module_bui-SelectItemIndicator__1y7zW {\n display: none;\n }\n\n &[disabled] {\n color: var(--bui-fg-disabled);\n }\n }\n\n .Select-module_bui-SelectList__2Cgmr:focus-visible {\n /* Remove default focus-visible outline because React Aria\n * triggers it on mouse click open of the list for some reason.\n * On keyboard use, the top item receives the focus style,\n * so it's not needed anyway. */\n outline: none;\n }\n\n .Select-module_bui-SelectItem__145pz {\n position: relative;\n width: var(--anchor-width);\n display: grid;\n grid-template-areas: 'icon text';\n grid-template-columns: 1rem 1fr;\n align-items: center;\n padding-block: var(--bui-space-2);\n padding-left: var(--bui-space-3);\n padding-right: var(--bui-space-4);\n color: var(--bui-fg-primary);\n border-radius: var(--bui-radius-3);\n cursor: pointer;\n user-select: none;\n font-size: var(--bui-font-size-3);\n gap: var(--bui-space-1);\n outline: none;\n\n &[data-focused] {\n z-index: 0;\n position: relative;\n color: var(--bui-fg-primary);\n }\n\n &[data-focused]::before {\n content: '';\n z-index: -1;\n position: absolute;\n inset-block: 0;\n inset-inline: 0.25rem;\n border-radius: 0.25rem;\n background-color: var(--bui-bg-tint-hover);\n }\n\n &[data-disabled] {\n cursor: not-allowed;\n color: var(--bui-fg-disabled);\n }\n\n &[data-selected] .Select-module_bui-SelectItemIndicator__1y7zW {\n opacity: 1;\n }\n }\n\n .Select-module_bui-SelectItemIndicator__1y7zW {\n grid-area: icon;\n display: flex;\n align-items: center;\n justify-content: center;\n opacity: 0;\n transition: opacity 0.2s ease-in-out;\n }\n\n .Select-module_bui-SelectItemLabel__1N_y- {\n flex: 1;\n grid-area: text;\n }\n}\n";
|
|
4
|
+
var styles = {"bui-SelectPopover":"Select-module_bui-SelectPopover__1vFLn","bui-SelectTrigger":"Select-module_bui-SelectTrigger__3kJBt","bui-Select":"Select-module_bui-Select__LDZ15","bui-SelectValue":"Select-module_bui-SelectValue__jdoc-","bui-SelectIcon":"Select-module_bui-SelectIcon__e97yW","bui-SelectItemIndicator":"Select-module_bui-SelectItemIndicator__1y7zW","bui-SelectList":"Select-module_bui-SelectList__2Cgmr","bui-SelectItem":"Select-module_bui-SelectItem__145pz","bui-SelectItemLabel":"Select-module_bui-SelectItemLabel__1N_y-"};
|
|
5
5
|
styleInject(css_248z);
|
|
6
6
|
|
|
7
7
|
export { styles as default };
|
package/dist/index.d.ts
CHANGED
|
@@ -1,9 +1,8 @@
|
|
|
1
1
|
import * as react from 'react';
|
|
2
2
|
import { ReactElement, ReactNode, ElementType, ComponentPropsWithRef, ComponentProps } from 'react';
|
|
3
|
-
import { ButtonProps as ButtonProps$1, DialogTriggerProps as DialogTriggerProps$1, ModalOverlayProps,
|
|
3
|
+
import { ButtonProps as ButtonProps$1, DisclosureProps, HeadingProps, DisclosurePanelProps, DisclosureGroupProps, DialogTriggerProps as DialogTriggerProps$1, ModalOverlayProps, TabsProps as TabsProps$1, TabListProps as TabListProps$1, TabProps as TabProps$1, TabPanelProps as TabPanelProps$1, LinkProps as LinkProps$1, CheckboxProps as CheckboxProps$1, RadioGroupProps as RadioGroupProps$1, RadioProps as RadioProps$1, TableProps, TableHeaderProps, TableBodyProps, ColumnProps as ColumnProps$1, CellProps as CellProps$1, RowProps, TagGroupProps as TagGroupProps$1, TagListProps, TagProps as TagProps$1, TextFieldProps as TextFieldProps$1, TooltipProps as TooltipProps$1, TooltipTriggerComponentProps, MenuTriggerProps as MenuTriggerProps$1, SubmenuTriggerProps as SubmenuTriggerProps$1, MenuProps as MenuProps$1, PopoverProps, ListBoxProps, MenuItemProps as MenuItemProps$1, ListBoxItemProps, MenuSectionProps as MenuSectionProps$1, SeparatorProps, SearchFieldProps as SearchFieldProps$1, SelectProps as SelectProps$1, SwitchProps as SwitchProps$1 } from 'react-aria-components';
|
|
4
4
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
5
5
|
import { NavigateOptions } from 'react-router-dom';
|
|
6
|
-
import { Collapsible as Collapsible$1 } from '@base-ui-components/react/collapsible';
|
|
7
6
|
|
|
8
7
|
/**
|
|
9
8
|
* Component definitions for the Backstage UI library
|
|
@@ -62,13 +61,6 @@ declare const componentDefinitions: {
|
|
|
62
61
|
readonly selected: readonly [true, false];
|
|
63
62
|
};
|
|
64
63
|
};
|
|
65
|
-
readonly Collapsible: {
|
|
66
|
-
readonly classNames: {
|
|
67
|
-
readonly root: "bui-CollapsibleRoot";
|
|
68
|
-
readonly trigger: "bui-CollapsibleTrigger";
|
|
69
|
-
readonly panel: "bui-CollapsiblePanel";
|
|
70
|
-
};
|
|
71
|
-
};
|
|
72
64
|
readonly Container: {
|
|
73
65
|
readonly classNames: {
|
|
74
66
|
readonly root: "bui-Container";
|
|
@@ -85,6 +77,18 @@ declare const componentDefinitions: {
|
|
|
85
77
|
readonly footer: "bui-DialogFooter";
|
|
86
78
|
};
|
|
87
79
|
};
|
|
80
|
+
readonly Accordion: {
|
|
81
|
+
readonly classNames: {
|
|
82
|
+
readonly root: "bui-Accordion";
|
|
83
|
+
readonly trigger: "bui-AccordionTrigger";
|
|
84
|
+
readonly triggerButton: "bui-AccordionTriggerButton";
|
|
85
|
+
readonly triggerTitle: "bui-AccordionTriggerTitle";
|
|
86
|
+
readonly triggerSubtitle: "bui-AccordionTriggerSubtitle";
|
|
87
|
+
readonly triggerIcon: "bui-AccordionTriggerIcon";
|
|
88
|
+
readonly panel: "bui-AccordionPanel";
|
|
89
|
+
readonly group: "bui-AccordionGroup";
|
|
90
|
+
};
|
|
91
|
+
};
|
|
88
92
|
readonly FieldError: {
|
|
89
93
|
readonly classNames: {
|
|
90
94
|
readonly root: "bui-FieldError";
|
|
@@ -226,6 +230,7 @@ declare const componentDefinitions: {
|
|
|
226
230
|
readonly Select: {
|
|
227
231
|
readonly classNames: {
|
|
228
232
|
readonly root: "bui-Select";
|
|
233
|
+
readonly popover: "bui-SelectPopover";
|
|
229
234
|
readonly trigger: "bui-SelectTrigger";
|
|
230
235
|
readonly value: "bui-SelectValue";
|
|
231
236
|
readonly icon: "bui-SelectIcon";
|
|
@@ -610,16 +615,50 @@ declare const CardBody: react.ForwardRefExoticComponent<CardBodyProps & react.Re
|
|
|
610
615
|
declare const CardFooter: react.ForwardRefExoticComponent<CardFooterProps & react.RefAttributes<HTMLDivElement>>;
|
|
611
616
|
|
|
612
617
|
/**
|
|
613
|
-
*
|
|
614
|
-
* It is a wrapper around the CollapsiblePrimitive component from base-ui-components.
|
|
615
|
-
*
|
|
618
|
+
* Props for the Accordion component.
|
|
616
619
|
* @public
|
|
617
620
|
*/
|
|
618
|
-
|
|
619
|
-
|
|
620
|
-
|
|
621
|
-
|
|
622
|
-
|
|
621
|
+
interface AccordionProps extends DisclosureProps {
|
|
622
|
+
className?: string;
|
|
623
|
+
}
|
|
624
|
+
/**
|
|
625
|
+
* Props for the AccordionTrigger component.
|
|
626
|
+
* @public
|
|
627
|
+
*/
|
|
628
|
+
interface AccordionTriggerProps extends HeadingProps {
|
|
629
|
+
className?: string;
|
|
630
|
+
title?: string;
|
|
631
|
+
subtitle?: string;
|
|
632
|
+
children?: React.ReactNode;
|
|
633
|
+
}
|
|
634
|
+
/**
|
|
635
|
+
* Props for the AccordionPanel component.
|
|
636
|
+
* @public
|
|
637
|
+
*/
|
|
638
|
+
interface AccordionPanelProps extends DisclosurePanelProps {
|
|
639
|
+
className?: string;
|
|
640
|
+
}
|
|
641
|
+
/**
|
|
642
|
+
* Props for the AccordionGroup component.
|
|
643
|
+
* @public
|
|
644
|
+
*/
|
|
645
|
+
interface AccordionGroupProps extends DisclosureGroupProps {
|
|
646
|
+
className?: string;
|
|
647
|
+
/**
|
|
648
|
+
* Whether multiple accordions can be expanded at the same time.
|
|
649
|
+
* @defaultValue false
|
|
650
|
+
*/
|
|
651
|
+
allowsMultiple?: boolean;
|
|
652
|
+
}
|
|
653
|
+
|
|
654
|
+
/** @public */
|
|
655
|
+
declare const Accordion: react.ForwardRefExoticComponent<AccordionProps & react.RefAttributes<HTMLDivElement>>;
|
|
656
|
+
/** @public */
|
|
657
|
+
declare const AccordionTrigger: react.ForwardRefExoticComponent<AccordionTriggerProps & react.RefAttributes<HTMLHeadingElement>>;
|
|
658
|
+
/** @public */
|
|
659
|
+
declare const AccordionPanel: react.ForwardRefExoticComponent<AccordionPanelProps & react.RefAttributes<HTMLDivElement>>;
|
|
660
|
+
/** @public */
|
|
661
|
+
declare const AccordionGroup: react.ForwardRefExoticComponent<AccordionGroupProps & react.RefAttributes<HTMLDivElement>>;
|
|
623
662
|
|
|
624
663
|
/**
|
|
625
664
|
* Props for the DialogTrigger component.
|
|
@@ -1292,4 +1331,4 @@ declare const useBreakpoint: () => {
|
|
|
1292
1331
|
down: (key: Breakpoint) => boolean;
|
|
1293
1332
|
};
|
|
1294
1333
|
|
|
1295
|
-
export { type AlignItems, Avatar, type AvatarProps, type Border, type BorderRadius, Box, type BoxProps, type Breakpoint, Button, ButtonIcon, type ButtonIconProps, ButtonLink, type ButtonLinkProps, type ButtonProps, Card, CardBody, type CardBodyProps, CardFooter, type CardFooterProps, CardHeader, type CardHeaderProps, type CardProps, Cell, CellProfile, type CellProfileProps, type CellProps, Checkbox, type CheckboxProps, type ClassNamesMap,
|
|
1334
|
+
export { Accordion, AccordionGroup, type AccordionGroupProps, AccordionPanel, type AccordionPanelProps, type AccordionProps, AccordionTrigger, type AccordionTriggerProps, type AlignItems, Avatar, type AvatarProps, type Border, type BorderRadius, Box, type BoxProps, type Breakpoint, Button, ButtonIcon, type ButtonIconProps, ButtonLink, type ButtonLinkProps, type ButtonProps, Card, CardBody, type CardBodyProps, CardFooter, type CardFooterProps, CardHeader, type CardHeaderProps, type CardProps, Cell, CellProfile, type CellProfileProps, type CellProps, Checkbox, type CheckboxProps, type ClassNamesMap, Column, type ColumnProps, type Columns, type ComponentClassNames, type ComponentDefinition, type ComponentDefinitionName, Container, type ContainerProps, type DataAttributeValues, type DataAttributesMap, Dialog, DialogBody, type DialogBodyProps, DialogFooter, DialogHeader, type DialogHeaderProps, type DialogProps, DialogTrigger, type DialogTriggerProps, type Display, FieldLabel, type FieldLabelProps, Flex, type FlexDirection, type FlexProps, type FlexWrap, Grid, type GridItemProps, type GridProps, Header, HeaderPage, type HeaderPageBreadcrumb, type HeaderPageProps, type HeaderProps, type HeaderTab, type JustifyContent, Link, type LinkProps, Menu, MenuAutocomplete, type MenuAutocompleteListBoxProps, MenuAutocompleteListbox, type MenuAutocompleteProps, MenuItem, type MenuItemProps, MenuListBox, MenuListBoxItem, type MenuListBoxItemProps, type MenuListBoxProps, type MenuProps, MenuSection, type MenuSectionProps, MenuSeparator, type MenuSeparatorProps, MenuTrigger, type MenuTriggerProps, Radio, RadioGroup, type RadioGroupProps, type RadioProps, type Responsive, Row, SearchField, type SearchFieldProps, Select, type SelectProps, Skeleton, type SkeletonProps, type Space, type SpaceProps, SubmenuTrigger, type SubmenuTriggerProps, Switch, type SwitchProps, Tab, TabList, type TabListProps, type TabMatchStrategy, TabPanel, type TabPanelProps, type TabProps, Table, TableBody, TableHeader, TablePagination, type TablePaginationProps, Tabs, type TabsProps, Tag, TagGroup, type TagGroupProps, type TagProps, Text, type TextColorStatus, type TextColors, TextField, type TextFieldProps, type TextOwnProps, type TextProps, type TextVariants, type TextWeights, Tooltip, type TooltipProps, TooltipTrigger, type UseTableConfig, type UseTablePagination, type UseTablePaginationConfig, type UseTableResult, type UtilityProps, VisuallyHidden, type VisuallyHiddenProps, componentDefinitions, useBreakpoint, useTable };
|
package/dist/index.esm.js
CHANGED
|
@@ -5,7 +5,7 @@ export { Container } from './components/Container/Container.esm.js';
|
|
|
5
5
|
export { Avatar } from './components/Avatar/Avatar.esm.js';
|
|
6
6
|
export { Button } from './components/Button/Button.esm.js';
|
|
7
7
|
export { Card, CardBody, CardFooter, CardHeader } from './components/Card/Card.esm.js';
|
|
8
|
-
export {
|
|
8
|
+
export { Accordion, AccordionGroup, AccordionPanel, AccordionTrigger } from './components/Accordion/Accordion.esm.js';
|
|
9
9
|
export { Dialog, DialogBody, DialogFooter, DialogHeader, DialogTrigger } from './components/Dialog/Dialog.esm.js';
|
|
10
10
|
export { FieldLabel } from './components/FieldLabel/FieldLabel.esm.js';
|
|
11
11
|
export { Header } from './components/Header/Header.esm.js';
|
|
@@ -74,13 +74,6 @@ const componentDefinitions = {
|
|
|
74
74
|
selected: [true, false]
|
|
75
75
|
}
|
|
76
76
|
},
|
|
77
|
-
Collapsible: {
|
|
78
|
-
classNames: {
|
|
79
|
-
root: "bui-CollapsibleRoot",
|
|
80
|
-
trigger: "bui-CollapsibleTrigger",
|
|
81
|
-
panel: "bui-CollapsiblePanel"
|
|
82
|
-
}
|
|
83
|
-
},
|
|
84
77
|
Container: {
|
|
85
78
|
classNames: {
|
|
86
79
|
root: "bui-Container"
|
|
@@ -97,6 +90,18 @@ const componentDefinitions = {
|
|
|
97
90
|
footer: "bui-DialogFooter"
|
|
98
91
|
}
|
|
99
92
|
},
|
|
93
|
+
Accordion: {
|
|
94
|
+
classNames: {
|
|
95
|
+
root: "bui-Accordion",
|
|
96
|
+
trigger: "bui-AccordionTrigger",
|
|
97
|
+
triggerButton: "bui-AccordionTriggerButton",
|
|
98
|
+
triggerTitle: "bui-AccordionTriggerTitle",
|
|
99
|
+
triggerSubtitle: "bui-AccordionTriggerSubtitle",
|
|
100
|
+
triggerIcon: "bui-AccordionTriggerIcon",
|
|
101
|
+
panel: "bui-AccordionPanel",
|
|
102
|
+
group: "bui-AccordionGroup"
|
|
103
|
+
}
|
|
104
|
+
},
|
|
100
105
|
FieldError: {
|
|
101
106
|
classNames: {
|
|
102
107
|
root: "bui-FieldError"
|
|
@@ -274,6 +279,7 @@ const componentDefinitions = {
|
|
|
274
279
|
Select: {
|
|
275
280
|
classNames: {
|
|
276
281
|
root: "bui-Select",
|
|
282
|
+
popover: "bui-SelectPopover",
|
|
277
283
|
trigger: "bui-SelectTrigger",
|
|
278
284
|
value: "bui-SelectValue",
|
|
279
285
|
icon: "bui-SelectIcon",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"componentDefinitions.esm.js","sources":["../../src/utils/componentDefinitions.ts"],"sourcesContent":["/*\n * Copyright 2024 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport type { ComponentDefinition } from '../types';\n\n/**\n * Component definitions for the Backstage UI library\n * @public\n */\nexport const componentDefinitions = {\n Avatar: {\n classNames: {\n root: 'bui-AvatarRoot',\n image: 'bui-AvatarImage',\n fallback: 'bui-AvatarFallback',\n },\n dataAttributes: {\n size: ['small', 'medium', 'large'] as const,\n },\n },\n Box: {\n classNames: {\n root: 'bui-Box',\n },\n utilityProps: [\n 'm',\n 'mb',\n 'ml',\n 'mr',\n 'mt',\n 'mx',\n 'my',\n 'p',\n 'pb',\n 'pl',\n 'pr',\n 'pt',\n 'px',\n 'py',\n 'position',\n 'display',\n 'width',\n 'minWidth',\n 'maxWidth',\n 'height',\n 'minHeight',\n 'maxHeight',\n ],\n },\n Button: {\n classNames: {\n root: 'bui-Button',\n },\n dataAttributes: {\n size: ['small', 'medium', 'large'] as const,\n variant: ['primary', 'secondary', 'tertiary'] as const,\n },\n },\n ButtonIcon: {\n classNames: {\n root: 'bui-ButtonIcon',\n },\n },\n ButtonLink: {\n classNames: {\n root: 'bui-ButtonLink',\n },\n },\n Card: {\n classNames: {\n root: 'bui-Card',\n header: 'bui-CardHeader',\n body: 'bui-CardBody',\n footer: 'bui-CardFooter',\n },\n },\n Checkbox: {\n classNames: {\n root: 'bui-Checkbox',\n indicator: 'bui-CheckboxIndicator',\n },\n dataAttributes: {\n selected: [true, false] as const,\n },\n },\n Collapsible: {\n classNames: {\n root: 'bui-CollapsibleRoot',\n trigger: 'bui-CollapsibleTrigger',\n panel: 'bui-CollapsiblePanel',\n },\n },\n Container: {\n classNames: {\n root: 'bui-Container',\n },\n utilityProps: ['my', 'mt', 'mb', 'py', 'pt', 'pb', 'display'],\n },\n Dialog: {\n classNames: {\n overlay: 'bui-DialogOverlay',\n dialog: 'bui-Dialog',\n header: 'bui-DialogHeader',\n headerTitle: 'bui-DialogHeaderTitle',\n body: 'bui-DialogBody',\n footer: 'bui-DialogFooter',\n },\n },\n FieldError: {\n classNames: {\n root: 'bui-FieldError',\n },\n },\n FieldLabel: {\n classNames: {\n root: 'bui-FieldLabelWrapper',\n label: 'bui-FieldLabel',\n secondaryLabel: 'bui-FieldSecondaryLabel',\n description: 'bui-FieldDescription',\n },\n },\n Flex: {\n classNames: {\n root: 'bui-Flex',\n },\n utilityProps: [\n 'm',\n 'mb',\n 'ml',\n 'mr',\n 'mt',\n 'mx',\n 'my',\n 'p',\n 'pb',\n 'pl',\n 'pr',\n 'pt',\n 'px',\n 'py',\n 'gap',\n 'align',\n 'justify',\n 'direction',\n ],\n },\n Grid: {\n classNames: {\n root: 'bui-Grid',\n },\n utilityProps: [\n 'columns',\n 'gap',\n 'm',\n 'mb',\n 'ml',\n 'mr',\n 'mt',\n 'mx',\n 'my',\n 'p',\n 'pb',\n 'pl',\n 'pr',\n 'pt',\n 'px',\n 'py',\n ],\n },\n GridItem: {\n classNames: {\n root: 'bui-GridItem',\n },\n utilityProps: ['colSpan', 'colEnd', 'colStart', 'rowSpan'],\n },\n Header: {\n classNames: {\n toolbar: 'bui-HeaderToolbar',\n toolbarWrapper: 'bui-HeaderToolbarWrapper',\n toolbarContent: 'bui-HeaderToolbarContent',\n toolbarControls: 'bui-HeaderToolbarControls',\n toolbarIcon: 'bui-HeaderToolbarIcon',\n toolbarName: 'bui-HeaderToolbarName',\n tabsWrapper: 'bui-HeaderTabsWrapper',\n },\n },\n HeaderPage: {\n classNames: {\n root: 'bui-HeaderPage',\n content: 'bui-HeaderPageContent',\n breadcrumbs: 'bui-HeaderPageBreadcrumbs',\n tabsWrapper: 'bui-HeaderPageTabsWrapper',\n controls: 'bui-HeaderPageControls',\n },\n },\n Heading: {\n classNames: {\n root: 'bui-Heading',\n },\n dataAttributes: {\n variant: ['title1', 'title2', 'title3', 'subtitle'] as const,\n color: ['primary', 'secondary', 'muted'] as const,\n truncate: [true, false] as const,\n },\n },\n Icon: {\n classNames: {\n root: 'bui-Icon',\n },\n },\n Link: {\n classNames: {\n root: 'bui-Link',\n },\n dataAttributes: {\n variant: ['subtitle', 'body', 'caption', 'label'] as const,\n weight: ['regular', 'bold'] as const,\n color: ['primary', 'secondary', 'danger', 'warning', 'success'] as const,\n truncate: [true, false] as const,\n },\n },\n List: {\n classNames: {\n root: 'bui-List',\n row: 'bui-ListRow',\n label: 'bui-ListLabel',\n },\n },\n Menu: {\n classNames: {\n root: 'bui-Menu',\n popover: 'bui-MenuPopover',\n content: 'bui-MenuContent',\n section: 'bui-MenuSection',\n sectionHeader: 'bui-MenuSectionHeader',\n item: 'bui-MenuItem',\n itemListBox: 'bui-MenuItemListBox',\n itemListBoxCheck: 'bui-MenuItemListBoxCheck',\n itemWrapper: 'bui-MenuItemWrapper',\n itemContent: 'bui-MenuItemContent',\n itemArrow: 'bui-MenuItemArrow',\n separator: 'bui-MenuSeparator',\n searchField: 'bui-MenuSearchField',\n searchFieldInput: 'bui-MenuSearchFieldInput',\n searchFieldClear: 'bui-MenuSearchFieldClear',\n emptyState: 'bui-MenuEmptyState',\n },\n },\n PasswordField: {\n classNames: {\n root: 'bui-PasswordField',\n inputVisibility: 'bui-InputVisibility',\n },\n dataAttributes: {\n size: ['small', 'medium'] as const,\n },\n },\n Popover: {\n classNames: {\n root: 'bui-Popover',\n },\n },\n RadioGroup: {\n classNames: {\n root: 'bui-RadioGroup',\n content: 'bui-RadioGroupContent',\n radio: 'bui-Radio',\n },\n },\n SearchField: {\n classNames: {\n root: 'bui-SearchField',\n clear: 'bui-SearchFieldClear',\n inputWrapper: 'bui-SearchFieldWrapper',\n input: 'bui-SearchFieldInput',\n inputIcon: 'bui-SearchFieldInputIcon',\n },\n dataAttributes: {\n startCollapsed: [true, false] as const,\n size: ['small', 'medium'] as const,\n },\n },\n Select: {\n classNames: {\n root: 'bui-Select',\n trigger: 'bui-SelectTrigger',\n value: 'bui-SelectValue',\n icon: 'bui-SelectIcon',\n list: 'bui-SelectList',\n item: 'bui-SelectItem',\n itemIndicator: 'bui-SelectItemIndicator',\n itemLabel: 'bui-SelectItemLabel',\n },\n dataAttributes: {\n size: ['small', 'medium'] as const,\n },\n },\n Skeleton: {\n classNames: {\n root: 'bui-Skeleton',\n },\n },\n Switch: {\n classNames: {\n root: 'bui-Switch',\n indicator: 'bui-SwitchIndicator',\n },\n },\n Table: {\n classNames: {\n table: 'bui-Table',\n header: 'bui-TableHeader',\n body: 'bui-TableBody',\n row: 'bui-TableRow',\n head: 'bui-TableHead',\n headContent: 'bui-TableHeadContent',\n headSortButton: 'bui-TableHeadSortButton',\n caption: 'bui-TableCaption',\n cell: 'bui-TableCell',\n cellContentWrapper: 'bui-TableCellContentWrapper',\n cellContent: 'bui-TableCellContent',\n cellIcon: 'bui-TableCellIcon',\n cellProfileAvatar: 'bui-TableCellProfileAvatar',\n cellProfileAvatarImage: 'bui-TableCellProfileAvatarImage',\n cellProfileAvatarFallback: 'bui-TableCellProfileAvatarFallback',\n cellProfileName: 'bui-TableCellProfileName',\n cellProfileLink: 'bui-TableCellProfileLink',\n },\n },\n TablePagination: {\n classNames: {\n root: 'bui-TablePagination',\n left: 'bui-TablePaginationLeft',\n right: 'bui-TablePaginationRight',\n select: 'bui-TablePaginationSelect',\n },\n },\n Tabs: {\n classNames: {\n tabs: 'bui-Tabs',\n tabList: 'bui-TabList',\n tabListWrapper: 'bui-TabListWrapper',\n tab: 'bui-Tab',\n tabActive: 'bui-TabActive',\n tabHovered: 'bui-TabHovered',\n panel: 'bui-TabPanel',\n },\n },\n TagGroup: {\n classNames: {\n group: 'bui-TagGroup',\n list: 'bui-TagList',\n tag: 'bui-Tag',\n tagIcon: 'bui-TagIcon',\n tagRemoveButton: 'bui-TagRemoveButton',\n },\n },\n Text: {\n classNames: {\n root: 'bui-Text',\n },\n dataAttributes: {\n variant: ['subtitle', 'body', 'caption', 'label'] as const,\n weight: ['regular', 'bold'] as const,\n color: ['primary', 'secondary', 'danger', 'warning', 'success'] as const,\n truncate: [true, false] as const,\n },\n },\n TextField: {\n classNames: {\n root: 'bui-TextField',\n inputWrapper: 'bui-InputWrapper',\n input: 'bui-Input',\n inputIcon: 'bui-InputIcon',\n inputAction: 'bui-InputAction',\n },\n dataAttributes: {\n invalid: [true, false] as const,\n disabled: [true, false] as const,\n size: ['small', 'medium'] as const,\n },\n },\n Tooltip: {\n classNames: {\n tooltip: 'bui-Tooltip',\n arrow: 'bui-TooltipArrow',\n },\n },\n VisuallyHidden: {\n classNames: {\n root: 'bui-VisuallyHidden',\n },\n },\n} as const satisfies Record<string, ComponentDefinition>;\n"],"names":[],"mappings":"AAsBO,MAAM,oBAAA,GAAuB;AAAA,EAClC,MAAA,EAAQ;AAAA,IACN,UAAA,EAAY;AAAA,MACV,IAAA,EAAM,gBAAA;AAAA,MACN,KAAA,EAAO,iBAAA;AAAA,MACP,QAAA,EAAU;AAAA,KACZ;AAAA,IACA,cAAA,EAAgB;AAAA,MACd,IAAA,EAAM,CAAC,OAAA,EAAS,QAAA,EAAU,OAAO;AAAA;AACnC,GACF;AAAA,EACA,GAAA,EAAK;AAAA,IACH,UAAA,EAAY;AAAA,MACV,IAAA,EAAM;AAAA,KACR;AAAA,IACA,YAAA,EAAc;AAAA,MACZ,GAAA;AAAA,MACA,IAAA;AAAA,MACA,IAAA;AAAA,MACA,IAAA;AAAA,MACA,IAAA;AAAA,MACA,IAAA;AAAA,MACA,IAAA;AAAA,MACA,GAAA;AAAA,MACA,IAAA;AAAA,MACA,IAAA;AAAA,MACA,IAAA;AAAA,MACA,IAAA;AAAA,MACA,IAAA;AAAA,MACA,IAAA;AAAA,MACA,UAAA;AAAA,MACA,SAAA;AAAA,MACA,OAAA;AAAA,MACA,UAAA;AAAA,MACA,UAAA;AAAA,MACA,QAAA;AAAA,MACA,WAAA;AAAA,MACA;AAAA;AACF,GACF;AAAA,EACA,MAAA,EAAQ;AAAA,IACN,UAAA,EAAY;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,IAAA,EAAM,KAAK;AAAA;AACxB,GACF;AAAA,EACA,SAAA,EAAW;AAAA,IACT,UAAA,EAAY;AAAA,MACV,IAAA,EAAM,eAAA;AAAA,MACN,YAAA,EAAc,kBAAA;AAAA,MACd,KAAA,EAAO,WAAA;AAAA,MACP,SAAA,EAAW,eAAA;AAAA,MACX,WAAA,EAAa;AAAA,KACf;AAAA,IACA,cAAA,EAAgB;AAAA,MACd,OAAA,EAAS,CAAC,IAAA,EAAM,KAAK,CAAA;AAAA,MACrB,QAAA,EAAU,CAAC,IAAA,EAAM,KAAK,CAAA;AAAA,MACtB,IAAA,EAAM,CAAC,OAAA,EAAS,QAAQ;AAAA;AAC1B,GACF;AAAA,EACA,OAAA,EAAS;AAAA,IACP,UAAA,EAAY;AAAA,MACV,OAAA,EAAS,aAAA;AAAA,MACT,KAAA,EAAO;AAAA;AACT,GACF;AAAA,EACA,cAAA,EAAgB;AAAA,IACd,UAAA,EAAY;AAAA,MACV,IAAA,EAAM;AAAA;AACR;AAEJ;;;;"}
|
|
1
|
+
{"version":3,"file":"componentDefinitions.esm.js","sources":["../../src/utils/componentDefinitions.ts"],"sourcesContent":["/*\n * Copyright 2024 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport type { ComponentDefinition } from '../types';\n\n/**\n * Component definitions for the Backstage UI library\n * @public\n */\nexport const componentDefinitions = {\n Avatar: {\n classNames: {\n root: 'bui-AvatarRoot',\n image: 'bui-AvatarImage',\n fallback: 'bui-AvatarFallback',\n },\n dataAttributes: {\n size: ['small', 'medium', 'large'] as const,\n },\n },\n Box: {\n classNames: {\n root: 'bui-Box',\n },\n utilityProps: [\n 'm',\n 'mb',\n 'ml',\n 'mr',\n 'mt',\n 'mx',\n 'my',\n 'p',\n 'pb',\n 'pl',\n 'pr',\n 'pt',\n 'px',\n 'py',\n 'position',\n 'display',\n 'width',\n 'minWidth',\n 'maxWidth',\n 'height',\n 'minHeight',\n 'maxHeight',\n ],\n },\n Button: {\n classNames: {\n root: 'bui-Button',\n },\n dataAttributes: {\n size: ['small', 'medium', 'large'] as const,\n variant: ['primary', 'secondary', 'tertiary'] as const,\n },\n },\n ButtonIcon: {\n classNames: {\n root: 'bui-ButtonIcon',\n },\n },\n ButtonLink: {\n classNames: {\n root: 'bui-ButtonLink',\n },\n },\n Card: {\n classNames: {\n root: 'bui-Card',\n header: 'bui-CardHeader',\n body: 'bui-CardBody',\n footer: 'bui-CardFooter',\n },\n },\n Checkbox: {\n classNames: {\n root: 'bui-Checkbox',\n indicator: 'bui-CheckboxIndicator',\n },\n dataAttributes: {\n selected: [true, false] as const,\n },\n },\n Container: {\n classNames: {\n root: 'bui-Container',\n },\n utilityProps: ['my', 'mt', 'mb', 'py', 'pt', 'pb', 'display'],\n },\n Dialog: {\n classNames: {\n overlay: 'bui-DialogOverlay',\n dialog: 'bui-Dialog',\n header: 'bui-DialogHeader',\n headerTitle: 'bui-DialogHeaderTitle',\n body: 'bui-DialogBody',\n footer: 'bui-DialogFooter',\n },\n },\n Accordion: {\n classNames: {\n root: 'bui-Accordion',\n trigger: 'bui-AccordionTrigger',\n triggerButton: 'bui-AccordionTriggerButton',\n triggerTitle: 'bui-AccordionTriggerTitle',\n triggerSubtitle: 'bui-AccordionTriggerSubtitle',\n triggerIcon: 'bui-AccordionTriggerIcon',\n panel: 'bui-AccordionPanel',\n group: 'bui-AccordionGroup',\n },\n },\n FieldError: {\n classNames: {\n root: 'bui-FieldError',\n },\n },\n FieldLabel: {\n classNames: {\n root: 'bui-FieldLabelWrapper',\n label: 'bui-FieldLabel',\n secondaryLabel: 'bui-FieldSecondaryLabel',\n description: 'bui-FieldDescription',\n },\n },\n Flex: {\n classNames: {\n root: 'bui-Flex',\n },\n utilityProps: [\n 'm',\n 'mb',\n 'ml',\n 'mr',\n 'mt',\n 'mx',\n 'my',\n 'p',\n 'pb',\n 'pl',\n 'pr',\n 'pt',\n 'px',\n 'py',\n 'gap',\n 'align',\n 'justify',\n 'direction',\n ],\n },\n Grid: {\n classNames: {\n root: 'bui-Grid',\n },\n utilityProps: [\n 'columns',\n 'gap',\n 'm',\n 'mb',\n 'ml',\n 'mr',\n 'mt',\n 'mx',\n 'my',\n 'p',\n 'pb',\n 'pl',\n 'pr',\n 'pt',\n 'px',\n 'py',\n ],\n },\n GridItem: {\n classNames: {\n root: 'bui-GridItem',\n },\n utilityProps: ['colSpan', 'colEnd', 'colStart', 'rowSpan'],\n },\n Header: {\n classNames: {\n toolbar: 'bui-HeaderToolbar',\n toolbarWrapper: 'bui-HeaderToolbarWrapper',\n toolbarContent: 'bui-HeaderToolbarContent',\n toolbarControls: 'bui-HeaderToolbarControls',\n toolbarIcon: 'bui-HeaderToolbarIcon',\n toolbarName: 'bui-HeaderToolbarName',\n tabsWrapper: 'bui-HeaderTabsWrapper',\n },\n },\n HeaderPage: {\n classNames: {\n root: 'bui-HeaderPage',\n content: 'bui-HeaderPageContent',\n breadcrumbs: 'bui-HeaderPageBreadcrumbs',\n tabsWrapper: 'bui-HeaderPageTabsWrapper',\n controls: 'bui-HeaderPageControls',\n },\n },\n Heading: {\n classNames: {\n root: 'bui-Heading',\n },\n dataAttributes: {\n variant: ['title1', 'title2', 'title3', 'subtitle'] as const,\n color: ['primary', 'secondary', 'muted'] as const,\n truncate: [true, false] as const,\n },\n },\n Icon: {\n classNames: {\n root: 'bui-Icon',\n },\n },\n Link: {\n classNames: {\n root: 'bui-Link',\n },\n dataAttributes: {\n variant: ['subtitle', 'body', 'caption', 'label'] as const,\n weight: ['regular', 'bold'] as const,\n color: ['primary', 'secondary', 'danger', 'warning', 'success'] as const,\n truncate: [true, false] as const,\n },\n },\n List: {\n classNames: {\n root: 'bui-List',\n row: 'bui-ListRow',\n label: 'bui-ListLabel',\n },\n },\n Menu: {\n classNames: {\n root: 'bui-Menu',\n popover: 'bui-MenuPopover',\n content: 'bui-MenuContent',\n section: 'bui-MenuSection',\n sectionHeader: 'bui-MenuSectionHeader',\n item: 'bui-MenuItem',\n itemListBox: 'bui-MenuItemListBox',\n itemListBoxCheck: 'bui-MenuItemListBoxCheck',\n itemWrapper: 'bui-MenuItemWrapper',\n itemContent: 'bui-MenuItemContent',\n itemArrow: 'bui-MenuItemArrow',\n separator: 'bui-MenuSeparator',\n searchField: 'bui-MenuSearchField',\n searchFieldInput: 'bui-MenuSearchFieldInput',\n searchFieldClear: 'bui-MenuSearchFieldClear',\n emptyState: 'bui-MenuEmptyState',\n },\n },\n PasswordField: {\n classNames: {\n root: 'bui-PasswordField',\n inputVisibility: 'bui-InputVisibility',\n },\n dataAttributes: {\n size: ['small', 'medium'] as const,\n },\n },\n Popover: {\n classNames: {\n root: 'bui-Popover',\n },\n },\n RadioGroup: {\n classNames: {\n root: 'bui-RadioGroup',\n content: 'bui-RadioGroupContent',\n radio: 'bui-Radio',\n },\n },\n SearchField: {\n classNames: {\n root: 'bui-SearchField',\n clear: 'bui-SearchFieldClear',\n inputWrapper: 'bui-SearchFieldWrapper',\n input: 'bui-SearchFieldInput',\n inputIcon: 'bui-SearchFieldInputIcon',\n },\n dataAttributes: {\n startCollapsed: [true, false] as const,\n size: ['small', 'medium'] as const,\n },\n },\n Select: {\n classNames: {\n root: 'bui-Select',\n popover: 'bui-SelectPopover',\n trigger: 'bui-SelectTrigger',\n value: 'bui-SelectValue',\n icon: 'bui-SelectIcon',\n list: 'bui-SelectList',\n item: 'bui-SelectItem',\n itemIndicator: 'bui-SelectItemIndicator',\n itemLabel: 'bui-SelectItemLabel',\n },\n dataAttributes: {\n size: ['small', 'medium'] as const,\n },\n },\n Skeleton: {\n classNames: {\n root: 'bui-Skeleton',\n },\n },\n Switch: {\n classNames: {\n root: 'bui-Switch',\n indicator: 'bui-SwitchIndicator',\n },\n },\n Table: {\n classNames: {\n table: 'bui-Table',\n header: 'bui-TableHeader',\n body: 'bui-TableBody',\n row: 'bui-TableRow',\n head: 'bui-TableHead',\n headContent: 'bui-TableHeadContent',\n headSortButton: 'bui-TableHeadSortButton',\n caption: 'bui-TableCaption',\n cell: 'bui-TableCell',\n cellContentWrapper: 'bui-TableCellContentWrapper',\n cellContent: 'bui-TableCellContent',\n cellIcon: 'bui-TableCellIcon',\n cellProfileAvatar: 'bui-TableCellProfileAvatar',\n cellProfileAvatarImage: 'bui-TableCellProfileAvatarImage',\n cellProfileAvatarFallback: 'bui-TableCellProfileAvatarFallback',\n cellProfileName: 'bui-TableCellProfileName',\n cellProfileLink: 'bui-TableCellProfileLink',\n },\n },\n TablePagination: {\n classNames: {\n root: 'bui-TablePagination',\n left: 'bui-TablePaginationLeft',\n right: 'bui-TablePaginationRight',\n select: 'bui-TablePaginationSelect',\n },\n },\n Tabs: {\n classNames: {\n tabs: 'bui-Tabs',\n tabList: 'bui-TabList',\n tabListWrapper: 'bui-TabListWrapper',\n tab: 'bui-Tab',\n tabActive: 'bui-TabActive',\n tabHovered: 'bui-TabHovered',\n panel: 'bui-TabPanel',\n },\n },\n TagGroup: {\n classNames: {\n group: 'bui-TagGroup',\n list: 'bui-TagList',\n tag: 'bui-Tag',\n tagIcon: 'bui-TagIcon',\n tagRemoveButton: 'bui-TagRemoveButton',\n },\n },\n Text: {\n classNames: {\n root: 'bui-Text',\n },\n dataAttributes: {\n variant: ['subtitle', 'body', 'caption', 'label'] as const,\n weight: ['regular', 'bold'] as const,\n color: ['primary', 'secondary', 'danger', 'warning', 'success'] as const,\n truncate: [true, false] as const,\n },\n },\n TextField: {\n classNames: {\n root: 'bui-TextField',\n inputWrapper: 'bui-InputWrapper',\n input: 'bui-Input',\n inputIcon: 'bui-InputIcon',\n inputAction: 'bui-InputAction',\n },\n dataAttributes: {\n invalid: [true, false] as const,\n disabled: [true, false] as const,\n size: ['small', 'medium'] as const,\n },\n },\n Tooltip: {\n classNames: {\n tooltip: 'bui-Tooltip',\n arrow: 'bui-TooltipArrow',\n },\n },\n VisuallyHidden: {\n classNames: {\n root: 'bui-VisuallyHidden',\n },\n },\n} as const satisfies Record<string, ComponentDefinition>;\n"],"names":[],"mappings":"AAsBO,MAAM,oBAAA,GAAuB;AAAA,EAClC,MAAA,EAAQ;AAAA,IACN,UAAA,EAAY;AAAA,MACV,IAAA,EAAM,gBAAA;AAAA,MACN,KAAA,EAAO,iBAAA;AAAA,MACP,QAAA,EAAU;AAAA,KACZ;AAAA,IACA,cAAA,EAAgB;AAAA,MACd,IAAA,EAAM,CAAC,OAAA,EAAS,QAAA,EAAU,OAAO;AAAA;AACnC,GACF;AAAA,EACA,GAAA,EAAK;AAAA,IACH,UAAA,EAAY;AAAA,MACV,IAAA,EAAM;AAAA,KACR;AAAA,IACA,YAAA,EAAc;AAAA,MACZ,GAAA;AAAA,MACA,IAAA;AAAA,MACA,IAAA;AAAA,MACA,IAAA;AAAA,MACA,IAAA;AAAA,MACA,IAAA;AAAA,MACA,IAAA;AAAA,MACA,GAAA;AAAA,MACA,IAAA;AAAA,MACA,IAAA;AAAA,MACA,IAAA;AAAA,MACA,IAAA;AAAA,MACA,IAAA;AAAA,MACA,IAAA;AAAA,MACA,UAAA;AAAA,MACA,SAAA;AAAA,MACA,OAAA;AAAA,MACA,UAAA;AAAA,MACA,UAAA;AAAA,MACA,QAAA;AAAA,MACA,WAAA;AAAA,MACA;AAAA;AACF,GACF;AAAA,EACA,MAAA,EAAQ;AAAA,IACN,UAAA,EAAY;AAAA,MACV,IAAA,EAAM;AAAA,KACR;AAAA,IACA,cAAA,EAAgB;AAAA,MACd,IAAA,EAAM,CAAC,OAAA,EAAS,QAAA,EAAU,OAAO,CAAA;AAAA,MACjC,OAAA,EAAS,CAAC,SAAA,EAAW,WAAA,EAAa,UAAU;AAAA;AAC9C,GACF;AAAA,EACA,UAAA,E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AAA,EACA,SAAA,EAAW;AAAA,IACT,UAAA,EAAY;AAAA,MACV,IAAA,EAAM,eAAA;AAAA,MACN,YAAA,EAAc,kBAAA;AAAA,MACd,KAAA,EAAO,WAAA;AAAA,MACP,SAAA,EAAW,eAAA;AAAA,MACX,WAAA,EAAa;AAAA,KACf;AAAA,IACA,cAAA,EAAgB;AAAA,MACd,OAAA,EAAS,CAAC,IAAA,EAAM,KAAK,CAAA;AAAA,MACrB,QAAA,EAAU,CAAC,IAAA,EAAM,KAAK,CAAA;AAAA,MACtB,IAAA,EAAM,CAAC,OAAA,EAAS,QAAQ;AAAA;AAC1B,GACF;AAAA,EACA,OAAA,EAAS;AAAA,IACP,UAAA,EAAY;AAAA,MACV,OAAA,EAAS,aAAA;AAAA,MACT,KAAA,EAAO;AAAA;AACT,GACF;AAAA,EACA,cAAA,EAAgB;AAAA,IACd,UAAA,EAAY;AAAA,MACV,IAAA,EAAM;AAAA;AACR;AAEJ;;;;"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@backstage/ui",
|
|
3
|
-
"version": "0.0.0-nightly-
|
|
3
|
+
"version": "0.0.0-nightly-20251107024121",
|
|
4
4
|
"backstage": {
|
|
5
5
|
"role": "web-library"
|
|
6
6
|
},
|
|
@@ -47,7 +47,7 @@
|
|
|
47
47
|
"react-aria-components": "^1.13.0"
|
|
48
48
|
},
|
|
49
49
|
"devDependencies": {
|
|
50
|
-
"@backstage/cli": "0.0.0-nightly-
|
|
50
|
+
"@backstage/cli": "0.0.0-nightly-20251107024121",
|
|
51
51
|
"@types/react": "^18.0.0",
|
|
52
52
|
"@types/react-dom": "^18.0.0",
|
|
53
53
|
"chalk": "^5.4.1",
|
|
@@ -1,55 +0,0 @@
|
|
|
1
|
-
import { jsx } from 'react/jsx-runtime';
|
|
2
|
-
import { forwardRef } from 'react';
|
|
3
|
-
import { Collapsible as Collapsible$1 } from '@base-ui-components/react/collapsible';
|
|
4
|
-
import clsx from 'clsx';
|
|
5
|
-
import { useStyles } from '../../hooks/useStyles.esm.js';
|
|
6
|
-
import styles from './Collapsible.module.css.esm.js';
|
|
7
|
-
|
|
8
|
-
const CollapsibleRoot = forwardRef(({ className, ...props }, ref) => {
|
|
9
|
-
const { classNames, cleanedProps } = useStyles("Collapsible", props);
|
|
10
|
-
return /* @__PURE__ */ jsx(
|
|
11
|
-
Collapsible$1.Root,
|
|
12
|
-
{
|
|
13
|
-
ref,
|
|
14
|
-
className: clsx(classNames.root, styles[classNames.root], className),
|
|
15
|
-
...cleanedProps
|
|
16
|
-
}
|
|
17
|
-
);
|
|
18
|
-
});
|
|
19
|
-
CollapsibleRoot.displayName = Collapsible$1.Root.displayName;
|
|
20
|
-
const CollapsibleTrigger = forwardRef(({ className, ...props }, ref) => {
|
|
21
|
-
const { classNames, cleanedProps } = useStyles("Collapsible", props);
|
|
22
|
-
return /* @__PURE__ */ jsx(
|
|
23
|
-
Collapsible$1.Trigger,
|
|
24
|
-
{
|
|
25
|
-
ref,
|
|
26
|
-
className: clsx(
|
|
27
|
-
classNames.trigger,
|
|
28
|
-
styles[classNames.trigger],
|
|
29
|
-
className
|
|
30
|
-
),
|
|
31
|
-
...cleanedProps
|
|
32
|
-
}
|
|
33
|
-
);
|
|
34
|
-
});
|
|
35
|
-
CollapsibleTrigger.displayName = Collapsible$1.Trigger.displayName;
|
|
36
|
-
const CollapsiblePanel = forwardRef(({ className, ...props }, ref) => {
|
|
37
|
-
const { classNames, cleanedProps } = useStyles("Collapsible", props);
|
|
38
|
-
return /* @__PURE__ */ jsx(
|
|
39
|
-
Collapsible$1.Panel,
|
|
40
|
-
{
|
|
41
|
-
ref,
|
|
42
|
-
className: clsx(classNames.panel, styles[classNames.panel], className),
|
|
43
|
-
...cleanedProps
|
|
44
|
-
}
|
|
45
|
-
);
|
|
46
|
-
});
|
|
47
|
-
CollapsiblePanel.displayName = Collapsible$1.Panel.displayName;
|
|
48
|
-
const Collapsible = {
|
|
49
|
-
Root: CollapsibleRoot,
|
|
50
|
-
Trigger: CollapsibleTrigger,
|
|
51
|
-
Panel: CollapsiblePanel
|
|
52
|
-
};
|
|
53
|
-
|
|
54
|
-
export { Collapsible };
|
|
55
|
-
//# sourceMappingURL=Collapsible.esm.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"Collapsible.esm.js","sources":["../../../src/components/Collapsible/Collapsible.tsx"],"sourcesContent":["/*\n * Copyright 2025 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { forwardRef } from 'react';\nimport { Collapsible as CollapsiblePrimitive } from '@base-ui-components/react/collapsible';\nimport clsx from 'clsx';\nimport { useStyles } from '../../hooks/useStyles';\nimport styles from './Collapsible.module.css';\n\nconst CollapsibleRoot = forwardRef<\n React.ElementRef<typeof CollapsiblePrimitive.Root>,\n React.ComponentPropsWithoutRef<typeof CollapsiblePrimitive.Root>\n>(({ className, ...props }, ref) => {\n const { classNames, cleanedProps } = useStyles('Collapsible', props);\n\n return (\n <CollapsiblePrimitive.Root\n ref={ref}\n className={clsx(classNames.root, styles[classNames.root], className)}\n {...cleanedProps}\n />\n );\n});\nCollapsibleRoot.displayName = CollapsiblePrimitive.Root.displayName;\n\nconst CollapsibleTrigger = forwardRef<\n React.ElementRef<typeof CollapsiblePrimitive.Trigger>,\n React.ComponentPropsWithoutRef<typeof CollapsiblePrimitive.Trigger>\n>(({ className, ...props }, ref) => {\n const { classNames, cleanedProps } = useStyles('Collapsible', props);\n\n return (\n <CollapsiblePrimitive.Trigger\n ref={ref}\n className={clsx(\n classNames.trigger,\n styles[classNames.trigger],\n className,\n )}\n {...cleanedProps}\n />\n );\n});\nCollapsibleTrigger.displayName = CollapsiblePrimitive.Trigger.displayName;\n\nconst CollapsiblePanel = forwardRef<\n React.ElementRef<typeof CollapsiblePrimitive.Panel>,\n React.ComponentPropsWithoutRef<typeof CollapsiblePrimitive.Panel>\n>(({ className, ...props }, ref) => {\n const { classNames, cleanedProps } = useStyles('Collapsible', props);\n\n return (\n <CollapsiblePrimitive.Panel\n ref={ref}\n className={clsx(classNames.panel, styles[classNames.panel], className)}\n {...cleanedProps}\n />\n );\n});\nCollapsiblePanel.displayName = CollapsiblePrimitive.Panel.displayName;\n\n/**\n * Collapsible is a component that allows you to collapse and expand content.\n * It is a wrapper around the CollapsiblePrimitive component from base-ui-components.\n *\n * @public\n */\nexport const Collapsible = {\n Root: CollapsibleRoot,\n Trigger: CollapsibleTrigger,\n Panel: CollapsiblePanel,\n};\n"],"names":["CollapsiblePrimitive"],"mappings":";;;;;;;AAsBA,MAAM,eAAA,GAAkB,WAGtB,CAAC,EAAE,WAAW,GAAG,KAAA,IAAS,GAAA,KAAQ;AAClC,EAAA,MAAM,EAAE,UAAA,EAAY,YAAA,EAAa,GAAI,SAAA,CAAU,eAAe,KAAK,CAAA;AAEnE,EAAA,uBACE,GAAA;AAAA,IAACA,aAAA,CAAqB,IAAA;AAAA,IAArB;AAAA,MACC,GAAA;AAAA,MACA,SAAA,EAAW,KAAK,UAAA,CAAW,IAAA,EAAM,OAAO,UAAA,CAAW,IAAI,GAAG,SAAS,CAAA;AAAA,MAClE,GAAG;AAAA;AAAA,GACN;AAEJ,CAAC,CAAA;AACD,eAAA,CAAgB,WAAA,GAAcA,cAAqB,IAAA,CAAK,WAAA;AAExD,MAAM,kBAAA,GAAqB,WAGzB,CAAC,EAAE,WAAW,GAAG,KAAA,IAAS,GAAA,KAAQ;AAClC,EAAA,MAAM,EAAE,UAAA,EAAY,YAAA,EAAa,GAAI,SAAA,CAAU,eAAe,KAAK,CAAA;AAEnE,EAAA,uBACE,GAAA;AAAA,IAACA,aAAA,CAAqB,OAAA;AAAA,IAArB;AAAA,MACC,GAAA;AAAA,MACA,SAAA,EAAW,IAAA;AAAA,QACT,UAAA,CAAW,OAAA;AAAA,QACX,MAAA,CAAO,WAAW,OAAO,CAAA;AAAA,QACzB;AAAA,OACF;AAAA,MACC,GAAG;AAAA;AAAA,GACN;AAEJ,CAAC,CAAA;AACD,kBAAA,CAAmB,WAAA,GAAcA,cAAqB,OAAA,CAAQ,WAAA;AAE9D,MAAM,gBAAA,GAAmB,WAGvB,CAAC,EAAE,WAAW,GAAG,KAAA,IAAS,GAAA,KAAQ;AAClC,EAAA,MAAM,EAAE,UAAA,EAAY,YAAA,EAAa,GAAI,SAAA,CAAU,eAAe,KAAK,CAAA;AAEnE,EAAA,uBACE,GAAA;AAAA,IAACA,aAAA,CAAqB,KAAA;AAAA,IAArB;AAAA,MACC,GAAA;AAAA,MACA,SAAA,EAAW,KAAK,UAAA,CAAW,KAAA,EAAO,OAAO,UAAA,CAAW,KAAK,GAAG,SAAS,CAAA;AAAA,MACpE,GAAG;AAAA;AAAA,GACN;AAEJ,CAAC,CAAA;AACD,gBAAA,CAAiB,WAAA,GAAcA,cAAqB,KAAA,CAAM,WAAA;AAQnD,MAAM,WAAA,GAAc;AAAA,EACzB,IAAA,EAAM,eAAA;AAAA,EACN,OAAA,EAAS,kBAAA;AAAA,EACT,KAAA,EAAO;AACT;;;;"}
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import styleInject from '../../node_modules_dist/style-inject/dist/style-inject.es.esm.js';
|
|
2
|
-
|
|
3
|
-
var css_248z = "/*\n * Copyright 2025 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n@layer tokens, base, components, utilities;\n\n@layer components {\n .Collapsible-module_bui-CollapsiblePanel__2C0cr {\n display: flex;\n height: var(--collapsible-panel-height);\n overflow: hidden;\n transition: all 150ms ease-out;\n\n &[data-starting-style],\n &[data-ending-style] {\n height: 0;\n }\n }\n}\n";
|
|
4
|
-
var styles = {"bui-CollapsiblePanel":"Collapsible-module_bui-CollapsiblePanel__2C0cr"};
|
|
5
|
-
styleInject(css_248z);
|
|
6
|
-
|
|
7
|
-
export { styles as default };
|
|
8
|
-
//# sourceMappingURL=Collapsible.module.css.esm.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"Collapsible.module.css.esm.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;"}
|