From 8c01e4d7ec3c9b356c768a79101f9917ce00889d Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Tue, 2 Jul 2024 09:01:21 +0200 Subject: [PATCH 1/2] Bump service_wiki image to v0.18.1 (#1396) Co-authored-by: ITA Wiki bot --- config/dev/service_wiki.yml | 2 +- packages/ui/src/stories/atoms/HamburgerMenu.stories.ts | 3 +-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/config/dev/service_wiki.yml b/config/dev/service_wiki.yml index 6311ba347..706473f39 100644 --- a/config/dev/service_wiki.yml +++ b/config/dev/service_wiki.yml @@ -1,2 +1,2 @@ service_wiki: - version: 0.16.1 + version: 0.18.1 diff --git a/packages/ui/src/stories/atoms/HamburgerMenu.stories.ts b/packages/ui/src/stories/atoms/HamburgerMenu.stories.ts index 755a348cc..61378e331 100644 --- a/packages/ui/src/stories/atoms/HamburgerMenu.stories.ts +++ b/packages/ui/src/stories/atoms/HamburgerMenu.stories.ts @@ -1,8 +1,7 @@ import type { Meta, StoryObj } from '@storybook/react' import { HamburgerMenu } from '../../components/atoms' -// More on how to set up stories at: https://storybook.js.org/docs/writing-stories#default-export -const meta = { +const meta: Meta = { title: 'Atoms/HamburgerMenu', component: HamburgerMenu, parameters: { From db180d67d3d047e059fc724920eed5821d130730 Mon Sep 17 00:00:00 2001 From: Cristian Moller Date: Tue, 2 Jul 2024 20:26:27 +0200 Subject: [PATCH 2/2] [FE][UI] Fix hamburger menu. Remove breakpoint and close/open on click --- packages/ui/CHANGELOG.md | 6 ++++++ packages/ui/package.json | 2 +- packages/ui/src/components/atoms/HamburgerMenu.tsx | 6 +----- packages/ui/src/stories/atoms/HamburgerMenu.stories.ts | 4 ---- 4 files changed, 8 insertions(+), 10 deletions(-) diff --git a/packages/ui/CHANGELOG.md b/packages/ui/CHANGELOG.md index 6979fb6dc..efb975170 100644 --- a/packages/ui/CHANGELOG.md +++ b/packages/ui/CHANGELOG.md @@ -4,6 +4,12 @@ All notable changes to this project will be documented in this file. ### Fixed +## [0.36.2] - 2024-07-02 + +- Fixed HamburguerMenu in Storybook + +### Fixed + ## [0.36.1] - 2024-06-25 - Fixed backgroundImg of CardHome diff --git a/packages/ui/package.json b/packages/ui/package.json index e7830f454..2cb06a67b 100644 --- a/packages/ui/package.json +++ b/packages/ui/package.json @@ -1,6 +1,6 @@ { "name": "@itacademy/ui", - "version": "0.36.1", + "version": "0.36.2", "description": "React FE components for ITAcademy projects.", "main": "./dist/cjs/index.js", "module": "./dist/esm/index.es.js", diff --git a/packages/ui/src/components/atoms/HamburgerMenu.tsx b/packages/ui/src/components/atoms/HamburgerMenu.tsx index 71784bc2b..0f79044ba 100644 --- a/packages/ui/src/components/atoms/HamburgerMenu.tsx +++ b/packages/ui/src/components/atoms/HamburgerMenu.tsx @@ -1,6 +1,6 @@ import { FC } from 'react' import styled from 'styled-components' -import { colors, dimensions, device } from '../../styles' +import { colors, dimensions } from '../../styles' export type THamburgerMenu = { open: boolean @@ -46,10 +46,6 @@ const StyledBurger = styled.button` transform: ${({ open }) => (open ? 'rotate(-45deg)' : 'rotate(0)')}; } } - - @media ${device.Tablet} { - display: none; - } ` export const HamburgerMenu: FC = ({ open, onClick }) => ( diff --git a/packages/ui/src/stories/atoms/HamburgerMenu.stories.ts b/packages/ui/src/stories/atoms/HamburgerMenu.stories.ts index 61378e331..28917ecf8 100644 --- a/packages/ui/src/stories/atoms/HamburgerMenu.stories.ts +++ b/packages/ui/src/stories/atoms/HamburgerMenu.stories.ts @@ -5,12 +5,9 @@ const meta: Meta = { title: 'Atoms/HamburgerMenu', component: HamburgerMenu, parameters: { - // Optional parameter to center the component in the Canvas. More info: https://storybook.js.org/docs/configure/story-layout layout: 'centered', }, - // This component will have an automatically generated Autodocs entry: https://storybook.js.org/docs/writing-docs/autodocs tags: ['autodocs'], - // More on argTypes: https://storybook.js.org/docs/api/argtypes argTypes: { open: { control: 'boolean' }, onClick: { action: 'clicked' }, @@ -20,7 +17,6 @@ const meta: Meta = { export default meta type HamburgerMenuStory = StoryObj -// More on writing stories with args: https://storybook.js.org/docs/writing-stories/args export const Closed: HamburgerMenuStory = { args: { open: false,