oddsgate-ds 1.0.166 → 1.0.168
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/index.js +4 -4
- package/dist/cjs/index.js.map +1 -1
- package/dist/cjs/types/components/atoms/LegalLinks/LegalLinks.component.d.ts +4 -0
- package/dist/cjs/types/components/atoms/LegalLinks/LegalLinks.interface.d.ts +10 -0
- package/dist/cjs/types/components/atoms/LegalLinks/LegalLinks.theme.d.ts +3 -0
- package/dist/cjs/types/components/atoms/LegalLinks/index.d.ts +1 -0
- package/dist/cjs/types/index.d.ts +1 -0
- package/dist/esm/index.js +5 -5
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/types/components/atoms/LegalLinks/LegalLinks.component.d.ts +4 -0
- package/dist/esm/types/components/atoms/LegalLinks/LegalLinks.interface.d.ts +10 -0
- package/dist/esm/types/components/atoms/LegalLinks/LegalLinks.theme.d.ts +3 -0
- package/dist/esm/types/components/atoms/LegalLinks/index.d.ts +1 -0
- package/dist/esm/types/index.d.ts +1 -0
- package/dist/types.d.ts +13 -1
- package/package.json +1 -1
- package/src/components/atoms/LegalLinks/LegalLinks.component.tsx +35 -0
- package/src/components/atoms/LegalLinks/LegalLinks.interface.ts +12 -0
- package/src/components/atoms/LegalLinks/LegalLinks.stories.tsx +43 -0
- package/src/components/atoms/LegalLinks/LegalLinks.theme.ts +23 -0
- package/src/components/atoms/LegalLinks/index.ts +1 -0
- package/src/index.ts +1 -0
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { ILegalLinks } from './LegalLinks.interface';
|
|
3
|
+
export declare const StyledLegalLinks: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components/dist/types").Substitute<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLUListElement>, HTMLUListElement>, ILegalLinks>> & string;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default } from './LegalLinks.component';
|
|
@@ -21,6 +21,7 @@ export { default as CloseButton } from './components/atoms/CloseButton';
|
|
|
21
21
|
export { default as Counter } from './components/atoms/Counter';
|
|
22
22
|
export { default as ScrollingNav } from './components/atoms/ScrollingNav';
|
|
23
23
|
export { default as SocialLinks } from './components/atoms/SocialLinks';
|
|
24
|
+
export { default as LegalLinks } from './components/atoms/LegalLinks';
|
|
24
25
|
export { default as Marquee } from './components/atoms/Marquee';
|
|
25
26
|
export { default as CardMarquee } from './components/atoms/CardMarquee';
|
|
26
27
|
export { default as PortalComponent } from './components/common/PortalComponent';
|
package/dist/types.d.ts
CHANGED
|
@@ -380,6 +380,18 @@ type ISocialLinks = {
|
|
|
380
380
|
|
|
381
381
|
declare const SocialLinks: ({ variant, socials, className, style, ...props }: ISocialLinks) => React__default.JSX.Element;
|
|
382
382
|
|
|
383
|
+
type ILegalLink = {
|
|
384
|
+
label: string;
|
|
385
|
+
url: string;
|
|
386
|
+
};
|
|
387
|
+
type ILegalLinks = {
|
|
388
|
+
links?: ILegalLink[];
|
|
389
|
+
className?: string;
|
|
390
|
+
style?: CSSProperties;
|
|
391
|
+
};
|
|
392
|
+
|
|
393
|
+
declare const LegalLinks: ({ links, className, style, }: ILegalLinks) => React__default.JSX.Element;
|
|
394
|
+
|
|
383
395
|
type IMarquee = {
|
|
384
396
|
text?: string;
|
|
385
397
|
repeat?: number;
|
|
@@ -682,4 +694,4 @@ declare function useMediaMatch(query?: string): boolean;
|
|
|
682
694
|
|
|
683
695
|
declare const debounce: (callback: any, wait: number) => (...args: any) => void;
|
|
684
696
|
|
|
685
|
-
export { Accordion, AccordionItem, BlogCard, Button, CardMarquee, CareersCard, CheckRadioField, Chip, CircularSlider, CloseButton, Column, Counter, Cover, Dropdown, DropdownItem, EmptyState, EventsCard, Flex, FormField, GlobalStyles, Heading, Icon, IconBox, IconTitle, ImageWrapper, LicenseCard, Loader, LogosCard, Marquee, Modal, NewsCard, OffCanvas, PortalComponent, ProductCard, ProductsSlider, Quote, RichText, Row, ScrollingNav, Separator, ShareModal, Slider, SocialLinks, Spacer, Tabs, TeamCard, Video, VideoEmbed, clickOutSideToClose, debounce, iconsList, isTouchDevice, useMediaMatch, variables };
|
|
697
|
+
export { Accordion, AccordionItem, BlogCard, Button, CardMarquee, CareersCard, CheckRadioField, Chip, CircularSlider, CloseButton, Column, Counter, Cover, Dropdown, DropdownItem, EmptyState, EventsCard, Flex, FormField, GlobalStyles, Heading, Icon, IconBox, IconTitle, ImageWrapper, LegalLinks, LicenseCard, Loader, LogosCard, Marquee, Modal, NewsCard, OffCanvas, PortalComponent, ProductCard, ProductsSlider, Quote, RichText, Row, ScrollingNav, Separator, ShareModal, Slider, SocialLinks, Spacer, Tabs, TeamCard, Video, VideoEmbed, clickOutSideToClose, debounce, iconsList, isTouchDevice, useMediaMatch, variables };
|
package/package.json
CHANGED
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import { ILegalLinks } from './LegalLinks.interface'
|
|
2
|
+
import React from 'react'
|
|
3
|
+
import { StyledLegalLinks } from './LegalLinks.theme'
|
|
4
|
+
|
|
5
|
+
const LegalLinks = ({
|
|
6
|
+
links,
|
|
7
|
+
className,
|
|
8
|
+
style,
|
|
9
|
+
}: ILegalLinks) => {
|
|
10
|
+
if (!links) return <></>
|
|
11
|
+
|
|
12
|
+
return (
|
|
13
|
+
<StyledLegalLinks className={className} style={style}>
|
|
14
|
+
{links.map((link, index) => {
|
|
15
|
+
if (!link.label || !link.url) return <></>
|
|
16
|
+
|
|
17
|
+
return (
|
|
18
|
+
<li key={`legalLink-${index}`}>
|
|
19
|
+
<a
|
|
20
|
+
href={link.url}
|
|
21
|
+
target="_blank"
|
|
22
|
+
aria-label={link.label}
|
|
23
|
+
rel="noreferrer"
|
|
24
|
+
className="font-epilogue"
|
|
25
|
+
>
|
|
26
|
+
{link.label}
|
|
27
|
+
</a>
|
|
28
|
+
</li>
|
|
29
|
+
)
|
|
30
|
+
})}
|
|
31
|
+
</StyledLegalLinks>
|
|
32
|
+
)
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
export default LegalLinks
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
import type { Meta, StoryObj } from '@storybook/react'
|
|
2
|
+
|
|
3
|
+
import { ILegalLinks } from './LegalLinks.interface'
|
|
4
|
+
import React from 'react'
|
|
5
|
+
import LegalLinks from './LegalLinks.component'
|
|
6
|
+
|
|
7
|
+
// More on default export: https://storybook.js.org/docs/react/writing-stories/introduction#default-export
|
|
8
|
+
export default {
|
|
9
|
+
title: 'Components/LegalLinks',
|
|
10
|
+
component: LegalLinks,
|
|
11
|
+
tags: ['autodocs'],
|
|
12
|
+
argTypes: {}
|
|
13
|
+
} as Meta
|
|
14
|
+
|
|
15
|
+
export const Example: StoryObj<ILegalLinks> = {
|
|
16
|
+
args: {
|
|
17
|
+
links: [
|
|
18
|
+
{
|
|
19
|
+
'label': 'Terms of Service',
|
|
20
|
+
'url': 'https://www.miew.com/terms-of-service'
|
|
21
|
+
},
|
|
22
|
+
{
|
|
23
|
+
'label': 'Privacy Policy',
|
|
24
|
+
'url': 'https://www.miew.com/privacy-policy'
|
|
25
|
+
},
|
|
26
|
+
{
|
|
27
|
+
'label': 'Cookie Policy',
|
|
28
|
+
'url': 'https://www.miew.com/cookie-policy'
|
|
29
|
+
},
|
|
30
|
+
{
|
|
31
|
+
'label': 'Accessibility Statement',
|
|
32
|
+
'url': 'https://www.miew.com/accessibility-statement'
|
|
33
|
+
}
|
|
34
|
+
]
|
|
35
|
+
},
|
|
36
|
+
decorators: [
|
|
37
|
+
(Story) => (
|
|
38
|
+
<div style={{ background: 'black', padding: '2rem' }}>
|
|
39
|
+
{Story()}
|
|
40
|
+
</div>
|
|
41
|
+
)
|
|
42
|
+
]
|
|
43
|
+
}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { responsiveMedia } from '@/styles/variables'
|
|
2
|
+
import styled from 'styled-components'
|
|
3
|
+
|
|
4
|
+
import { ILegalLinks } from './LegalLinks.interface'
|
|
5
|
+
|
|
6
|
+
export const StyledLegalLinks = styled.ul<ILegalLinks>`
|
|
7
|
+
display: inline-flex;
|
|
8
|
+
align-items: center;
|
|
9
|
+
flex-flow: row wrap;
|
|
10
|
+
gap: 32px;
|
|
11
|
+
|
|
12
|
+
& li {
|
|
13
|
+
& a {
|
|
14
|
+
font-size: 15px;
|
|
15
|
+
font-style: normal;
|
|
16
|
+
font-weight: 400;
|
|
17
|
+
transition: all 0.3s linear;
|
|
18
|
+
&:hover {
|
|
19
|
+
opacity: 0.6;
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
`
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default } from './LegalLinks.component'
|
package/src/index.ts
CHANGED
|
@@ -23,6 +23,7 @@ export { default as CloseButton } from './components/atoms/CloseButton'
|
|
|
23
23
|
export { default as Counter } from './components/atoms/Counter'
|
|
24
24
|
export { default as ScrollingNav } from './components/atoms/ScrollingNav'
|
|
25
25
|
export { default as SocialLinks } from './components/atoms/SocialLinks'
|
|
26
|
+
export { default as LegalLinks } from './components/atoms/LegalLinks'
|
|
26
27
|
export { default as Marquee } from './components/atoms/Marquee'
|
|
27
28
|
export { default as CardMarquee } from './components/atoms/CardMarquee'
|
|
28
29
|
|