diff --git a/web/src/beta/components/Icon/Icons/plus.svg b/web/src/beta/components/Icon/Icons/plus.svg new file mode 100644 index 0000000000..b34d787e46 --- /dev/null +++ b/web/src/beta/components/Icon/Icons/plus.svg @@ -0,0 +1,3 @@ + + + diff --git a/web/src/beta/components/Icon/icons.ts b/web/src/beta/components/Icon/icons.ts index 143c734983..cbefe72974 100644 --- a/web/src/beta/components/Icon/icons.ts +++ b/web/src/beta/components/Icon/icons.ts @@ -51,6 +51,9 @@ import Workspaces from "./Icons/workspaces.svg"; import Square from "./Icons/square.svg"; import TwoRectangle from "./Icons/two-rectangle.svg"; +// Plus +import Plus from "./Icons/plus.svg"; + export default { file: File, dl: InfoTable, @@ -74,6 +77,7 @@ export default { playRight: PlayRight, playLeft: PlayLeft, square: Square, + plus: Plus, timeline: Timeline, twoRectangle: TwoRectangle, actionbutton: ActionButton, diff --git a/web/src/beta/components/InsertionButton/index.stories.tsx b/web/src/beta/components/InsertionButton/index.stories.tsx new file mode 100644 index 0000000000..1166244773 --- /dev/null +++ b/web/src/beta/components/InsertionButton/index.stories.tsx @@ -0,0 +1,11 @@ +import { Meta, StoryObj } from "@storybook/react"; + +import InsertionButton from "."; + +export default { + component: InsertionButton, +} as Meta; + +type Story = StoryObj; + +export const Default: Story = {}; diff --git a/web/src/beta/components/InsertionButton/index.tsx b/web/src/beta/components/InsertionButton/index.tsx new file mode 100644 index 0000000000..1199aa755e --- /dev/null +++ b/web/src/beta/components/InsertionButton/index.tsx @@ -0,0 +1,52 @@ +import Icon from "@reearth/beta/components/Icon"; +import { styled } from "@reearth/services/theme"; + +type Props = { + onClick?: () => void; +}; + +const InsertionButton: React.FC = ({ onClick }) => { + return ( + + + + + ); +}; + +const Box = styled.div` + display: flex; + flex-direction: row; + align-items: center; + padding: 2px 0px; + gap: 4px; + + border-radius: 6px; + opacity: 0; + + :hover { + opacity: 1; + transition: all 0.5s ease; + } + :not(:hover) { + transition: all 0.5s ease; + } + cursor: pointer; +`; + +const Border = styled.object` + height: 1px; + width: 100%; + + background: ${props => props.theme.general.select}; + border-radius: 1px; +`; + +const StyledIcon = styled(Icon)` + background: ${props => props.theme.general.select}; + border-radius: 50%; + padding: 2px; + color: ${props => props.theme.general.bg.transparent}; +`; + +export default InsertionButton;