@zauru-sdk/components 1.0.35 → 1.0.36
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/CHANGELOG.md +8 -0
- package/dist/Chat/ChatLayout.js +1 -1
- package/dist/DynamicTable/DynamicPrintTable.js +2 -2
- package/dist/DynamicTable/DynamicTable.js +3 -3
- package/dist/DynamicTable/GenericDynamicTable.js +7 -6
- package/dist/Footer/Footer.js +2 -2
- package/dist/Form/Checklist/index.js +1 -1
- package/dist/Form/DynamicBaculoForm/index.js +11 -9
- package/dist/Form/FormLayout/index.js +1 -1
- package/dist/Form/SelectField/index.js +1 -1
- package/dist/NavBar/NavBar.d.ts +1 -1
- package/dist/NavBar/NavBar.js +1 -1
- package/dist/Wizards/StepWizard.js +1 -1
- package/package.json +2 -2
- package/src/Chat/ChatLayout.tsx +1 -1
- package/src/DynamicTable/DynamicPrintTable.tsx +2 -2
- package/src/DynamicTable/DynamicTable.tsx +3 -3
- package/src/DynamicTable/GenericDynamicTable.tsx +7 -6
- package/src/Footer/Footer.tsx +2 -2
- package/src/Form/Checklist/index.tsx +1 -1
- package/src/Form/DynamicBaculoForm/index.tsx +11 -9
- package/src/Form/FormLayout/index.tsx +1 -1
- package/src/Form/SelectField/index.tsx +1 -1
- package/src/NavBar/NavBar.tsx +2 -2
- package/src/Titles/TitleH1.tsx +0 -1
- package/src/Wizards/StepWizard.tsx +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,14 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
+
## [1.0.36](https://github.com/intuitiva/zauru-typescript-sdk/compare/v1.0.35...v1.0.36) (2024-03-25)
|
|
7
|
+
|
|
8
|
+
**Note:** Version bump only for package @zauru-sdk/components
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
|
|
6
14
|
## [1.0.35](https://github.com/intuitiva/zauru-typescript-sdk/compare/v1.0.34...v1.0.35) (2024-03-25)
|
|
7
15
|
|
|
8
16
|
**Note:** Version bump only for package @zauru-sdk/components
|
package/dist/Chat/ChatLayout.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
2
|
import { useRef, useState } from "react";
|
|
3
|
-
import { TextField } from "../Form/TextField";
|
|
3
|
+
import { TextField } from "../Form/TextField/index.js";
|
|
4
4
|
import { Form } from "@remix-run/react";
|
|
5
5
|
import { LoadingInputSkeleton } from "../Skeletons/LoadingInputSkeleton.js";
|
|
6
6
|
import { AttachmentIconSVG, SendMessageIcon, SpinnerSvg, } from "@zauru-sdk/icons";
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
2
|
import React, { useEffect, useCallback, useState } from "react";
|
|
3
|
-
import { TextFieldWithoutValidation } from "../Form/TextField";
|
|
4
|
-
import { SelectFieldWithoutValidation } from "../Form/SelectField";
|
|
3
|
+
import { TextFieldWithoutValidation } from "../Form/TextField/index.js";
|
|
4
|
+
import { SelectFieldWithoutValidation } from "../Form/SelectField/index.js";
|
|
5
5
|
import { useAppSelector } from "@zauru-sdk/redux";
|
|
6
6
|
const errorAnimation = {
|
|
7
7
|
hidden: { opacity: 0, y: -10 },
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { jsxs as _jsxs, Fragment as _Fragment, jsx as _jsx } from "react/jsx-runtime";
|
|
2
2
|
import React, { useEffect, useState } from "react";
|
|
3
|
-
import { TextAreaWithoutValidation } from "../Form/TextArea";
|
|
4
|
-
import { TextFieldWithoutValidation } from "../Form/TextField";
|
|
5
|
-
import { CheckboxWithoutValidation } from "../Form/Checkbox";
|
|
3
|
+
import { TextAreaWithoutValidation } from "../Form/TextArea/index.js";
|
|
4
|
+
import { TextFieldWithoutValidation } from "../Form/TextField/index.js";
|
|
5
|
+
import { CheckboxWithoutValidation } from "../Form/Checkbox/index.js";
|
|
6
6
|
export const DynamicTable = ({ forwardedRef, ...props }, ref) => {
|
|
7
7
|
const [tableData, setTableData] = useState({});
|
|
8
8
|
const { cellInputs, intersectionTitle, className, onChange, defaultValue, margins, } = props;
|
|
@@ -1,13 +1,14 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
2
2
|
import { useEffect, useState } from "react";
|
|
3
|
-
import { SelectFieldWithoutValidation } from "../Form/SelectField";
|
|
4
|
-
import { TextFieldWithoutValidation } from "../Form/TextField";
|
|
5
|
-
import { CheckboxWithoutValidation } from "../Form/Checkbox";
|
|
6
|
-
import { createModal } from "../Modal";
|
|
7
|
-
import { Button } from "../Buttons/
|
|
3
|
+
import { SelectFieldWithoutValidation } from "../Form/SelectField/index.js";
|
|
4
|
+
import { TextFieldWithoutValidation } from "../Form/TextField/index.js";
|
|
5
|
+
import { CheckboxWithoutValidation } from "../Form/Checkbox/index.js";
|
|
6
|
+
import { createModal } from "../Modal/index.js";
|
|
7
|
+
import { Button } from "../Buttons/index.js";
|
|
8
8
|
import { useAppSelector } from "@zauru-sdk/redux";
|
|
9
9
|
import { generateClientUUID } from "@zauru-sdk/common";
|
|
10
|
-
import { LoadingInputSkeleton
|
|
10
|
+
import { LoadingInputSkeleton } from "../Skeletons/index.js";
|
|
11
|
+
import { WithTooltip } from "../WithTooltip/index.js";
|
|
11
12
|
import { TrashSvg } from "@zauru-sdk/icons";
|
|
12
13
|
const GenericDynamicTableErrorComponent = ({ name, formName, }) => {
|
|
13
14
|
const { formValidations } = useAppSelector((state) => state.formValidation);
|
package/dist/Footer/Footer.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
2
|
import { useEffect, useState } from "react";
|
|
3
|
-
import { LoadingInputSkeleton } from "
|
|
4
|
-
import { ConnectionState } from "./../ConnectionState";
|
|
3
|
+
import { LoadingInputSkeleton } from "../Skeletons/index.js";
|
|
4
|
+
import { ConnectionState } from "./../ConnectionState/index.js";
|
|
5
5
|
const COLORS = {
|
|
6
6
|
purple: "bg-purple-500",
|
|
7
7
|
pink: "bg-pink-500",
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
-
import { CheckboxWithoutValidation } from "../Checkbox";
|
|
2
|
+
import { CheckboxWithoutValidation } from "../Checkbox/index.js";
|
|
3
3
|
export const Checklist = ({ items, onChange }) => {
|
|
4
4
|
const handleCheckboxChange = (name, value) => {
|
|
5
5
|
if (onChange) {
|
|
@@ -1,16 +1,18 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
2
|
import { TextField, TextFieldWithoutValidation } from "../TextField";
|
|
3
|
-
import { TripleFieldContainer } from "../FieldContainer/
|
|
4
|
-
import { DoubleFieldContainer } from "../FieldContainer/
|
|
5
|
-
import { YesNo } from "../YesNo";
|
|
6
|
-
import { TextArea } from "../TextArea";
|
|
7
|
-
import { SelectField } from "../SelectField";
|
|
8
|
-
import { FileUploadField } from "../FileUpload";
|
|
9
|
-
import { FormDatePicker } from "../DatePicker";
|
|
10
|
-
import { FormTimePicker } from "../TimePicker";
|
|
11
|
-
import { LineSeparator, StaticAlert, SubContainer } from "./../../index";
|
|
3
|
+
import { TripleFieldContainer } from "../FieldContainer/index.js";
|
|
4
|
+
import { DoubleFieldContainer } from "../FieldContainer/index.js";
|
|
5
|
+
import { YesNo } from "../YesNo/index.js";
|
|
6
|
+
import { TextArea } from "../TextArea/index.js";
|
|
7
|
+
import { SelectField } from "../SelectField/index.js";
|
|
8
|
+
import { FileUploadField } from "../FileUpload/index.js";
|
|
9
|
+
import { FormDatePicker } from "../DatePicker/index.js";
|
|
10
|
+
import { FormTimePicker } from "../TimePicker/index.js";
|
|
12
11
|
import { GenericDynamicTable } from "../../DynamicTable/GenericDynamicTable";
|
|
13
12
|
import { getDepSelectOptions, getMunSelectOptions } from "@zauru-sdk/common";
|
|
13
|
+
import { StaticAlert } from "../../Alerts/index.js";
|
|
14
|
+
import { SubContainer } from "../../Containers/index.js";
|
|
15
|
+
import { LineSeparator } from "../../LineSeparator/index.js";
|
|
14
16
|
export function DynamicBaculoForm(props) {
|
|
15
17
|
const { form, options = { showDescription: false, showTitle: false }, formName = "", namesStr = "", defaultValues = [], showingRules = [], readOnly = false, } = props;
|
|
16
18
|
if (!form) {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
2
|
import { Form } from "@remix-run/react";
|
|
3
|
-
import { ButtonSectionContainer } from "
|
|
3
|
+
import { ButtonSectionContainer } from "../../Containers/index.js";
|
|
4
4
|
export const FormLayout = (props) => {
|
|
5
5
|
const { title, children, buttons, method, formId } = props;
|
|
6
6
|
return (_jsxs(Form, { id: formId, name: formId, method: method ?? "post", children: [title && (_jsx("label", { className: "block text-sm font-medium text-gray-700 mb-3", children: title })), _jsxs("div", { className: "shadow sm:overflow-hidden sm:rounded-md", children: [_jsx("div", { className: "space-y-6 bg-white px-4 py-5 sm:p-6", children: children }), buttons && (_jsx(ButtonSectionContainer, { children: buttons }))] })] }, formId));
|
|
@@ -3,7 +3,7 @@ import { IdeaIconSVG } from "@zauru-sdk/icons";
|
|
|
3
3
|
import { useAppSelector } from "@zauru-sdk/redux";
|
|
4
4
|
import { useEffect, useState } from "react";
|
|
5
5
|
import Select, { components } from "react-select";
|
|
6
|
-
import { LoadingInputSkeleton } from "
|
|
6
|
+
import { LoadingInputSkeleton } from "../../Skeletons/index.js";
|
|
7
7
|
const Input = (props) => (_jsx(components.Input, { ...props, readOnly: props.selectProps.isReadOnly }));
|
|
8
8
|
export const SelectFieldWithoutValidation = (props) => {
|
|
9
9
|
const { id, name, title, defaultValue, defaultValueMulti = [], helpText, hint, options, onChange, onChangeMulti, isClearable = false, error = false, disabled = false, readOnly = false, isMulti = false, loading = false, className = "", onInputChange, } = props;
|
package/dist/NavBar/NavBar.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import type { NavBarProps } from "./NavBar.types";
|
|
1
|
+
import type { NavBarProps } from "./NavBar.types.js";
|
|
2
2
|
export declare const NavBar: ({ title, loggedIn, items, selectedColor, }: NavBarProps) => import("react/jsx-runtime").JSX.Element;
|
package/dist/NavBar/NavBar.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
2
2
|
import { useState } from "react";
|
|
3
3
|
import { DropDownArrowSvgIcon, LogoutDropDownSvgIcon, MenuAlt4Svg, OpcionButtonSvgIcon, } from "@zauru-sdk/icons";
|
|
4
|
-
import { COLORS } from "./NavBar.utils";
|
|
4
|
+
import { COLORS } from "./NavBar.utils.js";
|
|
5
5
|
import { Link } from "@remix-run/react";
|
|
6
6
|
const DropDownLinkButton = ({ text, path, icon, buttonHover, }) => (_jsx(Link, { className: `block px-4 py-3 text-sm text-gray-600 capitalize transition-colors duration-200 transform dark:text-gray-300 ${buttonHover ?? ""} dark:hover:bg-gray-700 dark:hover:text-white`, to: path, prefetch: "none", children: _jsxs("div", { className: "mx-auto pt-2", children: [icon, _jsx("span", { children: text })] }) }));
|
|
7
7
|
const OptionsDropDownButton = ({ color, options, name }) => {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
2
|
import { useState } from "react";
|
|
3
|
-
import { LoadingInputSkeleton } from "
|
|
3
|
+
import { LoadingInputSkeleton } from "../Skeletons/index.js";
|
|
4
4
|
export const StepWizardComponent = ({ steps, showStepName = false, loading = false, }) => {
|
|
5
5
|
const [currentStep, setCurrentStep] = useState(0);
|
|
6
6
|
if (loading) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@zauru-sdk/components",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.36",
|
|
4
4
|
"description": "Componentes reutilizables en las WebApps de Zauru.",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -48,5 +48,5 @@
|
|
|
48
48
|
"engines": {
|
|
49
49
|
"node": ">=18.0.0"
|
|
50
50
|
},
|
|
51
|
-
"gitHead": "
|
|
51
|
+
"gitHead": "235f1b18c73a58658bca1ab4aef2f50d49225fb4"
|
|
52
52
|
}
|
package/src/Chat/ChatLayout.tsx
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React, { useRef, useState } from "react";
|
|
2
|
-
import { TextField } from "../Form/TextField";
|
|
2
|
+
import { TextField } from "../Form/TextField/index.js";
|
|
3
3
|
import { Form } from "@remix-run/react";
|
|
4
4
|
import { FormDocumentType } from "@zauru-sdk/types";
|
|
5
5
|
import { LoadingInputSkeleton } from "../Skeletons/LoadingInputSkeleton.js";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React, { useEffect, useCallback, useState, type ReactNode } from "react";
|
|
2
|
-
import { TextFieldWithoutValidation } from "../Form/TextField";
|
|
3
|
-
import { SelectFieldWithoutValidation } from "../Form/SelectField";
|
|
2
|
+
import { TextFieldWithoutValidation } from "../Form/TextField/index.js";
|
|
3
|
+
import { SelectFieldWithoutValidation } from "../Form/SelectField/index.js";
|
|
4
4
|
import type { SingleValue } from "react-select";
|
|
5
5
|
import { useAppSelector } from "@zauru-sdk/redux";
|
|
6
6
|
import { SelectFieldOption } from "@zauru-sdk/types";
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React, { useEffect, useState } from "react";
|
|
2
|
-
import { TextAreaWithoutValidation } from "../Form/TextArea";
|
|
3
|
-
import { TextFieldWithoutValidation } from "../Form/TextField";
|
|
4
|
-
import { CheckboxWithoutValidation } from "../Form/Checkbox";
|
|
2
|
+
import { TextAreaWithoutValidation } from "../Form/TextArea/index.js";
|
|
3
|
+
import { TextFieldWithoutValidation } from "../Form/TextField/index.js";
|
|
4
|
+
import { CheckboxWithoutValidation } from "../Form/Checkbox/index.js";
|
|
5
5
|
|
|
6
6
|
type Props = {
|
|
7
7
|
cellInputs?: boolean;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import React, { useEffect, useState } from "react";
|
|
2
|
-
import { SelectFieldWithoutValidation } from "../Form/SelectField";
|
|
3
|
-
import { TextFieldWithoutValidation } from "../Form/TextField";
|
|
4
|
-
import { CheckboxWithoutValidation } from "../Form/Checkbox";
|
|
5
|
-
import { createModal } from "../Modal";
|
|
6
|
-
import { Button } from "../Buttons/
|
|
2
|
+
import { SelectFieldWithoutValidation } from "../Form/SelectField/index.js";
|
|
3
|
+
import { TextFieldWithoutValidation } from "../Form/TextField/index.js";
|
|
4
|
+
import { CheckboxWithoutValidation } from "../Form/Checkbox/index.js";
|
|
5
|
+
import { createModal } from "../Modal/index.js";
|
|
6
|
+
import { Button } from "../Buttons/index.js";
|
|
7
7
|
import {
|
|
8
8
|
GenericDynamicTableColumn,
|
|
9
9
|
RowDataType,
|
|
@@ -11,7 +11,8 @@ import {
|
|
|
11
11
|
} from "@zauru-sdk/types";
|
|
12
12
|
import { useAppSelector } from "@zauru-sdk/redux";
|
|
13
13
|
import { generateClientUUID } from "@zauru-sdk/common";
|
|
14
|
-
import { LoadingInputSkeleton
|
|
14
|
+
import { LoadingInputSkeleton } from "../Skeletons/index.js";
|
|
15
|
+
import { WithTooltip } from "../WithTooltip/index.js";
|
|
15
16
|
import { TrashSvg } from "@zauru-sdk/icons";
|
|
16
17
|
|
|
17
18
|
type Props = {
|
package/src/Footer/Footer.tsx
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React, { useEffect, useState } from "react";
|
|
2
|
-
import { LoadingInputSkeleton } from "
|
|
3
|
-
import { ConnectionState } from "./../ConnectionState";
|
|
2
|
+
import { LoadingInputSkeleton } from "../Skeletons/index.js";
|
|
3
|
+
import { ConnectionState } from "./../ConnectionState/index.js";
|
|
4
4
|
|
|
5
5
|
type FooterProps = {
|
|
6
6
|
href: string;
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { TextField, TextFieldWithoutValidation } from "../TextField";
|
|
2
|
-
import { TripleFieldContainer } from "../FieldContainer/
|
|
3
|
-
import { DoubleFieldContainer } from "../FieldContainer/
|
|
4
|
-
import { YesNo } from "../YesNo";
|
|
5
|
-
import { TextArea } from "../TextArea";
|
|
6
|
-
import { SelectField } from "../SelectField";
|
|
7
|
-
import { FileUploadField } from "../FileUpload";
|
|
8
|
-
import { FormDatePicker } from "../DatePicker";
|
|
9
|
-
import { FormTimePicker } from "../TimePicker";
|
|
2
|
+
import { TripleFieldContainer } from "../FieldContainer/index.js";
|
|
3
|
+
import { DoubleFieldContainer } from "../FieldContainer/index.js";
|
|
4
|
+
import { YesNo } from "../YesNo/index.js";
|
|
5
|
+
import { TextArea } from "../TextArea/index.js";
|
|
6
|
+
import { SelectField } from "../SelectField/index.js";
|
|
7
|
+
import { FileUploadField } from "../FileUpload/index.js";
|
|
8
|
+
import { FormDatePicker } from "../DatePicker/index.js";
|
|
9
|
+
import { FormTimePicker } from "../TimePicker/index.js";
|
|
10
10
|
import {
|
|
11
11
|
FormFieldGraphQL,
|
|
12
12
|
FormGraphQL,
|
|
@@ -14,9 +14,11 @@ import {
|
|
|
14
14
|
GenericDynamicTableColumn,
|
|
15
15
|
SelectFieldOption,
|
|
16
16
|
} from "@zauru-sdk/types";
|
|
17
|
-
import { LineSeparator, StaticAlert, SubContainer } from "./../../index";
|
|
18
17
|
import { GenericDynamicTable } from "../../DynamicTable/GenericDynamicTable";
|
|
19
18
|
import { getDepSelectOptions, getMunSelectOptions } from "@zauru-sdk/common";
|
|
19
|
+
import { StaticAlert } from "../../Alerts/index.js";
|
|
20
|
+
import { SubContainer } from "../../Containers/index.js";
|
|
21
|
+
import { LineSeparator } from "../../LineSeparator/index.js";
|
|
20
22
|
|
|
21
23
|
type Props = {
|
|
22
24
|
formName?: string;
|
|
@@ -4,7 +4,7 @@ import { SelectFieldOption } from "@zauru-sdk/types";
|
|
|
4
4
|
import { useEffect, useState } from "react";
|
|
5
5
|
import type { SingleValue, InputActionMeta } from "react-select";
|
|
6
6
|
import Select, { components } from "react-select";
|
|
7
|
-
import { LoadingInputSkeleton } from "
|
|
7
|
+
import { LoadingInputSkeleton } from "../../Skeletons/index.js";
|
|
8
8
|
|
|
9
9
|
type Props = {
|
|
10
10
|
id?: string;
|
package/src/NavBar/NavBar.tsx
CHANGED
|
@@ -5,14 +5,14 @@ import {
|
|
|
5
5
|
MenuAlt4Svg,
|
|
6
6
|
OpcionButtonSvgIcon,
|
|
7
7
|
} from "@zauru-sdk/icons";
|
|
8
|
-
import { COLORS } from "./NavBar.utils";
|
|
8
|
+
import { COLORS } from "./NavBar.utils.js";
|
|
9
9
|
import type {
|
|
10
10
|
ColorInterface,
|
|
11
11
|
DropDownLinkButtonType,
|
|
12
12
|
EntityProps,
|
|
13
13
|
NavBarProps,
|
|
14
14
|
NavItemProps,
|
|
15
|
-
} from "./NavBar.types";
|
|
15
|
+
} from "./NavBar.types.js";
|
|
16
16
|
import { Link } from "@remix-run/react";
|
|
17
17
|
|
|
18
18
|
const DropDownLinkButton = ({
|
package/src/Titles/TitleH1.tsx
CHANGED