oddsgate-ds 1.0.198 → 1.0.199
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/types/components/molecules/CategoriesWrapper/CategoriesWrapper.component.d.ts +4 -0
- package/dist/cjs/types/components/molecules/CategoriesWrapper/CategoriesWrapper.interface.d.ts +5 -0
- package/dist/cjs/types/components/molecules/CategoriesWrapper/CategoriesWrapper.theme.d.ts +6 -0
- package/dist/cjs/types/components/molecules/CategoryIndex/CategoryIndex.component.d.ts +4 -0
- package/dist/cjs/types/components/molecules/CategoryIndex/CategoryIndex.interface.d.ts +5 -0
- package/dist/cjs/types/components/molecules/CategoryIndex/CategoryIndex.theme.d.ts +7 -0
- package/dist/cjs/types/components/molecules/SearchBar/SearchBar.component.d.ts +4 -0
- package/dist/cjs/types/components/molecules/SearchBar/SearchBar.interface.d.ts +6 -0
- package/dist/cjs/types/components/molecules/SearchBar/SearchBar.theme.d.ts +4 -0
- package/dist/cjs/types/components/organisms/Glossary/Glossary.component.d.ts +26 -0
- package/dist/cjs/types/components/organisms/Glossary/Glossary.themes.d.ts +9 -0
- package/dist/esm/types/components/molecules/CategoriesWrapper/CategoriesWrapper.component.d.ts +4 -0
- package/dist/esm/types/components/molecules/CategoriesWrapper/CategoriesWrapper.interface.d.ts +5 -0
- package/dist/esm/types/components/molecules/CategoriesWrapper/CategoriesWrapper.theme.d.ts +6 -0
- package/dist/esm/types/components/molecules/CategoryIndex/CategoryIndex.component.d.ts +4 -0
- package/dist/esm/types/components/molecules/CategoryIndex/CategoryIndex.interface.d.ts +5 -0
- package/dist/esm/types/components/molecules/CategoryIndex/CategoryIndex.theme.d.ts +7 -0
- package/dist/esm/types/components/molecules/SearchBar/SearchBar.component.d.ts +4 -0
- package/dist/esm/types/components/molecules/SearchBar/SearchBar.interface.d.ts +6 -0
- package/dist/esm/types/components/molecules/SearchBar/SearchBar.theme.d.ts +4 -0
- package/dist/esm/types/components/organisms/Glossary/Glossary.component.d.ts +26 -0
- package/dist/esm/types/components/organisms/Glossary/Glossary.themes.d.ts +9 -0
- package/package.json +1 -1
- package/src/components/molecules/CategoriesWrapper/CategoriesWrapper.component.tsx +33 -0
- package/src/components/molecules/CategoriesWrapper/CategoriesWrapper.interface.ts +4 -0
- package/src/components/molecules/CategoriesWrapper/CategoriesWrapper.stories.tsx +27 -0
- package/src/components/molecules/CategoriesWrapper/CategoriesWrapper.theme.ts +38 -0
- package/src/components/molecules/CategoryIndex/CategoryIndex.component.tsx +33 -0
- package/src/components/molecules/CategoryIndex/CategoryIndex.interface.ts +5 -0
- package/src/components/molecules/CategoryIndex/CategoryIndex.stories.tsx +23 -0
- package/src/components/molecules/CategoryIndex/CategoryIndex.theme.ts +27 -0
- package/src/components/molecules/SearchBar/SearchBar.component.tsx +30 -0
- package/src/components/molecules/SearchBar/SearchBar.interface.ts +5 -0
- package/src/components/molecules/SearchBar/SearchBar.stories.tsx +18 -0
- package/src/components/molecules/SearchBar/SearchBar.theme.ts +47 -0
- package/src/components/organisms/Glossary/Glossary.component.tsx +84 -0
- package/src/components/organisms/Glossary/Glossary.interface.ts +0 -0
- package/src/components/organisms/Glossary/Glossary.stories.tsx +278 -0
- package/src/components/organisms/Glossary/Glossary.themes.ts +27 -0
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
export declare const StyledCategoryWrapper: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
|
|
3
|
+
export declare const StyledCategorySeparator: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
|
|
4
|
+
export declare const StyledCategorySeparatorLine: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
|
|
5
|
+
export declare const StyledCategoryContent: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
|
|
6
|
+
export declare const StyledCategoryItem: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
type ItemProps = {
|
|
3
|
+
isSelected?: boolean;
|
|
4
|
+
};
|
|
5
|
+
export declare const StyledGlossaryCategoryIndex: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
|
|
6
|
+
export declare const StyledGlossaryCategoryIndexItem: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components/dist/types").Substitute<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, ItemProps>> & string;
|
|
7
|
+
export {};
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
export declare const StyledGlossarySearch: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
|
|
3
|
+
export declare const SearchInput: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>, never>> & string;
|
|
4
|
+
export declare const SearchButton: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, never>> & string;
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
type GlossaryItem = {
|
|
3
|
+
title: string;
|
|
4
|
+
categories: {
|
|
5
|
+
name: string;
|
|
6
|
+
items: {
|
|
7
|
+
slug: string;
|
|
8
|
+
name: string;
|
|
9
|
+
}[];
|
|
10
|
+
}[];
|
|
11
|
+
};
|
|
12
|
+
type GlossaryProps = {
|
|
13
|
+
title: string;
|
|
14
|
+
subtitle: string;
|
|
15
|
+
items: GlossaryItem[];
|
|
16
|
+
categories: {
|
|
17
|
+
name: string;
|
|
18
|
+
items: {
|
|
19
|
+
slug: string;
|
|
20
|
+
name: string;
|
|
21
|
+
}[];
|
|
22
|
+
}[];
|
|
23
|
+
placeholder?: string;
|
|
24
|
+
};
|
|
25
|
+
declare const Glossary: React.FC<GlossaryProps>;
|
|
26
|
+
export default Glossary;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
export declare const StyledGlossary: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
|
|
3
|
+
export declare const StyledGlossaryHeader: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
|
|
4
|
+
export declare const StyledGlossaryTitle: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLHeadingElement>, HTMLHeadingElement>, never>> & string;
|
|
5
|
+
export declare const StyledGlossarySubtitle: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLHeadingElement>, HTMLHeadingElement>, never>> & string;
|
|
6
|
+
export declare const StyledGlossaryIndex: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
|
|
7
|
+
export declare const StyledGlossaryCategories: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
|
|
8
|
+
export declare const StyledGlossarySeparator: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
|
|
9
|
+
export declare const StyledGlossaryCategoryItems: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").LiHTMLAttributes<HTMLLIElement>, HTMLLIElement>, never>> & string;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
export declare const StyledCategoryWrapper: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
|
|
3
|
+
export declare const StyledCategorySeparator: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
|
|
4
|
+
export declare const StyledCategorySeparatorLine: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
|
|
5
|
+
export declare const StyledCategoryContent: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
|
|
6
|
+
export declare const StyledCategoryItem: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
type ItemProps = {
|
|
3
|
+
isSelected?: boolean;
|
|
4
|
+
};
|
|
5
|
+
export declare const StyledGlossaryCategoryIndex: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
|
|
6
|
+
export declare const StyledGlossaryCategoryIndexItem: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components/dist/types").Substitute<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, ItemProps>> & string;
|
|
7
|
+
export {};
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
export declare const StyledGlossarySearch: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
|
|
3
|
+
export declare const SearchInput: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>, never>> & string;
|
|
4
|
+
export declare const SearchButton: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, never>> & string;
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
type GlossaryItem = {
|
|
3
|
+
title: string;
|
|
4
|
+
categories: {
|
|
5
|
+
name: string;
|
|
6
|
+
items: {
|
|
7
|
+
slug: string;
|
|
8
|
+
name: string;
|
|
9
|
+
}[];
|
|
10
|
+
}[];
|
|
11
|
+
};
|
|
12
|
+
type GlossaryProps = {
|
|
13
|
+
title: string;
|
|
14
|
+
subtitle: string;
|
|
15
|
+
items: GlossaryItem[];
|
|
16
|
+
categories: {
|
|
17
|
+
name: string;
|
|
18
|
+
items: {
|
|
19
|
+
slug: string;
|
|
20
|
+
name: string;
|
|
21
|
+
}[];
|
|
22
|
+
}[];
|
|
23
|
+
placeholder?: string;
|
|
24
|
+
};
|
|
25
|
+
declare const Glossary: React.FC<GlossaryProps>;
|
|
26
|
+
export default Glossary;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
export declare const StyledGlossary: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
|
|
3
|
+
export declare const StyledGlossaryHeader: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
|
|
4
|
+
export declare const StyledGlossaryTitle: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLHeadingElement>, HTMLHeadingElement>, never>> & string;
|
|
5
|
+
export declare const StyledGlossarySubtitle: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLHeadingElement>, HTMLHeadingElement>, never>> & string;
|
|
6
|
+
export declare const StyledGlossaryIndex: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
|
|
7
|
+
export declare const StyledGlossaryCategories: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
|
|
8
|
+
export declare const StyledGlossarySeparator: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
|
|
9
|
+
export declare const StyledGlossaryCategoryItems: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").LiHTMLAttributes<HTMLLIElement>, HTMLLIElement>, never>> & string;
|
package/package.json
CHANGED
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import React from 'react'
|
|
2
|
+
import {
|
|
3
|
+
StyledCategoryContent,
|
|
4
|
+
StyledCategorySeparator,
|
|
5
|
+
StyledCategoryWrapper,
|
|
6
|
+
StyledCategoryItem,
|
|
7
|
+
StyledCategorySeparatorLine
|
|
8
|
+
} from './CategoriesWrapper.theme'
|
|
9
|
+
import { CategoriesWrapperProps } from './CategoriesWrapper.interface'
|
|
10
|
+
import Button from '@/components/atoms/Button'
|
|
11
|
+
|
|
12
|
+
const CategoriesWrapper: React.FC<CategoriesWrapperProps> = ({
|
|
13
|
+
category,
|
|
14
|
+
categoryItems
|
|
15
|
+
}) => {
|
|
16
|
+
return (
|
|
17
|
+
<StyledCategoryWrapper>
|
|
18
|
+
<StyledCategorySeparator>
|
|
19
|
+
{category}
|
|
20
|
+
<StyledCategorySeparatorLine />
|
|
21
|
+
</StyledCategorySeparator>
|
|
22
|
+
<StyledCategoryContent>
|
|
23
|
+
{categoryItems.map((item, index) => (
|
|
24
|
+
<StyledCategoryItem key={index}>
|
|
25
|
+
<Button variant="text">{item}</Button>
|
|
26
|
+
</StyledCategoryItem>
|
|
27
|
+
))}
|
|
28
|
+
</StyledCategoryContent>
|
|
29
|
+
</StyledCategoryWrapper>
|
|
30
|
+
)
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
export default CategoriesWrapper;
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import React from 'react'
|
|
2
|
+
import { Meta, StoryObj } from '@storybook/react'
|
|
3
|
+
import CategoriesWrapper from './CategoriesWrapper.component'
|
|
4
|
+
|
|
5
|
+
const meta: Meta<typeof CategoriesWrapper> = {
|
|
6
|
+
title: 'Components/CategoriesWrapper',
|
|
7
|
+
component: CategoriesWrapper
|
|
8
|
+
}
|
|
9
|
+
export default meta
|
|
10
|
+
|
|
11
|
+
type Story = StoryObj<typeof CategoriesWrapper>
|
|
12
|
+
|
|
13
|
+
export const Default: Story = {
|
|
14
|
+
args: {
|
|
15
|
+
category: 'A',
|
|
16
|
+
categoryItems: [
|
|
17
|
+
'Ace',
|
|
18
|
+
'Admin',
|
|
19
|
+
'AFK',
|
|
20
|
+
'Anti-eco',
|
|
21
|
+
'Aimbot',
|
|
22
|
+
'All-in',
|
|
23
|
+
'Armor',
|
|
24
|
+
'APM'
|
|
25
|
+
]
|
|
26
|
+
}
|
|
27
|
+
}
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
import { colors } from '@/styles/variables'
|
|
2
|
+
import styled from 'styled-components'
|
|
3
|
+
|
|
4
|
+
export const StyledCategoryWrapper = styled.div`
|
|
5
|
+
display: flex;
|
|
6
|
+
flex-direction: column;
|
|
7
|
+
width: 100%;
|
|
8
|
+
`
|
|
9
|
+
|
|
10
|
+
export const StyledCategorySeparator = styled.div`
|
|
11
|
+
display: flex;
|
|
12
|
+
align-items: center;
|
|
13
|
+
width: 100%;
|
|
14
|
+
gap: 0.75rem;
|
|
15
|
+
font-size: 3rem;
|
|
16
|
+
font-weight: 700;
|
|
17
|
+
`
|
|
18
|
+
export const StyledCategorySeparatorLine = styled.div`
|
|
19
|
+
flex-grow: 1;
|
|
20
|
+
height: 50%;
|
|
21
|
+
border-bottom: 1px solid ${colors.gray20};
|
|
22
|
+
opacity: 0.5;
|
|
23
|
+
`
|
|
24
|
+
|
|
25
|
+
export const StyledCategoryContent = styled.div`
|
|
26
|
+
display: flex;
|
|
27
|
+
gap: 1.875rem;
|
|
28
|
+
flex-wrap: wrap;
|
|
29
|
+
`
|
|
30
|
+
export const StyledCategoryItem = styled.div`
|
|
31
|
+
& > button {
|
|
32
|
+
height: 2.125rem;
|
|
33
|
+
padding: 0.625rem 2.5rem;
|
|
34
|
+
font-size: 1.5rem;
|
|
35
|
+
font-weight: 700;
|
|
36
|
+
text-transform: none;
|
|
37
|
+
}
|
|
38
|
+
`
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import React from 'react'
|
|
2
|
+
import {
|
|
3
|
+
StyledGlossaryCategoryIndex,
|
|
4
|
+
StyledGlossaryCategoryIndexItem
|
|
5
|
+
} from './CategoryIndex.theme'
|
|
6
|
+
import { CategoryIndexProps } from './CategoryIndex.interface'
|
|
7
|
+
|
|
8
|
+
const CategoryIndex: React.FC<CategoryIndexProps> = ({
|
|
9
|
+
categories,
|
|
10
|
+
onChange,
|
|
11
|
+
selectedCategory
|
|
12
|
+
}) => {
|
|
13
|
+
const allCategories = ['#', ...categories]
|
|
14
|
+
|
|
15
|
+
return (
|
|
16
|
+
<StyledGlossaryCategoryIndex>
|
|
17
|
+
{allCategories.map(category => (
|
|
18
|
+
<StyledGlossaryCategoryIndexItem
|
|
19
|
+
onClick={() => onChange(category === '#' ? null : category)}
|
|
20
|
+
isSelected={
|
|
21
|
+
selectedCategory === category ||
|
|
22
|
+
(selectedCategory === null && category === '#')
|
|
23
|
+
}
|
|
24
|
+
key={`category-${category}`}
|
|
25
|
+
>
|
|
26
|
+
{category}
|
|
27
|
+
</StyledGlossaryCategoryIndexItem>
|
|
28
|
+
))}
|
|
29
|
+
</StyledGlossaryCategoryIndex>
|
|
30
|
+
)
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
export default CategoryIndex
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import React, { useState } from 'react'
|
|
2
|
+
import CategoryIndex from './CategoryIndex.component'
|
|
3
|
+
|
|
4
|
+
const categories = Array.from({ length: 26 }, (_, i) =>
|
|
5
|
+
String.fromCharCode(65 + i)
|
|
6
|
+
)
|
|
7
|
+
|
|
8
|
+
export default {
|
|
9
|
+
title: 'Components/CategoryIndex',
|
|
10
|
+
component: CategoryIndex
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
export const Default = () => {
|
|
14
|
+
const [selected, setSelected] = useState<string | null>(null)
|
|
15
|
+
|
|
16
|
+
return (
|
|
17
|
+
<CategoryIndex
|
|
18
|
+
categories={[...categories]}
|
|
19
|
+
selectedCategory={selected}
|
|
20
|
+
onChange={setSelected}
|
|
21
|
+
/>
|
|
22
|
+
)
|
|
23
|
+
}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { colors } from '@/styles/variables'
|
|
2
|
+
import styled from 'styled-components'
|
|
3
|
+
|
|
4
|
+
type ItemProps = {
|
|
5
|
+
isSelected?: boolean
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
export const StyledGlossaryCategoryIndex = styled.div`
|
|
9
|
+
display: flex;
|
|
10
|
+
flex-wrap: wrap;
|
|
11
|
+
`
|
|
12
|
+
|
|
13
|
+
export const StyledGlossaryCategoryIndexItem = styled.div<ItemProps>`
|
|
14
|
+
cursor: pointer;
|
|
15
|
+
border-radius: 100%;
|
|
16
|
+
background-color: ${({ isSelected }) =>
|
|
17
|
+
isSelected ? `${colors.primary50}66` : ''};
|
|
18
|
+
display: flex;
|
|
19
|
+
align-items: center;
|
|
20
|
+
justify-content: center;
|
|
21
|
+
width: 2.125rem;
|
|
22
|
+
height: 2.125rem;
|
|
23
|
+
box-sizing: border-box;
|
|
24
|
+
color: ${colors.gray20};
|
|
25
|
+
font-weight: 700;
|
|
26
|
+
font-size: 1.5rem;
|
|
27
|
+
`
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import React from 'react'
|
|
2
|
+
import {
|
|
3
|
+
SearchButton,
|
|
4
|
+
SearchInput,
|
|
5
|
+
StyledGlossarySearch
|
|
6
|
+
} from './SearchBar.theme'
|
|
7
|
+
import Icon from '@/components/atoms/Icon'
|
|
8
|
+
import { SearchBarProps } from './SearchBar.interface'
|
|
9
|
+
|
|
10
|
+
const SearchBar: React.FC<SearchBarProps> = ({
|
|
11
|
+
value,
|
|
12
|
+
onChange,
|
|
13
|
+
placeholder
|
|
14
|
+
}) => {
|
|
15
|
+
return (
|
|
16
|
+
<StyledGlossarySearch>
|
|
17
|
+
<SearchInput
|
|
18
|
+
type="text"
|
|
19
|
+
placeholder={placeholder}
|
|
20
|
+
value={value}
|
|
21
|
+
onChange={onChange}
|
|
22
|
+
/>
|
|
23
|
+
<SearchButton>
|
|
24
|
+
<Icon icon="icon-search" />
|
|
25
|
+
</SearchButton>
|
|
26
|
+
</StyledGlossarySearch>
|
|
27
|
+
)
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
export default SearchBar
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import React, { useState } from 'react'
|
|
2
|
+
import SearchBar from './SearchBar.component'
|
|
3
|
+
|
|
4
|
+
export default {
|
|
5
|
+
title: 'Components/SearchBar',
|
|
6
|
+
component: SearchBar
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
export const Default = () => {
|
|
10
|
+
const [value, setValue] = useState('')
|
|
11
|
+
return (
|
|
12
|
+
<SearchBar
|
|
13
|
+
value={value}
|
|
14
|
+
onChange={e => setValue(e.target.value)}
|
|
15
|
+
placeholder="Search..."
|
|
16
|
+
/>
|
|
17
|
+
)
|
|
18
|
+
}
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import styled from 'styled-components'
|
|
2
|
+
import { colors } from '@/styles/variables'
|
|
3
|
+
|
|
4
|
+
export const StyledGlossarySearch = styled.div`
|
|
5
|
+
position: relative;
|
|
6
|
+
width: 100%;
|
|
7
|
+
max-width: 870px;
|
|
8
|
+
margin: 2rem auto;
|
|
9
|
+
`
|
|
10
|
+
|
|
11
|
+
export const SearchInput = styled.input`
|
|
12
|
+
display: flex;
|
|
13
|
+
align-items: center;
|
|
14
|
+
width: 100%;
|
|
15
|
+
padding: 1.5rem 0.75rem;
|
|
16
|
+
border-radius: 62.5rem;
|
|
17
|
+
border: none;
|
|
18
|
+
background: ${colors.gray20};
|
|
19
|
+
font-size: 0.9375rem;
|
|
20
|
+
color: ${colors.hellobar};
|
|
21
|
+
&::placeholder {
|
|
22
|
+
color: ${colors.hellobar};
|
|
23
|
+
}
|
|
24
|
+
`
|
|
25
|
+
|
|
26
|
+
export const SearchButton = styled.button`
|
|
27
|
+
position: absolute;
|
|
28
|
+
top: 50%;
|
|
29
|
+
transform: translateY(-50%);
|
|
30
|
+
right: 1.5rem;
|
|
31
|
+
width: 2.5rem;
|
|
32
|
+
height: 2.5rem;
|
|
33
|
+
border-radius: 50%;
|
|
34
|
+
background: ${colors.hellobar};
|
|
35
|
+
border: none;
|
|
36
|
+
cursor: pointer;
|
|
37
|
+
color: ${colors.gray20};
|
|
38
|
+
display: flex;
|
|
39
|
+
align-items: center;
|
|
40
|
+
justify-content: center;
|
|
41
|
+
|
|
42
|
+
svg {
|
|
43
|
+
width: 1.25rem;
|
|
44
|
+
height: 1.25rem;
|
|
45
|
+
display: block;
|
|
46
|
+
}
|
|
47
|
+
`
|
|
@@ -0,0 +1,84 @@
|
|
|
1
|
+
import React, { useState } from 'react'
|
|
2
|
+
import {
|
|
3
|
+
StyledGlossary,
|
|
4
|
+
StyledGlossaryCategories,
|
|
5
|
+
StyledGlossarySubtitle,
|
|
6
|
+
StyledGlossaryTitle
|
|
7
|
+
} from './Glossary.themes'
|
|
8
|
+
|
|
9
|
+
import SearchBar from '@/components/molecules/SearchBar/SearchBar.component'
|
|
10
|
+
import GlossaryCategoryIndex from '@/components/molecules/CategoryIndex/CategoryIndex.component'
|
|
11
|
+
import CategoriesWrapper from '@/components/molecules/CategoriesWrapper/CategoriesWrapper.component'
|
|
12
|
+
|
|
13
|
+
type GlossaryItem = {
|
|
14
|
+
title: string
|
|
15
|
+
categories: { name: string, items: { slug: string, name: string }[] }[]
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
type GlossaryProps = {
|
|
19
|
+
title: string
|
|
20
|
+
subtitle: string
|
|
21
|
+
items: GlossaryItem[]
|
|
22
|
+
categories: { name: string, items: { slug: string, name: string }[] }[]
|
|
23
|
+
placeholder?: string
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
const Glossary: React.FC<GlossaryProps> = ({
|
|
27
|
+
title,
|
|
28
|
+
subtitle,
|
|
29
|
+
items,
|
|
30
|
+
categories,
|
|
31
|
+
placeholder
|
|
32
|
+
}) => {
|
|
33
|
+
const [searchTerm, setSearchTerm] = useState('')
|
|
34
|
+
const [selectedCategory, setSelectedCategory] = useState<string | null>(null)
|
|
35
|
+
|
|
36
|
+
const categoryData: Record<string, string[]> = {}
|
|
37
|
+
categories[0].items.forEach(cat => {
|
|
38
|
+
categoryData[cat.name] = []
|
|
39
|
+
})
|
|
40
|
+
items.forEach(item => {
|
|
41
|
+
item.categories[0].items.forEach(cat => {
|
|
42
|
+
if (categoryData[cat.name]) {
|
|
43
|
+
categoryData[cat.name].push(item.title)
|
|
44
|
+
}
|
|
45
|
+
})
|
|
46
|
+
})
|
|
47
|
+
|
|
48
|
+
const categoryNames = Object.keys(categoryData)
|
|
49
|
+
|
|
50
|
+
const displayedCategories = selectedCategory
|
|
51
|
+
? [selectedCategory]
|
|
52
|
+
: categoryNames
|
|
53
|
+
|
|
54
|
+
return (
|
|
55
|
+
<StyledGlossary>
|
|
56
|
+
<StyledGlossaryTitle>{title}</StyledGlossaryTitle>
|
|
57
|
+
<StyledGlossarySubtitle>{subtitle}</StyledGlossarySubtitle>
|
|
58
|
+
|
|
59
|
+
<SearchBar
|
|
60
|
+
value={searchTerm}
|
|
61
|
+
onChange={e => setSearchTerm(e.target.value)}
|
|
62
|
+
placeholder="What are you looking for?"
|
|
63
|
+
/>
|
|
64
|
+
|
|
65
|
+
<GlossaryCategoryIndex
|
|
66
|
+
categories={categoryNames}
|
|
67
|
+
selectedCategory={selectedCategory}
|
|
68
|
+
onChange={cat => setSelectedCategory(cat === selectedCategory ? null : cat)}
|
|
69
|
+
/>
|
|
70
|
+
|
|
71
|
+
<StyledGlossaryCategories>
|
|
72
|
+
{displayedCategories.map(category => (
|
|
73
|
+
<CategoriesWrapper
|
|
74
|
+
key={category}
|
|
75
|
+
category={category}
|
|
76
|
+
categoryItems={categoryData[category]}
|
|
77
|
+
/>
|
|
78
|
+
))}
|
|
79
|
+
</StyledGlossaryCategories>
|
|
80
|
+
</StyledGlossary>
|
|
81
|
+
)
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
export default Glossary
|
|
File without changes
|
|
@@ -0,0 +1,278 @@
|
|
|
1
|
+
import React from 'react'
|
|
2
|
+
import Glossary from './Glossary.component'
|
|
3
|
+
|
|
4
|
+
export default {
|
|
5
|
+
title: 'Organisms/Glossary',
|
|
6
|
+
component: Glossary
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
export const Basic = () => (
|
|
10
|
+
<Glossary
|
|
11
|
+
title="Glossary"
|
|
12
|
+
subtitle="Explore commonly used terms in the gaming world."
|
|
13
|
+
categories={[
|
|
14
|
+
{
|
|
15
|
+
name: 'glossary-category',
|
|
16
|
+
items: [
|
|
17
|
+
{ slug: 'a', name: 'A' },
|
|
18
|
+
{ slug: 'm', name: 'M' },
|
|
19
|
+
{ slug: 'b', name: 'B' },
|
|
20
|
+
{ slug: 'c', name: 'C' },
|
|
21
|
+
{ slug: 'd', name: 'D' },
|
|
22
|
+
{ slug: 'e', name: 'E' },
|
|
23
|
+
{ slug: 'f', name: 'F' },
|
|
24
|
+
{ slug: 'g', name: 'G' },
|
|
25
|
+
{ slug: 'h', name: 'H' },
|
|
26
|
+
{ slug: 'i', name: 'I' },
|
|
27
|
+
{ slug: 'j', name: 'J' },
|
|
28
|
+
{ slug: 'k', name: 'K' },
|
|
29
|
+
{ slug: 'l', name: 'L' },
|
|
30
|
+
{ slug: 'n', name: 'N' },
|
|
31
|
+
{ slug: 'o', name: 'O' },
|
|
32
|
+
{ slug: 'q', name: 'Q' },
|
|
33
|
+
{ slug: 'r', name: 'R' },
|
|
34
|
+
{ slug: 't', name: 'T' },
|
|
35
|
+
{ slug: 'u', name: 'U' },
|
|
36
|
+
{ slug: 'v', name: 'V' },
|
|
37
|
+
{ slug: 'w', name: 'W' },
|
|
38
|
+
{ slug: 'x', name: 'X' },
|
|
39
|
+
{ slug: 'y', name: 'Y' },
|
|
40
|
+
{ slug: 'z', name: 'Z' }
|
|
41
|
+
]
|
|
42
|
+
},
|
|
43
|
+
{
|
|
44
|
+
name: 'advanced-category',
|
|
45
|
+
items: [
|
|
46
|
+
{ slug: 'p', name: 'P' },
|
|
47
|
+
{ slug: 's', name: 'S' }
|
|
48
|
+
]
|
|
49
|
+
}
|
|
50
|
+
]}
|
|
51
|
+
items={[
|
|
52
|
+
{
|
|
53
|
+
title: 'Ace',
|
|
54
|
+
categories: [{ name: 'glossary-category', items: [{ slug: 'a', name: 'A' }] }]
|
|
55
|
+
},
|
|
56
|
+
{
|
|
57
|
+
title: 'AFK',
|
|
58
|
+
categories: [{ name: 'glossary-category', items: [{ slug: 'a', name: 'A' }] }]
|
|
59
|
+
},
|
|
60
|
+
{
|
|
61
|
+
title: 'Aggro',
|
|
62
|
+
categories: [{ name: 'glossary-category', items: [{ slug: 'a', name: 'A' }] }]
|
|
63
|
+
},
|
|
64
|
+
{
|
|
65
|
+
title: 'Buff',
|
|
66
|
+
categories: [{ name: 'glossary-category', items: [{ slug: 'b', name: 'B' }] }]
|
|
67
|
+
},
|
|
68
|
+
{
|
|
69
|
+
title: 'Bot',
|
|
70
|
+
categories: [{ name: 'glossary-category', items: [{ slug: 'b', name: 'B' }] }]
|
|
71
|
+
},
|
|
72
|
+
{
|
|
73
|
+
title: 'Cooldown',
|
|
74
|
+
categories: [{ name: 'glossary-category', items: [{ slug: 'c', name: 'C' }] }]
|
|
75
|
+
},
|
|
76
|
+
{
|
|
77
|
+
title: 'Carry',
|
|
78
|
+
categories: [{ name: 'glossary-category', items: [{ slug: 'c', name: 'C' }] }]
|
|
79
|
+
},
|
|
80
|
+
{
|
|
81
|
+
title: 'Debuff',
|
|
82
|
+
categories: [{ name: 'glossary-category', items: [{ slug: 'd', name: 'D' }] }]
|
|
83
|
+
},
|
|
84
|
+
{
|
|
85
|
+
title: 'DPS',
|
|
86
|
+
categories: [{ name: 'glossary-category', items: [{ slug: 'd', name: 'D' }] }]
|
|
87
|
+
},
|
|
88
|
+
{
|
|
89
|
+
title: 'Experience',
|
|
90
|
+
categories: [{ name: 'glossary-category', items: [{ slug: 'e', name: 'E' }] }]
|
|
91
|
+
},
|
|
92
|
+
{
|
|
93
|
+
title: 'Farm',
|
|
94
|
+
categories: [{ name: 'glossary-category', items: [{ slug: 'f', name: 'F' }] }]
|
|
95
|
+
},
|
|
96
|
+
{
|
|
97
|
+
title: 'Gank',
|
|
98
|
+
categories: [{ name: 'glossary-category', items: [{ slug: 'g', name: 'G' }] }]
|
|
99
|
+
},
|
|
100
|
+
{
|
|
101
|
+
title: 'Heal',
|
|
102
|
+
categories: [{ name: 'glossary-category', items: [{ slug: 'h', name: 'H' }] }]
|
|
103
|
+
},
|
|
104
|
+
{
|
|
105
|
+
title: 'Jungle',
|
|
106
|
+
categories: [{ name: 'glossary-category', items: [{ slug: 'j', name: 'J' }] }]
|
|
107
|
+
},
|
|
108
|
+
{
|
|
109
|
+
title: 'KDA',
|
|
110
|
+
categories: [{ name: 'glossary-category', items: [{ slug: 'k', name: 'K' }] }]
|
|
111
|
+
},
|
|
112
|
+
{
|
|
113
|
+
title: 'Lane',
|
|
114
|
+
categories: [{ name: 'glossary-category', items: [{ slug: 'l', name: 'L' }] }]
|
|
115
|
+
},
|
|
116
|
+
{
|
|
117
|
+
title: 'Multikill',
|
|
118
|
+
categories: [{ name: 'glossary-category', items: [{ slug: 'm', name: 'M' }] }]
|
|
119
|
+
},
|
|
120
|
+
{
|
|
121
|
+
title: 'Nerf',
|
|
122
|
+
categories: [{ name: 'glossary-category', items: [{ slug: 'n', name: 'N' }] }]
|
|
123
|
+
},
|
|
124
|
+
{
|
|
125
|
+
title: 'Objective',
|
|
126
|
+
categories: [{ name: 'glossary-category', items: [{ slug: 'o', name: 'O' }] }]
|
|
127
|
+
},
|
|
128
|
+
{
|
|
129
|
+
title: 'Pentakill',
|
|
130
|
+
categories: [{ name: 'advanced-category', items: [{ slug: 'p', name: 'P' }] }]
|
|
131
|
+
},
|
|
132
|
+
{
|
|
133
|
+
title: 'Quest',
|
|
134
|
+
categories: [{ name: 'glossary-category', items: [{ slug: 'q', name: 'Q' }] }]
|
|
135
|
+
},
|
|
136
|
+
{
|
|
137
|
+
title: 'Respawn',
|
|
138
|
+
categories: [{ name: 'glossary-category', items: [{ slug: 'r', name: 'R' }] }]
|
|
139
|
+
},
|
|
140
|
+
{
|
|
141
|
+
title: 'Support',
|
|
142
|
+
categories: [{ name: 'advanced-category', items: [{ slug: 's', name: 'S' }] }]
|
|
143
|
+
},
|
|
144
|
+
{
|
|
145
|
+
title: 'Tank',
|
|
146
|
+
categories: [{ name: 'glossary-category', items: [{ slug: 't', name: 'T' }] }]
|
|
147
|
+
},
|
|
148
|
+
{
|
|
149
|
+
title: 'Ultimate',
|
|
150
|
+
categories: [{ name: 'glossary-category', items: [{ slug: 'u', name: 'U' }] }]
|
|
151
|
+
},
|
|
152
|
+
{
|
|
153
|
+
title: 'Vision',
|
|
154
|
+
categories: [{ name: 'glossary-category', items: [{ slug: 'v', name: 'V' }] }]
|
|
155
|
+
},
|
|
156
|
+
{
|
|
157
|
+
title: 'Wave',
|
|
158
|
+
categories: [{ name: 'glossary-category', items: [{ slug: 'w', name: 'W' }] }]
|
|
159
|
+
},
|
|
160
|
+
{
|
|
161
|
+
title: 'XP',
|
|
162
|
+
categories: [{ name: 'glossary-category', items: [{ slug: 'x', name: 'X' }] }]
|
|
163
|
+
},
|
|
164
|
+
{
|
|
165
|
+
title: 'Yolo',
|
|
166
|
+
categories: [{ name: 'glossary-category', items: [{ slug: 'y', name: 'Y' }] }]
|
|
167
|
+
},
|
|
168
|
+
{
|
|
169
|
+
title: 'Zoning',
|
|
170
|
+
categories: [{ name: 'glossary-category', items: [{ slug: 'z', name: 'Z' }] }]
|
|
171
|
+
},
|
|
172
|
+
// Additional terms
|
|
173
|
+
{
|
|
174
|
+
title: 'ADC',
|
|
175
|
+
categories: [{ name: 'glossary-category', items: [{ slug: 'a', name: 'A' }] }]
|
|
176
|
+
},
|
|
177
|
+
{
|
|
178
|
+
title: 'AoE',
|
|
179
|
+
categories: [{ name: 'glossary-category', items: [{ slug: 'a', name: 'A' }] }]
|
|
180
|
+
},
|
|
181
|
+
{
|
|
182
|
+
title: 'Backdoor',
|
|
183
|
+
categories: [{ name: 'glossary-category', items: [{ slug: 'b', name: 'B' }] }]
|
|
184
|
+
},
|
|
185
|
+
{
|
|
186
|
+
title: 'CC',
|
|
187
|
+
categories: [{ name: 'glossary-category', items: [{ slug: 'c', name: 'C' }] }]
|
|
188
|
+
},
|
|
189
|
+
{
|
|
190
|
+
title: 'Cheese',
|
|
191
|
+
categories: [{ name: 'glossary-category', items: [{ slug: 'c', name: 'C' }] }]
|
|
192
|
+
},
|
|
193
|
+
{
|
|
194
|
+
title: 'Draft',
|
|
195
|
+
categories: [{ name: 'glossary-category', items: [{ slug: 'd', name: 'D' }] }]
|
|
196
|
+
},
|
|
197
|
+
{
|
|
198
|
+
title: 'Engage',
|
|
199
|
+
categories: [{ name: 'glossary-category', items: [{ slug: 'e', name: 'E' }] }]
|
|
200
|
+
},
|
|
201
|
+
{
|
|
202
|
+
title: 'Feed',
|
|
203
|
+
categories: [{ name: 'glossary-category', items: [{ slug: 'f', name: 'F' }] }]
|
|
204
|
+
},
|
|
205
|
+
{
|
|
206
|
+
title: 'First Blood',
|
|
207
|
+
categories: [{ name: 'glossary-category', items: [{ slug: 'f', name: 'F' }] }]
|
|
208
|
+
},
|
|
209
|
+
{
|
|
210
|
+
title: 'GG',
|
|
211
|
+
categories: [{ name: 'glossary-category', items: [{ slug: 'g', name: 'G' }] }]
|
|
212
|
+
},
|
|
213
|
+
{
|
|
214
|
+
title: 'Harass',
|
|
215
|
+
categories: [{ name: 'glossary-category', items: [{ slug: 'h', name: 'H' }] }]
|
|
216
|
+
},
|
|
217
|
+
{
|
|
218
|
+
title: 'Initiate',
|
|
219
|
+
categories: [{ name: 'glossary-category', items: [{ slug: 'i', name: 'I' }] }]
|
|
220
|
+
},
|
|
221
|
+
{
|
|
222
|
+
title: 'Kiting',
|
|
223
|
+
categories: [{ name: 'glossary-category', items: [{ slug: 'k', name: 'K' }] }]
|
|
224
|
+
},
|
|
225
|
+
{
|
|
226
|
+
title: 'Leash',
|
|
227
|
+
categories: [{ name: 'glossary-category', items: [{ slug: 'l', name: 'L' }] }]
|
|
228
|
+
},
|
|
229
|
+
{
|
|
230
|
+
title: 'Meta',
|
|
231
|
+
categories: [{ name: 'glossary-category', items: [{ slug: 'm', name: 'M' }] }]
|
|
232
|
+
},
|
|
233
|
+
{
|
|
234
|
+
title: 'Outplay',
|
|
235
|
+
categories: [{ name: 'glossary-category', items: [{ slug: 'o', name: 'O' }] }]
|
|
236
|
+
},
|
|
237
|
+
{
|
|
238
|
+
title: 'Peel',
|
|
239
|
+
categories: [{ name: 'advanced-category', items: [{ slug: 'p', name: 'P' }] }]
|
|
240
|
+
},
|
|
241
|
+
{
|
|
242
|
+
title: 'Roam',
|
|
243
|
+
categories: [{ name: 'glossary-category', items: [{ slug: 'r', name: 'R' }] }]
|
|
244
|
+
},
|
|
245
|
+
{
|
|
246
|
+
title: 'Snowball',
|
|
247
|
+
categories: [{ name: 'advanced-category', items: [{ slug: 's', name: 'S' }] }]
|
|
248
|
+
},
|
|
249
|
+
{
|
|
250
|
+
title: 'Split Push',
|
|
251
|
+
categories: [{ name: 'advanced-category', items: [{ slug: 's', name: 'S' }] }]
|
|
252
|
+
},
|
|
253
|
+
{
|
|
254
|
+
title: 'Tilt',
|
|
255
|
+
categories: [{ name: 'glossary-category', items: [{ slug: 't', name: 'T' }] }]
|
|
256
|
+
},
|
|
257
|
+
{
|
|
258
|
+
title: 'Trade',
|
|
259
|
+
categories: [{ name: 'glossary-category', items: [{ slug: 't', name: 'T' }] }]
|
|
260
|
+
},
|
|
261
|
+
{
|
|
262
|
+
title: 'Wombo Combo',
|
|
263
|
+
categories: [{ name: 'glossary-category', items: [{ slug: 'w', name: 'W' }] }]
|
|
264
|
+
},
|
|
265
|
+
{
|
|
266
|
+
title: 'Zone',
|
|
267
|
+
categories: [{ name: 'glossary-category', items: [{ slug: 'z', name: 'Z' }] }]
|
|
268
|
+
}
|
|
269
|
+
]}
|
|
270
|
+
placeholder="What are you looking for?"
|
|
271
|
+
/>
|
|
272
|
+
)
|
|
273
|
+
Basic.parameters = {
|
|
274
|
+
backgrounds: {
|
|
275
|
+
default: 'glossary-bg',
|
|
276
|
+
values: [{ name: 'glossary-bg', value: '#33052F' }]
|
|
277
|
+
}
|
|
278
|
+
}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { colors } from '@/styles/variables'
|
|
2
|
+
import styled from 'styled-components'
|
|
3
|
+
|
|
4
|
+
export const StyledGlossary = styled.div`
|
|
5
|
+
display: flex;
|
|
6
|
+
flex-direction: column;
|
|
7
|
+
align-items: center;
|
|
8
|
+
width: 100%;
|
|
9
|
+
`
|
|
10
|
+
|
|
11
|
+
export const StyledGlossaryHeader = styled.div``
|
|
12
|
+
|
|
13
|
+
export const StyledGlossaryTitle = styled.h1`
|
|
14
|
+
color: ${colors.primary50};
|
|
15
|
+
`
|
|
16
|
+
|
|
17
|
+
export const StyledGlossarySubtitle = styled.h4``
|
|
18
|
+
|
|
19
|
+
export const StyledGlossaryIndex = styled.div``
|
|
20
|
+
|
|
21
|
+
export const StyledGlossaryCategories = styled.div`
|
|
22
|
+
width: 100%;
|
|
23
|
+
`
|
|
24
|
+
|
|
25
|
+
export const StyledGlossarySeparator = styled.div``
|
|
26
|
+
|
|
27
|
+
export const StyledGlossaryCategoryItems = styled.li``
|