Browse Source

Auto COMMIT for build : 139

 commit by: ayoub <hassani.ayoub@gmail.com>

 with message : update CI
ayoub 1 year ago
parent
commit
99fe089f52

+ 15 - 0
README.md

@@ -0,0 +1,15 @@
+# @d3v4pp/ui
+A light react components library with a lot of components, fun to use
+
+
+## Install
+### current version
+```
+npm install --save @d3v4pp/ui
+```
+### dev version 
+```
+npm install --save git+https://cvs.d3v4pp.fr/D3V4PP/ui.git
+```
+## Documentation & Examples
+[Documentation & Examples](https://ui.d3v4pp.fr)

BIN
assets/SweetIcons-Regular.eot


BIN
assets/SweetIcons-Regular.ttf


BIN
assets/SweetIcons-Regular.woff


BIN
assets/SweetIcons-Regular.woff2


+ 6 - 0
cmps/badge/Badge.d.ts

@@ -0,0 +1,6 @@
+import * as React from "react";
+export interface BadgeProps extends React.HTMLAttributes<HTMLSpanElement> {
+}
+export declare class Badge extends React.Component<BadgeProps> {
+    render(): JSX.Element;
+}

+ 12 - 0
cmps/button/Button.d.ts

@@ -0,0 +1,12 @@
+import * as React from 'react';
+export interface ButtonProps extends React.AnchorHTMLAttributes<HTMLAnchorElement> {
+}
+export declare class Button extends React.Component<ButtonProps> {
+    el: HTMLAnchorElement | null;
+    constructor(props: ButtonProps);
+    /**
+     * Initialisation of the wave effect after the component did mount
+     */
+    componentDidMount(): void;
+    render(): JSX.Element;
+}

+ 18 - 0
cmps/button/Waves.d.ts

@@ -0,0 +1,18 @@
+export default Waves;
+declare class Waves {
+    constructor(cmp: any, options: any);
+    el: any;
+    options: any;
+    showEffect(e: any): false | undefined;
+    ripple: HTMLDivElement | undefined;
+    hideEffect(e: any): void;
+    wrapInput(): void;
+    triggerEffect(e: any): void;
+    isWindow(obj: any): boolean;
+    getWindow(elem: any): any;
+    offset(): {
+        top: number;
+        left: number;
+    };
+    convertStyle(obj: any): string;
+}

+ 21 - 0
cmps/card/Card.d.ts

@@ -0,0 +1,21 @@
+import * as React from "react";
+export interface CardProps extends React.ButtonHTMLAttributes<HTMLDivElement> {
+}
+export declare class Card extends React.Component<CardProps> {
+    render(): JSX.Element;
+}
+export interface CardContentProps extends React.ButtonHTMLAttributes<HTMLDivElement> {
+}
+export declare class CardContent extends React.Component<CardContentProps> {
+    render(): JSX.Element;
+}
+export interface CardTitleProps extends React.ButtonHTMLAttributes<HTMLSpanElement> {
+}
+export declare class CardTitle extends React.Component<CardTitleProps> {
+    render(): JSX.Element;
+}
+export interface CardActionProps extends React.ButtonHTMLAttributes<HTMLDivElement> {
+}
+export declare class CardAction extends React.Component<CardActionProps> {
+    render(): JSX.Element;
+}

+ 7 - 0
cmps/chip/Chip.d.ts

@@ -0,0 +1,7 @@
+import * as React from 'react';
+export interface DividerProps extends React.HTMLProps<HTMLDivElement> {
+}
+export declare class Chip extends React.Component<DividerProps> {
+    render(): JSX.Element;
+}
+export default Chip;

+ 27 - 0
cmps/collapsible/Collapsible.d.ts

@@ -0,0 +1,27 @@
+import * as React from "react";
+export interface CollapsibleProps extends React.HTMLProps<HTMLUListElement> {
+}
+export declare class Collapsible extends React.Component<CollapsibleProps> {
+    render(): JSX.Element;
+}
+export interface CollapsBodyProps extends React.HTMLProps<HTMLDivElement> {
+}
+export declare class CollapsBody extends React.Component<CollapsBodyProps> {
+    el: HTMLDivElement | null;
+    render(): JSX.Element;
+}
+export interface CollapsTriggerProps extends React.HTMLProps<HTMLDivElement> {
+}
+export declare class CollapsTrigger extends React.Component<CollapsTriggerProps> {
+    state: {
+        isOpen: boolean;
+    };
+    el: HTMLDivElement | null;
+    componentDidMount(): void;
+    showHideBody(e: React.MouseEvent<HTMLDivElement>): void;
+    collapse(e: React.MouseEvent<HTMLDivElement>): void;
+    findCollapsible(): HTMLUListElement;
+    expand(e: React.MouseEvent<HTMLDivElement>): void;
+    isOpen(): boolean;
+    render(): JSX.Element;
+}

+ 13 - 0
cmps/collections/Collection.d.ts

@@ -0,0 +1,13 @@
+import * as React from "react";
+export interface CollectionProps extends React.HTMLProps<HTMLUListElement> {
+}
+export declare class Collection extends React.Component<CollectionProps> {
+    private el;
+    render(): JSX.Element;
+}
+export interface CollectionItemProps extends React.HTMLProps<HTMLLIElement> {
+}
+export declare class CollectionItem extends React.Component<CollectionItemProps> {
+    private el;
+    render(): JSX.Element;
+}

+ 41 - 0
cmps/forms/Field.d.ts

@@ -0,0 +1,41 @@
+import * as React from 'react';
+export interface FieldProps extends React.HTMLProps<HTMLInputElement> {
+    vtype?: string;
+    vtypeMsg?: string;
+    onEnterKey?: Function;
+}
+export interface FieldRef extends HTMLInputElement {
+    isValid: () => Boolean;
+}
+export declare class Field extends React.Component<FieldProps> {
+    id: string;
+    el: FieldRef | null | undefined;
+    label: HTMLLabelElement | null | undefined;
+    state: {
+        labelClassName: string;
+        focusCount: number;
+        errmsg: string;
+    };
+    constructor(props: FieldProps);
+    getDefaults(): {
+        placeholder: string;
+        id: number;
+        className: string;
+        label: string;
+        type: string;
+        icon: string;
+    };
+    getValue(): string | null | undefined;
+    setValue(val: string): void;
+    isValid(): Boolean;
+    onBlur(e: React.FocusEvent<HTMLInputElement>): void;
+    onFocus(e: React.FocusEvent<HTMLInputElement>): void;
+    validate(blure?: boolean): Boolean;
+    makeInValid(): void;
+    makeValid(): void;
+    componentDidMount(): void;
+    onKeyUp(e?: React.KeyboardEvent<HTMLInputElement>): void;
+    uuidv4(): any;
+    getErrorView(): JSX.Element | undefined;
+    render(): JSX.Element;
+}

File diff suppressed because it is too large
+ 24 - 0
cmps/forms/Textarea.d.ts


+ 6 - 0
cmps/forms/line-height.d.ts

@@ -0,0 +1,6 @@
+/**
+ * Calculate the `line-height` of a given node
+ * @param {HTMLElement} node Element to calculate line height of. Must be in the DOM.
+ * @returns {Number} `line-height` of the element in pixels
+ */
+export default function lineHeight(node: HTMLElement): number;

+ 0 - 0
cmps/forms/rex.d.ts


+ 6 - 0
cmps/icons/Icon.d.ts

@@ -0,0 +1,6 @@
+import * as React from 'react';
+export interface IconProps extends React.HTMLProps<HTMLSpanElement> {
+}
+export declare class Icon extends React.Component<IconProps> {
+    render(): JSX.Element;
+}

+ 37 - 0
cmps/layouts/Layouts.d.ts

@@ -0,0 +1,37 @@
+import * as React from 'react';
+export interface ColProps extends React.HTMLProps<HTMLDivElement> {
+}
+export declare class Col extends React.Component<ColProps> {
+    el: HTMLDivElement | null;
+    render(): JSX.Element;
+}
+export interface RowProps extends React.HTMLProps<HTMLDivElement> {
+}
+export declare class Row extends React.Component<RowProps> {
+    el: HTMLDivElement | null;
+    render(): JSX.Element;
+}
+export interface ParallaxProps extends React.HTMLProps<HTMLImageElement> {
+}
+export declare class Parallax extends React.Component<ParallaxProps> {
+    render(): JSX.Element;
+}
+export interface DividerProps extends React.HTMLProps<HTMLDivElement> {
+}
+export declare class Divider extends React.Component<DividerProps> {
+    render(): JSX.Element;
+}
+export interface OverlayProps extends React.HTMLProps<HTMLDivElement> {
+}
+export declare class Overlay extends React.Component<OverlayProps> {
+    state: {
+        visible: boolean;
+    };
+    el: HTMLDivElement | null;
+    show(): void;
+    open(): void;
+    isVisible(): boolean;
+    hide(): void;
+    close(): void;
+    render(): JSX.Element | null;
+}

+ 28 - 0
cmps/modal/Modal.d.ts

@@ -0,0 +1,28 @@
+import * as React from 'react';
+export interface ModalProps extends React.HTMLProps<HTMLDivElement> {
+}
+export declare class Modal extends React.Component<ModalProps> {
+    state: {
+        isOpen: boolean;
+    };
+    open(): void;
+    close(): void;
+    show(): void;
+    hide(): void;
+    render(): JSX.Element | null;
+}
+export interface ModalContentProps extends React.HTMLProps<HTMLDivElement> {
+}
+export declare class ModalContent extends React.Component<ModalContentProps> {
+    render(): JSX.Element;
+}
+export interface ModalFooterProps extends React.HTMLProps<HTMLDivElement> {
+}
+export declare class ModalFooter extends React.Component<ModalFooterProps> {
+    render(): JSX.Element;
+}
+export interface ModalHeaderProps extends React.HTMLProps<HTMLDivElement> {
+}
+export declare class ModalHeader extends React.Component<ModalHeaderProps> {
+    render(): JSX.Element;
+}

+ 21 - 0
cmps/navigation/NavBar.d.ts

@@ -0,0 +1,21 @@
+import * as React from 'react';
+export interface NavBarProps extends React.HTMLProps<HTMLDivElement> {
+}
+export declare class NavBar extends React.Component<NavBarProps> {
+    render(): JSX.Element;
+}
+export interface NavBarGroupProps extends React.HTMLProps<HTMLUListElement> {
+}
+export declare class NavBarGroup extends React.Component<NavBarGroupProps> {
+    render(): JSX.Element;
+}
+export interface NavBarItemProps extends React.HTMLProps<HTMLLIElement> {
+}
+export declare class NavBarItem extends React.Component<NavBarItemProps> {
+    render(): JSX.Element;
+}
+export interface NavBarBrandProps extends React.HTMLProps<HTMLAnchorElement> {
+}
+export declare class NavBarBrand extends React.Component<NavBarBrandProps> {
+    render(): JSX.Element;
+}

+ 15 - 0
cmps/navigation/Navigation.d.ts

@@ -0,0 +1,15 @@
+import * as React from "react";
+export interface NavigationRoutes {
+    element: any;
+}
+export interface NavigationProps {
+    logo: string;
+    routes: Array<NavigationRoutes>;
+}
+export declare class Navigation extends React.Component<NavigationProps> {
+    private navbar;
+    private sidenav;
+    constructor(props: NavigationProps);
+    componentDidMount(): void;
+    render(): JSX.Element;
+}

+ 26 - 0
cmps/navigation/SideNav.d.ts

@@ -0,0 +1,26 @@
+import * as React from 'react';
+export interface SideNavProps extends React.HTMLProps<HTMLUListElement> {
+}
+export declare class SideNav extends React.Component<SideNavProps> {
+    state: {
+        open: boolean;
+    };
+    open(): void;
+    toggle(): void;
+    hide(): void;
+    render(): JSX.Element;
+}
+export interface SideNavUserProps extends React.HTMLProps<HTMLLIElement> {
+    readonly src: string;
+    readonly bg_src: string;
+    readonly username: string;
+    readonly email: string;
+}
+export declare class SideNavUser extends React.Component<SideNavUserProps> {
+    render(): JSX.Element;
+}
+export interface SideNavElProps extends React.HTMLProps<HTMLLIElement> {
+}
+export declare class SideNavEl extends React.Component<SideNavElProps> {
+    render(): JSX.Element;
+}

+ 13 - 0
cmps/progress/Progress.d.ts

@@ -0,0 +1,13 @@
+import * as React from 'react';
+export interface ProgressProps extends React.HTMLProps<HTMLDivElement> {
+}
+export declare class Progress extends React.Component<ProgressProps> {
+    render(): JSX.Element;
+}
+export interface PreloaderProps extends React.HTMLAttributes<HTMLDivElement> {
+    readonly size?: string;
+    readonly color?: string;
+}
+export declare class Preloader extends React.Component<PreloaderProps> {
+    render(): JSX.Element;
+}

+ 18 - 0
index.d.ts

@@ -0,0 +1,18 @@
+import "./sass/d3v4pp.scss";
+export { TextareaAutosize as Textarea } from "./cmps/forms/Textarea";
+export { Field, FieldRef, FieldProps } from "./cmps/forms/Field";
+export { Collection, CollectionProps, CollectionItemProps, CollectionItem } from "./cmps/collections/Collection";
+export { Button } from "./cmps/button/Button";
+export { Badge } from "./cmps/badge/Badge";
+export { Chip } from "./cmps/chip/Chip";
+export { Icon } from "./cmps/icons/Icon";
+export { Row, Col, Overlay, Divider, Parallax } from "./cmps/layouts/Layouts";
+export { CollapsTrigger, Collapsible, CollapsBody } from "./cmps/collapsible/Collapsible";
+export { Card, CardContent, CardTitle, CardAction } from "./cmps/card/Card";
+export { NavBar, NavBarGroup, NavBarItem, NavBarBrand } from "./cmps/navigation/NavBar";
+export { Navigation } from "./cmps/navigation/Navigation";
+export { SideNav, SideNavEl, SideNavUser } from "./cmps/navigation/SideNav";
+export { Progress, Preloader } from "./cmps/progress/Progress";
+export { Modal, ModalContent, ModalFooter, ModalHeader } from "./cmps/modal/Modal";
+export * as Router from "react-router-dom";
+export { Login, LoginProps } from "./ux";

File diff suppressed because it is too large
+ 3765 - 0
index.js


+ 40 - 0
package.json

@@ -0,0 +1,40 @@
+{
+    "name": "@d3v4pp/ui",
+    "version": "0.0.2",
+    "description": "a set of react ui components",
+    "main": "index.js",
+    "repository": {
+        "type": "git",
+        "url": "https://cvs.d3v4pp.fr/D3V4PP/ui.git"
+    },
+    "author": {
+        "name": "Ayoub Hassani <D3v4pp>",
+        "email": "ayoub@d3v4pp.fr",
+        "url": "https://d3v4pp.fr/"
+    },
+    "funding": "https://paypal.me/SupportTheDoc",
+    "homepage": "https://cvs.d3v4pp.fr/D3V4PP/ui/src/master/README.md",
+    "bugs": {
+        "url": "https://cvs.d3v4pp.fr/D3V4PP/ui/issues",
+        "email": "ayoub@d3v4pp.fr"
+    },
+    "license": "d3v4pp",
+    "keywords": [
+        "react",
+        "react-component"
+    ],
+    "peerDependencies": {
+        "react": ">=16.0.0",
+        "react-dom": ">=16.0.0"
+    },
+    "dependencies": {
+        "@emotion/react": "^11.10.0",
+        "autosize": "^4.0.2",
+        "computed-style": "^0.3.0",
+        "memoize-one": "^6.0.0",
+        "prop-types": "^15.8.1",
+        "react": "^17.0.2",
+        "react-dom": "^17.0.2",
+        "react-router-dom": "^6.3.0"
+    }
+}

+ 21 - 0
ux/auth/Login.d.ts

@@ -0,0 +1,21 @@
+import * as React from 'react';
+import { EventHandler } from "react";
+export interface LoginProps {
+    checkUrl?: string;
+    loginUrl?: string;
+    className?: string;
+    onLoginError?: EventHandler<any>;
+    onLogin?: EventHandler<any>;
+}
+export declare class Login extends React.Component<LoginProps> {
+    el: HTMLDivElement | null;
+    state: any;
+    private emailF;
+    private passwordF;
+    constructor(props: LoginProps);
+    next(): void;
+    login(): void;
+    getLoginView(): JSX.Element | null;
+    getPasswordView(): JSX.Element | null;
+    render(): JSX.Element;
+}

+ 1 - 0
ux/index.d.ts

@@ -0,0 +1 @@
+export { Login, LoginProps } from "./auth/Login";

Some files were not shown because too many files changed in this diff