ymy-components 0.0.64 → 0.0.65
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/animations/AnimatedText.d.ts +4 -1
- package/dist/buttons/CircleIconButton.styles.d.ts +1 -1
- package/dist/collections/ListItem.d.ts +3 -1
- package/dist/context/AnimatedTextContext.d.ts +13 -0
- package/dist/index.cjs +66 -66
- package/dist/index.d.ts +2 -0
- package/dist/index.js +931 -917
- package/dist/loading/LoadingScreen.styles.d.ts +1 -1
- package/package.json +1 -1
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { CSSProperties } from 'react';
|
|
2
2
|
import { default as DynamicLanguage, CharacterPreference } from '../types/DynamicLanguage';
|
|
3
|
+
export type StaticLanguage = 'english' | 'chinese';
|
|
3
4
|
type AnimatedTextProps = {
|
|
4
5
|
animate?: boolean;
|
|
5
6
|
content: DynamicLanguage;
|
|
@@ -9,6 +10,8 @@ type AnimatedTextProps = {
|
|
|
9
10
|
characterPreference?: CharacterPreference;
|
|
10
11
|
/** Maximum delay in milliseconds between animation cycles (default: 15000) */
|
|
11
12
|
maxDelay?: number;
|
|
13
|
+
/** Which language to display when animate is false (default: 'english') */
|
|
14
|
+
staticLanguage?: StaticLanguage;
|
|
12
15
|
};
|
|
13
|
-
export default function AnimatedText({ animate, content, textStyles, htmlElement, fadeIn, characterPreference, maxDelay, }: AnimatedTextProps): import("react/jsx-runtime").JSX.Element;
|
|
16
|
+
export default function AnimatedText({ animate: animateProp, content, textStyles, htmlElement, fadeIn, characterPreference: charPrefProp, maxDelay, staticLanguage: staticLangProp, }: AnimatedTextProps): import("react/jsx-runtime").JSX.Element;
|
|
14
17
|
export {};
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
export declare const StyledCircleButton: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components').FastOmit<import('@react-spring/web').AnimatedProps<{
|
|
2
|
+
children?: import('react').ReactNode;
|
|
2
3
|
slot?: string | undefined | undefined;
|
|
3
4
|
style?: {
|
|
4
5
|
accentColor?: import("csstype").Property.AccentColor | undefined;
|
|
@@ -851,7 +852,6 @@ export declare const StyledCircleButton: import('styled-components/dist/types').
|
|
|
851
852
|
content?: string | undefined | undefined;
|
|
852
853
|
onChange?: import('react').FormEventHandler<HTMLDivElement> | undefined;
|
|
853
854
|
onPause?: import('react').ReactEventHandler<HTMLDivElement> | undefined;
|
|
854
|
-
children?: import('react').ReactNode;
|
|
855
855
|
hidden?: boolean | undefined | undefined;
|
|
856
856
|
color?: string | undefined | undefined;
|
|
857
857
|
translate?: "yes" | "no" | undefined | undefined;
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { ReactElement } from 'react';
|
|
2
|
+
import { StaticLanguage } from '../animations/AnimatedText';
|
|
2
3
|
import { default as DynamicLanguage, CharacterPreference } from '../types/DynamicLanguage';
|
|
3
4
|
export declare const PrimaryIcons: {
|
|
4
5
|
readonly translate: import('react-icons/lib').IconType;
|
|
@@ -21,6 +22,7 @@ interface ListItemProps {
|
|
|
21
22
|
styles?: React.CSSProperties;
|
|
22
23
|
switchChecked?: boolean;
|
|
23
24
|
onSwitchChange?: (checked: boolean) => void;
|
|
25
|
+
staticLanguage?: StaticLanguage;
|
|
24
26
|
}
|
|
25
|
-
export declare const ListItem: ({ icon, text, textContent, characterPreference, animate, maxDelay, actionIcon, onClick, styles, switchChecked, onSwitchChange, }: ListItemProps) => ReactElement;
|
|
27
|
+
export declare const ListItem: ({ icon, text, textContent, characterPreference, animate, maxDelay, actionIcon, onClick, styles, switchChecked, onSwitchChange, staticLanguage, }: ListItemProps) => ReactElement;
|
|
26
28
|
export {};
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
import { StaticLanguage } from '../animations/AnimatedText';
|
|
3
|
+
import { CharacterPreference } from '../types/DynamicLanguage';
|
|
4
|
+
interface AnimatedTextDefaults {
|
|
5
|
+
staticLanguage?: StaticLanguage;
|
|
6
|
+
characterPreference?: CharacterPreference;
|
|
7
|
+
animate?: boolean;
|
|
8
|
+
}
|
|
9
|
+
export declare function AnimatedTextProvider({ children, ...defaults }: AnimatedTextDefaults & {
|
|
10
|
+
children: ReactNode;
|
|
11
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
12
|
+
export declare function useAnimatedTextDefaults(): AnimatedTextDefaults;
|
|
13
|
+
export {};
|