Skip to content
This repository has been archived by the owner on Oct 23, 2024. It is now read-only.

Fix destructuring assignments #223

Merged
merged 1 commit into from
Jan 30, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/_labs/ThemeKit/ThemeKit.story.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ const box = {
};

function ThemeKit(props) {
const globalTheme = useContext(ThemeContext);
const { globalTheme } = useContext(ThemeContext);
const subTheme = globalTheme.name;

const [theme, setTheme] = useState(themes.vimeo);
Expand Down
6 changes: 6 additions & 0 deletions src/components/inputs/Input/Input.props.story.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -211,3 +211,9 @@ export function Autosuggest() {
);
}
Autosuggest.storyName = 'autosuggest';

export function Number() {
<Layout.StoryVertical>
<Input type="number" variant="underline" />
</Layout.StoryVertical>;
}
2 changes: 1 addition & 1 deletion src/storybook/welcome/Flower.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ const Pre = styled.pre`
`;

function Code({ children, ...props }) {
const theme = useContext(ThemeContext);
const { theme } = useContext(ThemeContext);

const saturation = 1;
const lightness = theme.name === 'dark' ? 0.667 : 0.4;
Expand Down
4 changes: 2 additions & 2 deletions src/themes/themes.story.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ const padding = '2rem';
export const Common = () => <HookedStory />;

function HookedStory() {
const theme = useContext(ThemeContext);
const { theme } = useContext(ThemeContext);

return (
<div>
Expand Down Expand Up @@ -109,7 +109,7 @@ function HookedStory() {
}

function ThemeBlock({ block }) {
const theme = useContext(ThemeContext);
const { theme } = useContext(ThemeContext);
const section = Object.entries(theme[block]);

return (
Expand Down