@dashadmin/dash-components 1.3.73 → 1.3.74-srcfree.2
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/dist/components/AuditLog/AuditLog.d.ts +27 -0
- package/dist/components/AutoCompleteArrayInput/AutoCompleteCheckBoxInput.d.ts +22 -0
- package/dist/components/AutoCompleteArrayInput/AutocompleteCheckBoxArrayInput.d.ts +7 -0
- package/dist/components/AutoCompleteArrayInputAutoSearch/AutoCompleteCheckBoxInput.d.ts +22 -0
- package/dist/components/AutoCompleteArrayInputAutoSearch/AutocompleteCheckBoxArrayInput.d.ts +7 -0
- package/dist/components/Json/Json.d.ts +5 -0
- package/dist/components/JsonColorSelector/JsonColorSelector.d.ts +5 -0
- package/dist/components/JsonColorSelector/JsonColorSelectorEnhanced.d.ts +4 -0
- package/dist/components/JsonColorSelector/JsonCssVarValues.d.ts +5 -0
- package/dist/components/JsonColorSelector/components/BasicColorSelector.d.ts +9 -0
- package/dist/components/JsonColorSelector/components/ColorEditDialog.d.ts +12 -0
- package/dist/components/JsonColorSelector/components/ColorPaletteItem.d.ts +7 -0
- package/dist/components/JsonColorSelector/components/ImageColorExtractor.d.ts +9 -0
- package/dist/components/JsonColorSelector/helpers/functions.d.ts +11 -0
- package/dist/components/JsonColorSelector/helpers/paletteDerivation.d.ts +37 -0
- package/{src/components/JsonColorSelector/interfaces/interfaces.tsx → dist/components/JsonColorSelector/interfaces/interfaces.d.ts} +6 -8
- package/dist/components/JsonColorSelector/useAsyncColorThief.d.ts +11 -0
- package/dist/components/ListActive/ListActive.d.ts +10 -0
- package/dist/components/ListActive/ListBoolean.d.ts +10 -0
- package/dist/components/NotificationPreferences/NotificationPreferences.d.ts +6 -0
- package/dist/components/SearchableSelects/RASearchableSelect.d.ts +25 -0
- package/dist/components/SearchableSelects/RASearchableSelectCheckboxes.d.ts +35 -0
- package/dist/components/SearchableSelects/RASearchableSelectChips.d.ts +33 -0
- package/dist/components/SearchableSelects/RASearchableSelectChipsRecordContext.d.ts +30 -0
- package/dist/components/SearchableSelects/SearchableSelect.d.ts +25 -0
- package/dist/components/SearchableSelects/SearchableSelectCheckboxes.d.ts +29 -0
- package/dist/components/SortableDataGrid/SortableDataGrid.d.ts +7 -0
- package/dist/components/SortableDataGrid/SortableDataGridBody.d.ts +7 -0
- package/dist/components/SortableDataGrid/SortableDataGridHeader.d.ts +6 -0
- package/dist/components/SortableDataGrid/SortableDataGridRow.d.ts +5 -0
- package/dist/components/Upload/SingleImageUploader.d.ts +8 -0
- package/dist/components/custom/PackageCopyMethod.d.ts +15 -0
- package/dist/components/custom/PackageRadioButtonGroup.d.ts +8 -0
- package/dist/components/dialog/Basic.d.ts +2 -0
- package/dist/components/dialog/Correct.d.ts +2 -0
- package/dist/components/dialog/Error.d.ts +2 -0
- package/dist/components/dialog/Info.d.ts +2 -0
- package/dist/components/dialog/InfoV2.d.ts +2 -0
- package/dist/components/dialog/NotFound.d.ts +2 -0
- package/dist/components/dialog/QuickSearch.d.ts +6 -0
- package/dist/components/notifications/NotificationsCenter.d.ts +109 -0
- package/dist/components/notifications/index.d.ts +2 -0
- package/dist/components/tables/PaginationComponent.d.ts +4 -0
- package/dist/components/theme/AppLoadingFallback.d.ts +6 -0
- package/dist/components/theme/ErrorBoundary.d.ts +19 -0
- package/dist/components/theme/InitialLoader.d.ts +3 -0
- package/dist/components/theme/NotFound.d.ts +13 -0
- package/dist/components/theme/NotResults.d.ts +7 -0
- package/dist/hooks/useDraggable.d.ts +1 -0
- package/dist/hooks/useNotifications.d.ts +2 -0
- package/dist/hooks/useQuickSearch.d.ts +6 -0
- package/{src/index.tsx → dist/index.d.ts} +10 -58
- package/dist/utils/setNativeValue.d.ts +2 -0
- package/package.json +24 -21
- package/src/components/AuditLog/AuditLog.tsx +0 -490
- package/src/components/AutoCompleteArrayInput/AutoCompleteCheckBoxInput.tsx +0 -917
- package/src/components/AutoCompleteArrayInput/AutocompleteCheckBoxArrayInput.tsx +0 -39
- package/src/components/AutoCompleteArrayInputAutoSearch/AutoCompleteCheckBoxInput.tsx +0 -916
- package/src/components/AutoCompleteArrayInputAutoSearch/AutocompleteCheckBoxArrayAutoSearch.tsx.wip +0 -42
- package/src/components/AutoCompleteArrayInputAutoSearch/AutocompleteCheckBoxArrayInput.tsx +0 -44
- package/src/components/Json/Json.tsx +0 -312
- package/src/components/JsonColorSelector/JsonColorSelector.tsx +0 -1443
- package/src/components/JsonColorSelector/JsonColorSelector.tsx.bkup +0 -746
- package/src/components/JsonColorSelector/JsonColorSelectorEnhanced.tsx +0 -1135
- package/src/components/JsonColorSelector/JsonCssVarValues.tsx +0 -867
- package/src/components/JsonColorSelector/components/BasicColorSelector.tsx +0 -333
- package/src/components/JsonColorSelector/components/ColorEditDialog.tsx +0 -495
- package/src/components/JsonColorSelector/components/ColorPaletteItem.tsx +0 -80
- package/src/components/JsonColorSelector/components/ImageColorExtractor.tsx +0 -420
- package/src/components/JsonColorSelector/helpers/functions.tsx +0 -123
- package/src/components/JsonColorSelector/helpers/paletteDerivation.ts +0 -367
- package/src/components/JsonColorSelector/useAsyncColorThief.tsx +0 -97
- package/src/components/ListActive/ListActive.tsx +0 -106
- package/src/components/ListActive/ListBoolean.tsx +0 -96
- package/src/components/NotificationPreferences/NotificationPreferences.tsx +0 -480
- package/src/components/SearchableSelects/RASearchableSelect.tsx +0 -303
- package/src/components/SearchableSelects/RASearchableSelectCheckboxes.tsx +0 -617
- package/src/components/SearchableSelects/RASearchableSelectChips.tsx +0 -561
- package/src/components/SearchableSelects/RASearchableSelectChipsRecordContext.tsx +0 -366
- package/src/components/SearchableSelects/SearchableSelect.tsx +0 -323
- package/src/components/SearchableSelects/SearchableSelectCheckboxes.tsx +0 -358
- package/src/components/SortableDataGrid/README.md +0 -1
- package/src/components/SortableDataGrid/SortableDataGrid.tsx +0 -56
- package/src/components/SortableDataGrid/SortableDataGridBody.tsx +0 -175
- package/src/components/SortableDataGrid/SortableDataGridHeader.tsx +0 -171
- package/src/components/SortableDataGrid/SortableDataGridRow.tsx +0 -247
- package/src/components/Upload/SingleImageUploader.tsx +0 -55
- package/src/components/custom/PackageCopyMethod.tsx +0 -109
- package/src/components/custom/PackageRadioButtonGroup.tsx +0 -49
- package/src/components/dialog/Basic.tsx +0 -11
- package/src/components/dialog/Correct.tsx +0 -16
- package/src/components/dialog/Error.tsx +0 -15
- package/src/components/dialog/Info.tsx +0 -15
- package/src/components/dialog/InfoV2.tsx +0 -35
- package/src/components/dialog/NotFound.tsx +0 -18
- package/src/components/dialog/QuickSearch.tsx +0 -115
- package/src/components/notifications/NotificationsCenter.tsx +0 -743
- package/src/components/notifications/index.ts +0 -42
- package/src/components/tables/PaginationComponent.tsx +0 -17
- package/src/components/theme/AppLoadingFallback.tsx +0 -42
- package/src/components/theme/ErrorBoundary.tsx +0 -57
- package/src/components/theme/InitialLoader.tsx +0 -16
- package/src/components/theme/NotFound.tsx +0 -124
- package/src/components/theme/NotResults.tsx +0 -56
- package/src/hooks/useDraggable.ts +0 -11
- package/src/hooks/useNotifications.ts +0 -14
- package/src/hooks/useQuickSearch.tsx +0 -29
- package/src/styles/index.less +0 -0
- package/src/utils/setNativeValue.tsx +0 -23
- /package/{src/components/AuditLog/index.ts → dist/components/AuditLog/index.d.ts} +0 -0
- /package/{src/components/NotificationPreferences/index.tsx → dist/components/NotificationPreferences/index.d.ts} +0 -0
|
@@ -1,35 +0,0 @@
|
|
|
1
|
-
import Button from '@mui/material/Button';
|
|
2
|
-
|
|
3
|
-
const DialogInfoV2 = () => {
|
|
4
|
-
return (
|
|
5
|
-
<>
|
|
6
|
-
<p>
|
|
7
|
-
<strong>Paquete egresado</strong>
|
|
8
|
-
</p>
|
|
9
|
-
<p>
|
|
10
|
-
<strong style={{ color: '#9A65E0' }}>
|
|
11
|
-
Fecha y hora: 12/02/2023 12:23:43
|
|
12
|
-
</strong>
|
|
13
|
-
</p>
|
|
14
|
-
<p>
|
|
15
|
-
<strong style={{ color: '#9A65E0' }}>Estado: En depósito</strong>
|
|
16
|
-
</p>
|
|
17
|
-
<br />
|
|
18
|
-
<Button className='btn-width-lg'>
|
|
19
|
-
Egresar nuevamente
|
|
20
|
-
</Button>
|
|
21
|
-
<br />
|
|
22
|
-
<br />
|
|
23
|
-
<Button className='btn-width-lg'>
|
|
24
|
-
Duplicado
|
|
25
|
-
</Button>
|
|
26
|
-
<br />
|
|
27
|
-
<br />
|
|
28
|
-
<Button className='btn-width-lg'>
|
|
29
|
-
Cerrar
|
|
30
|
-
</Button>
|
|
31
|
-
</>
|
|
32
|
-
);
|
|
33
|
-
};
|
|
34
|
-
|
|
35
|
-
export default DialogInfoV2;
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
import { Button } from '@mui/material';
|
|
2
|
-
|
|
3
|
-
const DialogNotFound = () => {
|
|
4
|
-
return (
|
|
5
|
-
<>
|
|
6
|
-
<p>
|
|
7
|
-
<strong>Lo sentimos</strong>
|
|
8
|
-
</p>
|
|
9
|
-
<p>No se ha encontrado lo solicitado</p>
|
|
10
|
-
<br />
|
|
11
|
-
<Button className='btn-width-md'>
|
|
12
|
-
Aceptar
|
|
13
|
-
</Button>
|
|
14
|
-
</>
|
|
15
|
-
);
|
|
16
|
-
};
|
|
17
|
-
|
|
18
|
-
export default DialogNotFound;
|
|
@@ -1,115 +0,0 @@
|
|
|
1
|
-
import { useEffect, useState } from 'react';
|
|
2
|
-
import Button from '@mui/material/Button';
|
|
3
|
-
import { useNavigate } from 'react-router-dom';
|
|
4
|
-
import * as React from 'react';
|
|
5
|
-
|
|
6
|
-
import DASHModal from 'dash-modal';
|
|
7
|
-
import { TextField } from '@mui/material';
|
|
8
|
-
import useQuickSearch from '../../hooks/useQuickSearch';
|
|
9
|
-
import setNativeValue from '../../utils/setNativeValue';
|
|
10
|
-
|
|
11
|
-
export interface IQuickSearch {
|
|
12
|
-
searchUrl?: string;
|
|
13
|
-
}
|
|
14
|
-
const QuickSearch: React.FC<IQuickSearch> = (props) => {
|
|
15
|
-
const { searchUrl = '/admin/package' } = props;
|
|
16
|
-
|
|
17
|
-
const navigateTo = useNavigate();
|
|
18
|
-
const [options, setOptions] = useState<{ q: string }>({ q: '' });
|
|
19
|
-
const [open, setOpen] = React.useState(false);
|
|
20
|
-
const { sendQuickSearchEvent } = useQuickSearch();
|
|
21
|
-
|
|
22
|
-
const inputRef = React.useRef<HTMLInputElement>(null);
|
|
23
|
-
|
|
24
|
-
const toggleModal = (value?: boolean) => {
|
|
25
|
-
if (value === null || value === undefined) {
|
|
26
|
-
setOpen(true);
|
|
27
|
-
return;
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
setOpen(!open);
|
|
31
|
-
};
|
|
32
|
-
// TODO: [bug] somethomes when clicking fast between pages seems to be related to an infinite loop redirection issue because of the timeout;
|
|
33
|
-
const search = () => {
|
|
34
|
-
toggleModal(false);
|
|
35
|
-
//sendQuickSearchEvent(options.q);
|
|
36
|
-
// This timeout sends the event that triggers the filters change in the searchUrl target;
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
//sendQuickSearchEvent(options.q);
|
|
40
|
-
//setNativeValue(document.getElementById("quickSearch"),options.q);
|
|
41
|
-
|
|
42
|
-
navigateTo({
|
|
43
|
-
pathname: searchUrl,
|
|
44
|
-
//search: `filter=${stringify({ quickSearch: options.q}, { arrayFormat: 'bracket', arrayFormatSeparator:":" })}`,
|
|
45
|
-
//search: `quickSearch=${options.q}`
|
|
46
|
-
});
|
|
47
|
-
|
|
48
|
-
setTimeout(() => {
|
|
49
|
-
sendQuickSearchEvent(options.q);
|
|
50
|
-
setNativeValue(document.getElementById("quickSearch"),options.q);
|
|
51
|
-
}, 2000);
|
|
52
|
-
|
|
53
|
-
};
|
|
54
|
-
|
|
55
|
-
useEffect(() => {
|
|
56
|
-
if (open === true) {
|
|
57
|
-
setTimeout(() => {
|
|
58
|
-
inputRef.current?.focus();
|
|
59
|
-
}, 10);
|
|
60
|
-
}
|
|
61
|
-
}, [open]);
|
|
62
|
-
|
|
63
|
-
return (
|
|
64
|
-
<>
|
|
65
|
-
<Button
|
|
66
|
-
//htmlType="button"
|
|
67
|
-
//variant="default"
|
|
68
|
-
className='dash-header-actions-btn'
|
|
69
|
-
onClick={() => toggleModal(true)}
|
|
70
|
-
>
|
|
71
|
-
Búsqueda rápida
|
|
72
|
-
</Button>
|
|
73
|
-
|
|
74
|
-
<DASHModal
|
|
75
|
-
onCancel={() => {
|
|
76
|
-
toggleModal(false);
|
|
77
|
-
}}
|
|
78
|
-
onConfirm={() => search()}
|
|
79
|
-
title='Búsqueda rápida'
|
|
80
|
-
variant={'info'}
|
|
81
|
-
open={open}
|
|
82
|
-
confirmText={'Buscar'}
|
|
83
|
-
>
|
|
84
|
-
<div
|
|
85
|
-
style={{
|
|
86
|
-
display: 'flex',
|
|
87
|
-
flexDirection: 'column',
|
|
88
|
-
alignItems: 'stretch',
|
|
89
|
-
textAlign: 'left',
|
|
90
|
-
}}
|
|
91
|
-
>
|
|
92
|
-
<TextField
|
|
93
|
-
inputRef={inputRef}
|
|
94
|
-
// eslint-disable-next-line jsx-a11y/no-autofocus
|
|
95
|
-
autoFocus={true}
|
|
96
|
-
variant='outlined'
|
|
97
|
-
placeholder='Buscar por nombre, apellido, ID dash'
|
|
98
|
-
label='Buscar'
|
|
99
|
-
onChange={({ target: { value } }) =>
|
|
100
|
-
setOptions((prevState) => ({ ...prevState, q: value }))
|
|
101
|
-
}
|
|
102
|
-
onKeyDown={(ev) => {
|
|
103
|
-
//console.log(`Pressed keyCode ${ev.key}`);
|
|
104
|
-
if (ev.key === 'Enter') {
|
|
105
|
-
// Do code here
|
|
106
|
-
search();
|
|
107
|
-
}
|
|
108
|
-
}}
|
|
109
|
-
/>
|
|
110
|
-
</div>
|
|
111
|
-
</DASHModal>
|
|
112
|
-
</>
|
|
113
|
-
);
|
|
114
|
-
};
|
|
115
|
-
export default QuickSearch;
|