progress
This commit is contained in:
parent
e005a42254
commit
e155b4a2a1
26 changed files with 468 additions and 36 deletions
|
@ -54,7 +54,7 @@ export const ArrayExtensions = () => {
|
|||
if ([].repeat === undefined) {
|
||||
// eslint-disable-next-line no-extend-native
|
||||
Array.prototype.repeat = function (quantity) {
|
||||
return Array(quantity).fill(this[0]);
|
||||
return Array(quantity).fill(this).flat(1);
|
||||
};
|
||||
}
|
||||
};
|
||||
|
|
3
ui/src/core/model/style.ts
Normal file
3
ui/src/core/model/style.ts
Normal file
|
@ -0,0 +1,3 @@
|
|||
export interface IStyle{
|
||||
style?: React.CSSProperties;
|
||||
}
|
|
@ -1,12 +1,12 @@
|
|||
import * as React from "react";
|
||||
import { CoreText, CoreTextType } from "../text/text";
|
||||
import { IStyle } from "../../model/style";
|
||||
|
||||
export interface IButtonProps {
|
||||
export interface IButtonProps extends IStyle {
|
||||
block?: boolean;
|
||||
filled?: boolean;
|
||||
text?: string;
|
||||
onClick?: any;
|
||||
style?: React.CSSProperties;
|
||||
}
|
||||
|
||||
export function CoreButton(props: IButtonProps) {
|
||||
|
|
|
@ -1,9 +1,9 @@
|
|||
import * as React from "react";
|
||||
import { Result } from "../../helper/result";
|
||||
import { IStyle } from "../../model/style";
|
||||
|
||||
export interface IIconsProps {
|
||||
export interface IIconsProps extends IStyle {
|
||||
type: string;
|
||||
style?: React.CSSProperties;
|
||||
onClick?: Function;
|
||||
}
|
||||
|
||||
|
|
|
@ -1,11 +1,11 @@
|
|||
import * as React from "react";
|
||||
import { CoreText, CoreTextType } from "../text/text";
|
||||
import { IStyle } from "../../model/style";
|
||||
|
||||
interface IInputProps {
|
||||
interface IInputProps extends IStyle {
|
||||
label: string;
|
||||
value?: string;
|
||||
onChange?: (value: string) => void;
|
||||
style?: React.CSSProperties;
|
||||
validation?: (value: string) => boolean;
|
||||
error?: string;
|
||||
}
|
||||
|
|
|
@ -1,13 +1,13 @@
|
|||
import * as React from "react";
|
||||
import { Typography } from "antd";
|
||||
import { useNavigate } from "react-router-dom";
|
||||
import { IStyle } from "../../model/style";
|
||||
|
||||
const { Link } = Typography;
|
||||
|
||||
export interface ILinkTypography {
|
||||
export interface ILinkTypography extends IStyle {
|
||||
path: string;
|
||||
text: string;
|
||||
style?: React.CSSProperties;
|
||||
}
|
||||
|
||||
export const LinkTypography: React.FunctionComponent<ILinkTypography> = (
|
||||
|
|
|
@ -1,12 +1,12 @@
|
|||
import React from "react";
|
||||
import { CoreText, CoreTextType } from "../text/text";
|
||||
import { IStyle } from "../../model/style";
|
||||
|
||||
interface ISelectCoreProps {
|
||||
interface ISelectCoreProps extends IStyle {
|
||||
items: string[];
|
||||
value: string;
|
||||
label: string;
|
||||
onChange: (value: string) => void;
|
||||
style?: React.CSSProperties;
|
||||
}
|
||||
export const SelectCore = (props: ISelectCoreProps) => {
|
||||
const ref = React.useRef<HTMLDivElement>(null);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue