@ljcl/storybook-addon-cssprops
Version:
Interact with css custom properties dynamically in the Storybook UI
16 lines (15 loc) • 816 B
JavaScript
import * as React from "react";
import { styled } from "@storybook/theming";
import { Link } from "@storybook/components";
var NoCustomPropertiesWrapper = styled.div(function (_a) {
var theme = _a.theme;
return ({
background: theme.background.app,
padding: "10px 15px",
lineHeight: "20px",
boxShadow: "".concat(theme.appBorderColor, " 0 -1px 0 0 inset"),
});
});
export var NoCustomPropertiesWarning = function () { return (React.createElement(NoCustomPropertiesWrapper, null,
"This story is not configured with CSS Custom Properties.\u00A0",
React.createElement(Link, { href: "https://github.com/ljcl/storybook-addon-cssprops/blob/main/README.md#adding-custom-properties", target: "_blank", cancel: false }, "Learn how to add css custom properties \u00BB"))); };