@anywayseo/tools 1.0.0
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/LICENSE +21 -0
- package/README.md +62 -0
- package/dist/components/author/index.d.ts +8 -0
- package/dist/components/contact-form/index.d.ts +3 -0
- package/dist/components/expert/bio/index.d.ts +8 -0
- package/dist/components/expert/index.d.ts +8 -0
- package/dist/components/expert-tip/index.d.ts +9 -0
- package/dist/components/faq/index.d.ts +9 -0
- package/dist/components/features/index.d.ts +8 -0
- package/dist/components/game-demo/content/index.d.ts +10 -0
- package/dist/components/game-demo/index.d.ts +10 -0
- package/dist/components/game-demo/preview/index.d.ts +9 -0
- package/dist/components/game-info/index.d.ts +7 -0
- package/dist/components/game-info/item/index.d.ts +7 -0
- package/dist/components/game-info/utils.d.ts +2 -0
- package/dist/components/how-to/index.d.ts +8 -0
- package/dist/components/index.cjs +14 -0
- package/dist/components/index.d.ts +11 -0
- package/dist/components/index.mjs +14 -0
- package/dist/components/layout/content/index.d.ts +3 -0
- package/dist/components/layout/footer/brand/index.d.ts +6 -0
- package/dist/components/layout/footer/copyright/index.d.ts +3 -0
- package/dist/components/layout/footer/disclaimer/index.d.ts +3 -0
- package/dist/components/layout/footer/index.d.ts +3 -0
- package/dist/components/layout/footer/navigation/index.d.ts +3 -0
- package/dist/components/layout/header/index.d.ts +3 -0
- package/dist/components/layout/header/navbar/brand/index.d.ts +6 -0
- package/dist/components/layout/header/navbar/index.d.ts +6 -0
- package/dist/components/layout/header/navbar/navigation/desktop/index.d.ts +4 -0
- package/dist/components/layout/header/navbar/navigation/desktop/item/index.d.ts +5 -0
- package/dist/components/layout/header/navbar/navigation/index.d.ts +4 -0
- package/dist/components/layout/header/navbar/navigation/mobile/index.d.ts +4 -0
- package/dist/components/layout/header/navbar/navigation/mobile/item/index.d.ts +5 -0
- package/dist/components/layout/header/navbar/navigation/types.d.ts +4 -0
- package/dist/components/layout/header/navbar/theme-toggler/index.d.ts +3 -0
- package/dist/components/layout/hero/index.d.ts +9 -0
- package/dist/components/layout/index.d.ts +12 -0
- package/dist/components/layout/logo/index.d.ts +3 -0
- package/dist/components/layout/main/index.d.ts +3 -0
- package/dist/components/layout/scroll-to-top/index.d.ts +3 -0
- package/dist/components/pros-cons/card/index.d.ts +8 -0
- package/dist/components/pros-cons/card/utils.d.ts +6 -0
- package/dist/components/pros-cons/index.d.ts +8 -0
- package/dist/components/seo/index.d.ts +16 -0
- package/dist/hooks/index.cjs +4 -0
- package/dist/hooks/index.d.ts +1 -0
- package/dist/hooks/index.mjs +4 -0
- package/dist/hooks/use-primary-colors/index.d.ts +6 -0
- package/dist/i18n/index.cjs +7 -0
- package/dist/i18n/index.d.ts +9 -0
- package/dist/i18n/index.mjs +7 -0
- package/dist/i18n/resources/en/index.d.ts +99 -0
- package/dist/i18n/resources/index.d.ts +8 -0
- package/dist/i18n/resources/it/index.d.ts +99 -0
- package/dist/index-BWuTDC6H.js +17 -0
- package/dist/index-Bh5idiRE.mjs +257 -0
- package/dist/index-Bs4zA1wD.mjs +17 -0
- package/dist/index-BtWxmLHW.mjs +80 -0
- package/dist/index-D96zh94V.js +16 -0
- package/dist/index-DB1dS9cp.js +256 -0
- package/dist/index-Dfw_EKZ6.mjs +767 -0
- package/dist/index-IpSV-c71.js +8 -0
- package/dist/index-JMmaWcmu.js +79 -0
- package/dist/index-NWY9BnRg.js +766 -0
- package/dist/index-wbMOJRW_.mjs +18 -0
- package/dist/index-xuSxvz5z.mjs +9 -0
- package/dist/index.cjs +36 -0
- package/dist/index.d.ts +6 -0
- package/dist/index.mjs +36 -0
- package/dist/providers/index.cjs +7 -0
- package/dist/providers/index.d.ts +2 -0
- package/dist/providers/index.mjs +7 -0
- package/dist/providers/mdx-provider/index.d.ts +3 -0
- package/dist/providers/site-metadata-provider/index.d.ts +14 -0
- package/dist/style.css +15 -0
- package/dist/types/author/index.d.ts +17 -0
- package/dist/types/faq/index.d.ts +4 -0
- package/dist/types/feature/index.d.ts +4 -0
- package/dist/types/game-info/index.d.ts +63 -0
- package/dist/types/how-to/index.d.ts +5 -0
- package/dist/types/i18n/index.d.ts +2 -0
- package/dist/types/index.d.ts +9 -0
- package/dist/types/navigation/index.d.ts +9 -0
- package/dist/types/pros-cons/index.d.ts +6 -0
- package/dist/types/site-metadata/index.d.ts +10 -0
- package/dist/utils/date/index.d.ts +9 -0
- package/dist/utils/index.cjs +11 -0
- package/dist/utils/index.d.ts +3 -0
- package/dist/utils/index.mjs +11 -0
- package/dist/utils/numbers/index.d.ts +19 -0
- package/dist/utils/numbers/types.d.ts +1 -0
- package/dist/utils/url/index.d.ts +1 -0
- package/package.json +99 -0
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2025 Anywayseo
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/README.md
ADDED
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
# Shared UI Components & Modules for Anywayseo projects
|
|
2
|
+
|
|
3
|
+
A modular UI component library designed for Anywayseo blog sites, offering reusable React components and utilities to enhance development speed and consistency.
|
|
4
|
+
|
|
5
|
+
## Installation
|
|
6
|
+
|
|
7
|
+
```bash
|
|
8
|
+
npm install @anywayseo/tools
|
|
9
|
+
# or
|
|
10
|
+
yarn add @anywayseo/tools
|
|
11
|
+
```
|
|
12
|
+
|
|
13
|
+
### Peer Dependencies
|
|
14
|
+
|
|
15
|
+
This package requires the following peer dependencies:
|
|
16
|
+
|
|
17
|
+
- "@chakra-ui/icons": "^2.0.0",
|
|
18
|
+
- "@chakra-ui/react": "^2.0.0",
|
|
19
|
+
- "@emotion/react": "^11.0.0",
|
|
20
|
+
- "@emotion/styled": "^11.0.0",
|
|
21
|
+
- "@mdx-js/react": "^2.0.0",
|
|
22
|
+
- "framer-motion": "^12.0.6",
|
|
23
|
+
- "gatsby": "^5.0.0",
|
|
24
|
+
- "gatsby-plugin-image": "^3.0.0",
|
|
25
|
+
- "i18next": "^24.0.0",
|
|
26
|
+
- "react": "^18.3.1",
|
|
27
|
+
- "react-dom": "^18.3.1",
|
|
28
|
+
- "react-i18next": "^15.0.0"
|
|
29
|
+
|
|
30
|
+
## Usage
|
|
31
|
+
|
|
32
|
+
Importing Components
|
|
33
|
+
|
|
34
|
+
```tsx
|
|
35
|
+
import type { IAuthor } from '@anywayseo/tools';
|
|
36
|
+
import { Author, getCurrentYear } from '@anywayseo/tools';
|
|
37
|
+
|
|
38
|
+
const BlogPreview = ({ author }) => (
|
|
39
|
+
<div>
|
|
40
|
+
<Author author={author} />
|
|
41
|
+
{getCurrentYear()}
|
|
42
|
+
</div>
|
|
43
|
+
);
|
|
44
|
+
```
|
|
45
|
+
|
|
46
|
+
## Available Modules:
|
|
47
|
+
|
|
48
|
+
- Components
|
|
49
|
+
|
|
50
|
+
- Hooks
|
|
51
|
+
|
|
52
|
+
- i18n
|
|
53
|
+
|
|
54
|
+
- Providers
|
|
55
|
+
|
|
56
|
+
- Types
|
|
57
|
+
|
|
58
|
+
- Utilities
|
|
59
|
+
|
|
60
|
+
## License
|
|
61
|
+
|
|
62
|
+
MIT License © 2025 Anywayseo
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { FC } from 'react';
|
|
2
|
+
import { BoxProps } from '@chakra-ui/react';
|
|
3
|
+
import { IAuthor } from '../../types';
|
|
4
|
+
type ExpertTipProps = {
|
|
5
|
+
tip: string;
|
|
6
|
+
expert?: IAuthor;
|
|
7
|
+
} & BoxProps;
|
|
8
|
+
declare const ExpertTip: FC<ExpertTipProps>;
|
|
9
|
+
export default ExpertTip;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { FC } from 'react';
|
|
2
|
+
type GameDemoContentProps = {
|
|
3
|
+
src: string;
|
|
4
|
+
isFullscreen: boolean;
|
|
5
|
+
isLoaded: boolean;
|
|
6
|
+
onLoad: VoidFunction;
|
|
7
|
+
onToggleFullscreen: VoidFunction;
|
|
8
|
+
};
|
|
9
|
+
declare const GameDemoContent: FC<GameDemoContentProps>;
|
|
10
|
+
export default GameDemoContent;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { FC } from 'react';
|
|
2
|
+
import { BoxProps } from '@chakra-ui/react';
|
|
3
|
+
import { GatsbyImageProps } from 'gatsby-plugin-image';
|
|
4
|
+
type GameDemoProps = {
|
|
5
|
+
name: string;
|
|
6
|
+
src: string;
|
|
7
|
+
previewImageFit?: GatsbyImageProps['objectFit'];
|
|
8
|
+
} & BoxProps;
|
|
9
|
+
declare const GameDemo: FC<GameDemoProps>;
|
|
10
|
+
export default GameDemo;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { FC } from 'react';
|
|
2
|
+
import { GatsbyImageProps } from 'gatsby-plugin-image';
|
|
3
|
+
type GameDemoPreviewProps = {
|
|
4
|
+
gameName: string;
|
|
5
|
+
previewImageFit?: GatsbyImageProps['objectFit'];
|
|
6
|
+
onPlay: VoidFunction;
|
|
7
|
+
};
|
|
8
|
+
declare const GameDemoPreview: FC<GameDemoPreviewProps>;
|
|
9
|
+
export default GameDemoPreview;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
|
+
const index = require("../index-NWY9BnRg.js");
|
|
4
|
+
exports.Author = index.Author;
|
|
5
|
+
exports.ContactForm = index.ContactForm;
|
|
6
|
+
exports.ExpertTip = index.ExpertTip;
|
|
7
|
+
exports.Faq = index.Faq;
|
|
8
|
+
exports.Features = index.Features;
|
|
9
|
+
exports.GameDemo = index.GameDemo;
|
|
10
|
+
exports.GameInfo = index.GameInfo;
|
|
11
|
+
exports.HowTo = index.HowTo;
|
|
12
|
+
exports.Layout = index.Layout;
|
|
13
|
+
exports.ProsCons = index.ProsCons;
|
|
14
|
+
exports.Seo = index.Seo;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
export { default as Author } from './author';
|
|
2
|
+
export { default as ContactForm } from './contact-form';
|
|
3
|
+
export { default as ExpertTip } from './expert-tip';
|
|
4
|
+
export { default as Faq } from './faq';
|
|
5
|
+
export { default as Features } from './features';
|
|
6
|
+
export { default as GameDemo } from './game-demo';
|
|
7
|
+
export { default as GameInfo } from './game-info';
|
|
8
|
+
export { default as HowTo } from './how-to';
|
|
9
|
+
export { default as Layout } from './layout';
|
|
10
|
+
export { default as ProsCons } from './pros-cons';
|
|
11
|
+
export { default as Seo } from './seo';
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { A, C, E, F, a, G, b, H, L, P, S } from "../index-Dfw_EKZ6.mjs";
|
|
2
|
+
export {
|
|
3
|
+
A as Author,
|
|
4
|
+
C as ContactForm,
|
|
5
|
+
E as ExpertTip,
|
|
6
|
+
F as Faq,
|
|
7
|
+
a as Features,
|
|
8
|
+
G as GameDemo,
|
|
9
|
+
b as GameInfo,
|
|
10
|
+
H as HowTo,
|
|
11
|
+
L as Layout,
|
|
12
|
+
P as ProsCons,
|
|
13
|
+
S as Seo
|
|
14
|
+
};
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { FC, ReactNode } from 'react';
|
|
2
|
+
import { default as Content } from './content';
|
|
3
|
+
import { default as Hero } from './hero';
|
|
4
|
+
interface ILayoutComponents {
|
|
5
|
+
Hero: typeof Hero;
|
|
6
|
+
Content: typeof Content;
|
|
7
|
+
}
|
|
8
|
+
type LayoutProps = {
|
|
9
|
+
children?: ((components: ILayoutComponents) => ReactNode) | ReactNode;
|
|
10
|
+
};
|
|
11
|
+
declare const Layout: FC<LayoutProps>;
|
|
12
|
+
export default Layout;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { FC } from 'react';
|
|
2
|
+
import { IProsConsItem, ProsConsItemType } from '../../../types';
|
|
3
|
+
type ProsConsCardProps = {
|
|
4
|
+
itemType: ProsConsItemType;
|
|
5
|
+
items: IProsConsItem[];
|
|
6
|
+
};
|
|
7
|
+
declare const ProsConsCard: FC<ProsConsCardProps>;
|
|
8
|
+
export default ProsConsCard;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { BoxProps, ComponentWithAs } from '@chakra-ui/react';
|
|
2
|
+
import { ProsConsItemType } from '../../../types';
|
|
3
|
+
export declare const TitleMap: Record<ProsConsItemType, 'advantages' | 'disadvantages'>;
|
|
4
|
+
export declare const IconMap: Record<ProsConsItemType, ComponentWithAs<'svg'>>;
|
|
5
|
+
export declare const IconColorMap: Record<ProsConsItemType, BoxProps['color']>;
|
|
6
|
+
export declare const BgColorMap: Record<ProsConsItemType, BoxProps['backgroundColor']>;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { FC, PropsWithChildren } from 'react';
|
|
2
|
+
import { ISiteMetadata, LanguageCode } from '../../types';
|
|
3
|
+
interface IGetMetaItemFunctionArgs {
|
|
4
|
+
domain: string;
|
|
5
|
+
currentYear: string;
|
|
6
|
+
currentMonth: string;
|
|
7
|
+
}
|
|
8
|
+
type GetMetaItemFunction = ({ domain, currentYear, currentMonth }: IGetMetaItemFunctionArgs) => string;
|
|
9
|
+
type SeoProps = {
|
|
10
|
+
siteMetadata: ISiteMetadata;
|
|
11
|
+
title?: string | GetMetaItemFunction;
|
|
12
|
+
description?: string | GetMetaItemFunction;
|
|
13
|
+
lang?: LanguageCode;
|
|
14
|
+
};
|
|
15
|
+
declare const Seo: FC<PropsWithChildren<SeoProps>>;
|
|
16
|
+
export default Seo;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as usePrimaryColors } from './use-primary-colors';
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { DefaultResourceType, default as resources } from './resources';
|
|
2
|
+
import { default as i18n } from 'i18next';
|
|
3
|
+
declare module 'i18next' {
|
|
4
|
+
interface CustomTypeOptions {
|
|
5
|
+
defaultNS: Extract<DefaultResourceType, 'common'>;
|
|
6
|
+
resources: DefaultResourceType;
|
|
7
|
+
}
|
|
8
|
+
}
|
|
9
|
+
export { i18n, resources };
|
|
@@ -0,0 +1,99 @@
|
|
|
1
|
+
declare const dictionary: {
|
|
2
|
+
readonly pageNotFound: {
|
|
3
|
+
title: string;
|
|
4
|
+
description: string;
|
|
5
|
+
action: string;
|
|
6
|
+
};
|
|
7
|
+
readonly footer: {
|
|
8
|
+
copyright: string;
|
|
9
|
+
disclaimer: {
|
|
10
|
+
title: string;
|
|
11
|
+
description: string;
|
|
12
|
+
};
|
|
13
|
+
};
|
|
14
|
+
readonly gameDemo: {
|
|
15
|
+
warning: string;
|
|
16
|
+
action: {
|
|
17
|
+
playForFree: string;
|
|
18
|
+
activateFullscreen: string;
|
|
19
|
+
deactivateFullscreen: string;
|
|
20
|
+
};
|
|
21
|
+
};
|
|
22
|
+
readonly gameInfo: {
|
|
23
|
+
title: string;
|
|
24
|
+
group: {
|
|
25
|
+
general: string;
|
|
26
|
+
features: string;
|
|
27
|
+
};
|
|
28
|
+
feature: {
|
|
29
|
+
BONUS_FEATURES: string;
|
|
30
|
+
COMPATIBILITY: string;
|
|
31
|
+
DEVELOPER: string;
|
|
32
|
+
HAS_AUTOPLAY: string;
|
|
33
|
+
HAS_BONUS_PURCHASE: string;
|
|
34
|
+
HAS_COLLECTION_SYMBOLS: string;
|
|
35
|
+
HAS_DEMO: string;
|
|
36
|
+
HAS_FAST_SPIN: string;
|
|
37
|
+
HAS_FREE_SPINS: string;
|
|
38
|
+
HAS_PROGRESSIVE_JACKPOT: string;
|
|
39
|
+
LANGUAGES: string;
|
|
40
|
+
MAX_WIN: string;
|
|
41
|
+
MAX_BET: string;
|
|
42
|
+
MIN_BET: string;
|
|
43
|
+
NAME: string;
|
|
44
|
+
PAY_LINES: string;
|
|
45
|
+
REELS_NUMBER: string;
|
|
46
|
+
RELEASE_DATE: string;
|
|
47
|
+
RTP: string;
|
|
48
|
+
THEME: string;
|
|
49
|
+
TYPE: string;
|
|
50
|
+
VOLATILITY: string;
|
|
51
|
+
};
|
|
52
|
+
value: {
|
|
53
|
+
boolean: {
|
|
54
|
+
true: string;
|
|
55
|
+
false: string;
|
|
56
|
+
};
|
|
57
|
+
volatility: {
|
|
58
|
+
HIGH: string;
|
|
59
|
+
MEDIUM: string;
|
|
60
|
+
LOW: string;
|
|
61
|
+
};
|
|
62
|
+
};
|
|
63
|
+
};
|
|
64
|
+
readonly prosCons: {
|
|
65
|
+
advantages: string;
|
|
66
|
+
disadvantages: string;
|
|
67
|
+
};
|
|
68
|
+
readonly author: {
|
|
69
|
+
title: string;
|
|
70
|
+
action: {
|
|
71
|
+
expand: string;
|
|
72
|
+
collapse: string;
|
|
73
|
+
};
|
|
74
|
+
};
|
|
75
|
+
readonly contactForm: {
|
|
76
|
+
field: {
|
|
77
|
+
name: {
|
|
78
|
+
label: string;
|
|
79
|
+
placeholder: string;
|
|
80
|
+
};
|
|
81
|
+
email: {
|
|
82
|
+
label: string;
|
|
83
|
+
placeholder: string;
|
|
84
|
+
};
|
|
85
|
+
message: {
|
|
86
|
+
label: string;
|
|
87
|
+
placeholder: string;
|
|
88
|
+
};
|
|
89
|
+
};
|
|
90
|
+
notification: {
|
|
91
|
+
title: string;
|
|
92
|
+
description: string;
|
|
93
|
+
};
|
|
94
|
+
action: {
|
|
95
|
+
send: string;
|
|
96
|
+
};
|
|
97
|
+
};
|
|
98
|
+
};
|
|
99
|
+
export default dictionary;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { LanguageCode } from '../../types';
|
|
2
|
+
import { default as en } from './en';
|
|
3
|
+
type DefaultResourceType = typeof en;
|
|
4
|
+
declare const resources: {
|
|
5
|
+
[key in LanguageCode]: DefaultResourceType;
|
|
6
|
+
};
|
|
7
|
+
export type { DefaultResourceType };
|
|
8
|
+
export default resources;
|