diff --git a/packages/components/src/components/CopyButton/CopyButton.module.css b/packages/components/src/components/CopyButton/CopyButton.module.css deleted file mode 100644 index 696149055..000000000 --- a/packages/components/src/components/CopyButton/CopyButton.module.css +++ /dev/null @@ -1,4 +0,0 @@ -@import "@/styles"; - -.root { -} diff --git a/packages/components/src/components/CopyButton/CopyButton.tsx b/packages/components/src/components/CopyButton/CopyButton.tsx index 354141c8f..a8ceb7424 100644 --- a/packages/components/src/components/CopyButton/CopyButton.tsx +++ b/packages/components/src/components/CopyButton/CopyButton.tsx @@ -6,7 +6,6 @@ import { Icon } from "@/components/Icon"; import { faCopy } from "@fortawesome/free-regular-svg-icons/faCopy"; import locales from "./locales/*.locale.json"; import { useLocalizedStringFormatter } from "react-aria"; -import styles from "./CopyButton.module.css"; import clsx from "clsx"; export interface CopyButtonProps { @@ -19,7 +18,7 @@ export const CopyButton: FC = (props) => { const stringFormatter = useLocalizedStringFormatter(locales); - const rootClassName = clsx(className, styles.root); + const rootClassName = clsx(className); const ariaLabel = stringFormatter.format("copyButton.copy"); diff --git a/packages/components/src/components/LabeledValue/LabeledValue.module.css b/packages/components/src/components/LabeledValue/LabeledValue.module.css index cc56ae476..55511f034 100644 --- a/packages/components/src/components/LabeledValue/LabeledValue.module.css +++ b/packages/components/src/components/LabeledValue/LabeledValue.module.css @@ -9,23 +9,23 @@ column-gap: var(--labeled-value--value-to-copy-button-spacing); width: fit-content; - &:has(.copyButton) { + &:has(> :global(.flow-button)) { grid-template-areas: "label label" - "value copyButton"; + "value button"; } -} -.label { - grid-area: label; -} + :global(.flow-label) { + grid-area: label; + } -.value { - grid-area: value; -} + :global(.flow-text) { + grid-area: value; + } -.copyButton { - grid-area: copyButton; - margin-top: calc(var(--labeled-value--label-to-value-spacing) * -1); - align-self: start; + & > :global(.flow-button) { + grid-area: button; + margin-top: calc(var(--labeled-value--label-to-value-spacing) * -1); + align-self: start; + } } diff --git a/packages/components/src/components/LabeledValue/LabeledValue.tsx b/packages/components/src/components/LabeledValue/LabeledValue.tsx index 475ea591e..3016946c7 100644 --- a/packages/components/src/components/LabeledValue/LabeledValue.tsx +++ b/packages/components/src/components/LabeledValue/LabeledValue.tsx @@ -1,5 +1,4 @@ import React, { FC, PropsWithChildren, ReactNode } from "react"; -import { PropsContext, PropsContextProvider } from "@/lib/propsContext"; import styles from "./LabeledValue.module.css"; import clsx from "clsx"; import { Text } from "@/components/Text"; @@ -16,19 +15,11 @@ export const LabeledValue: FC = (props) => { const rootClassName = clsx(className, styles.root); - const propsContext: PropsContext = { - Label: { - className: styles.label, - }, - }; - return (
- - {children} - {value} - {copyable && } - + {children} + {value} + {copyable && }
); };