greenole-design-system 1.1.28 → 1.1.30

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.
@@ -0,0 +1,4 @@
1
+ import { default as React } from 'react';
2
+ import { InputProps } from './Input.types';
3
+ export declare const Input: React.FC<InputProps>;
4
+ export default Input;
@@ -0,0 +1,8 @@
1
+ import { Meta, StoryObj } from '@storybook/react';
2
+ import { default as Input } from './Input';
3
+ declare const meta: Meta<typeof Input>;
4
+ export default meta;
5
+ type Story = StoryObj<typeof Input>;
6
+ export declare const Playground: Story;
7
+ export declare const States: Story;
8
+ export declare const WithTanStackForm: Story;
@@ -0,0 +1,20 @@
1
+ export declare const Wrapper: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components/dist/types').Substitute<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {
2
+ fullWidth?: boolean;
3
+ }>> & string;
4
+ export declare const Label: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components').FastOmit<import('react').DetailedHTMLProps<import('react').LabelHTMLAttributes<HTMLLabelElement>, HTMLLabelElement>, never>> & string;
5
+ export declare const FieldWrapper: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components/dist/types').Substitute<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {
6
+ disabled?: boolean;
7
+ hasError?: boolean;
8
+ isValid?: boolean;
9
+ readOnly?: boolean;
10
+ textArea?: boolean;
11
+ }>> & string;
12
+ export declare const IconWrapper: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components').FastOmit<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, never>> & string;
13
+ export declare const BaseFieldStyles: import('styled-components').RuleSet<object>;
14
+ export declare const InputField: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components').FastOmit<import('react').DetailedHTMLProps<import('react').InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>, never>> & string;
15
+ export declare const TextAreaField: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components').FastOmit<import('react').DetailedHTMLProps<import('react').TextareaHTMLAttributes<HTMLTextAreaElement>, HTMLTextAreaElement>, never>> & string;
16
+ export declare const ErrorText: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components').FastOmit<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, never>> & string;
17
+ export declare const Subtitle: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components').FastOmit<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
18
+ export declare const CharCounter: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components/dist/types').Substitute<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {
19
+ hasError?: boolean;
20
+ }>> & string;
@@ -0,0 +1,23 @@
1
+ import { TypographyVariant } from '../../components/Typography/Typography';
2
+ export type InputType = React.HTMLInputTypeAttribute;
3
+ type InputElementProps = React.InputHTMLAttributes<HTMLInputElement>;
4
+ type TextAreaElementProps = React.TextareaHTMLAttributes<HTMLTextAreaElement>;
5
+ export interface InputProps extends Omit<InputElementProps & TextAreaElementProps, "required" | "readOnly"> {
6
+ label?: string;
7
+ labelSize?: TypographyVariant;
8
+ subtitle?: string;
9
+ subtitleIcon?: React.ReactNode;
10
+ error?: string;
11
+ valid?: boolean;
12
+ iconLeft?: React.ReactNode;
13
+ iconRight?: React.ReactNode;
14
+ fullWidth?: boolean;
15
+ disabled?: boolean;
16
+ type?: InputType;
17
+ className?: string;
18
+ isRequired?: boolean;
19
+ readOnly?: boolean;
20
+ textArea?: boolean;
21
+ maxLength?: number;
22
+ }
23
+ export {};
@@ -0,0 +1,3 @@
1
+ import { default as React } from 'react';
2
+ import { UploadProps } from './Upload.types';
3
+ export declare const Upload: React.FC<UploadProps>;
@@ -0,0 +1,15 @@
1
+ import { Meta, StoryObj } from '@storybook/react';
2
+ import { Upload } from './Upload';
3
+ declare const meta: Meta<typeof Upload>;
4
+ export default meta;
5
+ type Story = StoryObj<typeof Upload>;
6
+ export declare const DefaultInput: Story;
7
+ export declare const MultipleInput: Story;
8
+ export declare const WithPreview: Story;
9
+ export declare const MultiplePreview: Story;
10
+ export declare const WithAspectRatio16x9: Story;
11
+ export declare const SquareAspectRatio: Story;
12
+ export declare const DocumentUpload: Story;
13
+ export declare const FullFeatured: Story;
14
+ export declare const SmallPreview: Story;
15
+ export declare const LargePreview: Story;
@@ -0,0 +1,21 @@
1
+ export declare const Wrapper: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components/dist/types').Substitute<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {
2
+ variant: "input" | "preview";
3
+ }>> & string;
4
+ export declare const InputContainer: 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 InputWrapper: 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 HiddenInput: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components').FastOmit<import('react').DetailedHTMLProps<import('react').InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>, never>> & string;
7
+ export declare const InputBox: 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 UploadButton: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components').FastOmit<import('react').DetailedHTMLProps<import('react').ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, never>> & string;
9
+ export declare const PreviewBox: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components/dist/types').Substitute<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {
10
+ size: {
11
+ width: number;
12
+ height: number;
13
+ };
14
+ }>> & string;
15
+ export declare const UploadText: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components').FastOmit<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, never>> & string;
16
+ export declare const ErrorMessage: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components').FastOmit<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
17
+ export declare const PreviewContainer: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components').FastOmit<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
18
+ export declare const PreviewWrapper: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components').FastOmit<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
19
+ export declare const PreviewItem: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components').FastOmit<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
20
+ export declare const FileInfo: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components').FastOmit<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
21
+ export declare const RemoveButton: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components').FastOmit<import('react').DetailedHTMLProps<import('react').ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, never>> & string;
@@ -0,0 +1,18 @@
1
+ export type AspectRatio = {
2
+ width: number;
3
+ height: number;
4
+ };
5
+ export type UploadProps = {
6
+ variant?: "input" | "preview";
7
+ maxSize?: number;
8
+ acceptedTypes?: string;
9
+ previewSize?: {
10
+ width: number;
11
+ height: number;
12
+ };
13
+ multiple?: boolean;
14
+ maxFiles?: number;
15
+ aspectRatio?: AspectRatio;
16
+ onUpload?: (files: File[]) => void;
17
+ onRemove?: (fileIndex: number) => void;
18
+ };