Skip to content

Commit

Permalink
(Feat) Build for release
Browse files Browse the repository at this point in the history
  • Loading branch information
Arthur Volokhin authored and Arthur Volokhin committed May 18, 2023
1 parent 7a02e40 commit e82453a
Show file tree
Hide file tree
Showing 14 changed files with 39,017 additions and 28,733 deletions.
67,601 changes: 38,902 additions & 28,699 deletions lib/admiral.es.js

Large diffs are not rendered by default.

113 changes: 87 additions & 26 deletions lib/admiral.umd.js

Large diffs are not rendered by default.

6 changes: 6 additions & 0 deletions lib/admiral/actions/SearchField/index.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
/// <reference types="react" />
interface Props {
className?: string;
}
export declare const SearchField: ({ className }: Props) => JSX.Element;
export {};
1 change: 1 addition & 0 deletions lib/admiral/actions/index.d.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
export * from './BackButton';
export * from './CreateButton';
export * from './FilterButton';
export * from './SearchField';
3 changes: 2 additions & 1 deletion lib/admiral/admin/index.d.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import '../assets/global.css';
import React, { ComponentType } from 'react';
import React, { ComponentType, ReactNode } from 'react';
import { LogoType } from '../ui/Layout/LayoutHeader';
import { DataProvider } from '../dataProvider';
import type { AuthProvider } from '../auth/interfaces';
Expand All @@ -8,6 +8,7 @@ import { CRUDLocale } from '../crud/interfaces';
import { OAuthProvidersEnum } from '../auth/interfaces';
export declare type AdminProps = {
menu: ComponentType;
menuPopupExtraComponents: ReactNode;
logo?: LogoType;
loginLogo?: LogoType;
asideContent?: React.ReactNode;
Expand Down
3 changes: 2 additions & 1 deletion lib/admiral/config/ConfigContext.d.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
import { LogoType, OAuthProvidersEnum } from '../../admiral';
import React from 'react';
import React, { ReactNode } from 'react';
declare type ConfigContextValue = {
logo?: LogoType;
loginLogo?: LogoType;
asideContent?: React.ReactNode;
oauthProviders?: OAuthProvidersEnum[];
menuPopupExtraComponents?: ReactNode;
};
export declare const ConfigContext: React.Context<ConfigContextValue>;
export declare const ConfigContextProvider: React.FC<{
Expand Down
1 change: 1 addition & 0 deletions lib/admiral/crud/IndexPageContext/interfaces.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ export declare type CrudIndexUrlState = {
page_size: string;
filter: Record<string, any>;
sort: Record<string, SortOrder>;
search: string;
} & {
[x: string]: any;
};
Expand Down
1 change: 1 addition & 0 deletions lib/admiral/dataProvider/interfaces.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@ export interface GetListParams {
pagination: PaginationPayload;
sort: SortPayload;
filter: any;
search: string;
}
export interface GetListResult<RecordType extends IRecord = IRecord> {
items: RecordType[];
Expand Down
4 changes: 3 additions & 1 deletion lib/admiral/dataTable/DataTable.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,14 +13,16 @@ export declare type DataTableProps<RecordType> = {
};
}>;
config?: DataTableConfig<RecordType>;
autoupdateTime?: number;
};
export interface DataTableConfig<RecordType> extends Pick<TableProps<RecordType>, 'dndRows' | 'showSorterTooltip' | 'bordered' | 'size' | 'title' | 'footer'> {
rowSelection?: DataTableRowSelectionConfig<RecordType>;
autoupdateTime?: number;
}
export declare type DataTableRowSelectionConfig<RecordType> = {
render: (selectedRowKeys: Key[], selectedRows: RecordType[]) => React.ReactNode;
onSelectionChange?: (selectedRowKeys: Key[], selectedRows: RecordType[]) => void;
};
export declare function DataTable<RecordType extends {
id: number | string;
}>({ resource, columns, locale, config, }: DataTableProps<RecordType>): JSX.Element;
}>({ resource, columns, locale, config, autoupdateTime, }: DataTableProps<RecordType>): JSX.Element;
1 change: 1 addition & 0 deletions lib/admiral/form/fields/SlugInput.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ import { InputComponentWithName } from '../interfaces';
export interface SlugInputProps extends InputProps, FormItemProps {
name: string;
from: string;
slugLang?: string;
options?: SlygifyOptions;
}
export declare type SlygifyOptions = {
Expand Down
2 changes: 1 addition & 1 deletion lib/admiral/ui/Input/interfaces.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import React from 'react';
export declare type InputSizeType = 'XS' | 'S' | 'M' | 'L';
export interface InputProps extends Omit<React.InputHTMLAttributes<HTMLInputElement>, 'size' | 'type'> {
size?: InputSizeType;
type?: 'text' | 'tel' | 'password';
type?: 'text' | 'tel' | 'password' | 'search';
borderless?: boolean;
alert?: boolean;
suffix?: React.ReactNode;
Expand Down
8 changes: 5 additions & 3 deletions lib/admiral/ui/Layout/LayoutFooter/index.d.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
import React from 'react';
import React, { ReactNode } from 'react';
import { UserIdentity } from '../../../auth/interfaces';
declare const LayoutFooter: React.FC<{
interface Props {
user: UserIdentity | null;
}>;
menuPopupExtraComponents: ReactNode;
}
declare const LayoutFooter: React.FC<Props>;
export declare function Logout(): JSX.Element;
export default LayoutFooter;
4 changes: 4 additions & 0 deletions lib/admiral/ui/Upload/interfaces.d.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import React from 'react';
import { RcFile, UploadRequestOption as RcCustomRequestOptions, UploadProps as RcUploadProps } from 'rc-upload/lib/interface';
import { OnDragEndResponder } from 'react-beautiful-dnd';
export type { RcFile };
export declare type UploadFileStatus = 'error' | 'removed' | 'uploading';
export declare type UploadFileError = {
Expand Down Expand Up @@ -69,6 +70,7 @@ export interface UploadProps<T = any> extends Pick<RcUploadProps, 'capture'> {
itemRender?: ItemRender<T>;
/** Config max count of `fileList`. Will replace current one when `maxCount` is 1 */
maxCount?: number;
isDraggable?: boolean;
}
export interface UploadState<T = any> {
fileList: UploadFile[];
Expand All @@ -80,6 +82,7 @@ export interface UploadListProps<T = any> {
onRemove?: (file: UploadFile) => void | boolean;
onPreview?: (file: UploadFile) => void | boolean;
onDownload?: (file: UploadFile) => void;
onDragEnd?: OnDragEndResponder;
items?: Array<UploadFile>;
showRemoveIcon?: boolean;
showPreviewIcon?: boolean;
Expand All @@ -89,6 +92,7 @@ export interface UploadListProps<T = any> {
itemRender?: ItemRender<T>;
previewFile?: PreviewFileHandler;
appendButton?: React.ReactNode;
isDraggable?: boolean;
}
export interface ListItemProps {
locale: UploadLocale;
Expand Down
2 changes: 1 addition & 1 deletion lib/style.css

Large diffs are not rendered by default.

0 comments on commit e82453a

Please sign in to comment.