How to use the emotion-theming.useTheme function in emotion-theming

To help you get started, we’ve selected a few emotion-theming examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github gremlin / chaoskit / src / components / Container.js View on Github external
const Container = ({ className, size, ...opts }) => {
  const theme = useTheme();

  return (
github jaylineko / discohook / src / editor / Editor.tsx View on Github external
export default function Editor(props: Props) {
  const {
    message,
    onChange: handleChange,
    files,
    onFilesChange: handleFilesChange,
    onAppearanceChange: handleAppearanceChange,
    webhookUrl,
    onWebhookUrlChange: handleWebhookUrlChange,
    webhook,
  } = props

  const theme = useTheme()

  const [sending, setSending] = useState(false)
  const sendMessage = async () => {
    if (sending) return
    setSending(true)

    try {
      await executeWebhook(webhookUrl, message, files)
    } catch (error) {
      console.error("Error executing webhook:", error)
    }

    setSending(false)
  }

  const clearAll = () => {
github gremlin / chaoskit / .storybook / components / ExampleFill.js View on Github external
const ExampleFill = ({ as: Component, ...opts }) => {
  const theme = useTheme();

  return (
    
  );
};
github sumup-oss / circuit-ui / src / components / Text / Text.native.js View on Github external
const Text = ({ size, bold, italic, strike, noMargin, style, ...props }) => {
  const theme = useTheme();
  const { Text: NativeText } = useComponents();
  const styleProps = { size, bold, italic, strike, noMargin, style };
  return (
    
  );
};
github gremlin / chaoskit / src / components / Section.js View on Github external
({ as: Component, space, slant, className, ...opts }, ref) => {
    const theme = useTheme();

    return (
github huchenme / hacker-tab-extension / src / components / InfoItem.js View on Github external
export default function InfoItem({ children, icon }) {
  const theme = useTheme();
  return (
    <div>
      {icon ? (
        <div>
          {React.cloneElement(icon, {</div></div>
github gremlin / chaoskit / src / components / Skeleton.js View on Github external
const Skeleton = ({ as: Component, className, ...props }) =&gt; {
  const theme = useTheme();

  return (

emotion-theming

A CSS-in-JS theming solution, inspired by styled-components

MIT
Latest version published 4 years ago

Package Health Score

85 / 100
Full package analysis

Similar packages